---
name: "recover_gnomehack"
section: "6"
platform: "linux"
package: "gnomehack"
version: "1.0.5-1.1"
release: "Debian 2.2 (Potato)"
platforms: ["linux"]
url: "https://new.carta.tech/recover_gnomehack"
---

# recover\_gnomehack(6)

recover a GnomeHack game interrupted by disaster

## NAME

recover - recover a GnomeHack game interrupted by disaster

## SYNOPSIS

**recover** *base1 base2 ...*

## DESCRIPTION

Occasionally, a GnomeHack game will be interrupted by disaster when the game or the system crashes. Prior to GnomeHack v3.1, these games were lost because various information like the player's inventory was kept only in memory. Now, all pertinent information can be written out to disk, so such games can be recovered at the point of the last level change.

The *base* options tell *recover* which files to process. Each base option specifies recovery of a separate game.

For recovery to be possible, *gnomehack* must have been compiled with the INSURANCE option, and the run-time option *checkpoint* must also have been on. GnomeHack normally writes out files for levels as the player leaves them, so they will be ready for return visits. When checkpointing, GnomeHack also writes out the level entered and the current game state on every level change. This naturally slows level changes down somewhat.

The level file names are of the form base.nn, where nn is an internal bookkeeping number for the level. The file base.0 is used for game identity, locking, and, when checkpointing, for the game state. Various OSes use different strategies for constructing the base name. Microcomputers use the character name, possibly truncated and modified to be a legal filename on that system. Multi-user systems use the (modified) character name prefixed by a user number to avoid conflicts, or "xlock" if the number of concurrent players is being limited. It may be necessary to look in the playground to find the correct base name of the interrupted game. *recover* will transform these level files into a save file of the same name as *gnomehack* would have used.

*recover* has been installed under Debian GNU/Linux as sgid games. This makes it possible for users to recover their own games. The security hazards of possible cheating have been removed, by taking out the *-d* option and making sure the only directory auto-save files can be read from is /var/lib/games/gnomehack.

## NOTES

Like *gnomehack* itself, *recover* will overwrite existing savefiles of the same name. Savefiles created by *recover* are uncompressed; they may be compressed afterwards if desired, but even a compression-using *gnomehack* will find them in the uncompressed form.

## SEE ALSO

[gnomehack(6)](/gnomehack/6.md)

## BUGS

*recover* makes no attempt to find out if a base name specifies a game in progress. If multiple machines share a playground, this would be impossible to determine.

*recover* should be taught to use the gnomehack playground locking mechanism to avoid conflicts.
