PDA

View Full Version : broken save file


grassy
January 17, 2010, 04:53
Save file breaks when computer bombs (e.g. overheats) while playing. This happens on 3.1.2.dev. Anyway to recover these?

flechette
January 17, 2010, 06:33
You aren't overclocking to play angband are you? ^^

grassy
January 17, 2010, 06:44
crappy laptop :)

takkaria
January 17, 2010, 09:04
Save file breaks when computer bombs (e.g. overheats) while playing. This happens on 3.1.2.dev. Anyway to recover these?

Email me one at takkaria@gmail.com and I'll have a look, but no promises.

Pete Mack
January 17, 2010, 13:11
This should never happen. A few questions:
1. What OS?
2. Does it happen always, or only sometimes?
3. Are you sure that it is angband that is pegging the CPU? (On *NIX, top; on Windows, task manager.)

grassy
January 19, 2010, 07:23
+ The save file after the crash is reduced to 0 bytes (angband indicates it's broken - but it's essentially deleted) - thus it wouldn't make sense posting.
+ I compiled using my home directory as the install target.
+ I'm playing the game on ubuntu karmic (x86) running through sun virtuallbox on win7 x64.
+ Happen always? So far every time the computer bombed (2x). Lost 2 nifty 35+ level female warriors :(
+ no, angband is not hogging the cpu, win processes are.

PowerDiver
January 19, 2010, 09:25
You sound ept enough to set up a daemon to copy the savefile once every 10 minutes [only] while you are playing. Versioning would be a pain, but even if you always copy to the same location you'd only lose if the system crashed while the copy was happening.

The game currently autosaves on level change [I don't know what revision that got in], so a crash would cost the max of the current dLevel or 10 minutes [or whatever] if you use sufficiently recent code.

Pete Mack
January 19, 2010, 11:44
What windows process is pinning it?
And why play on linux, when you can just as well play on the host OS?
EDIT:
since you're on Linux, can you run it under gdb (compiled -g) and see what causes the fault?

d_m
January 19, 2010, 15:18
+ The save file after the crash is reduced to 0 bytes (angband indicates it's broken - but it's essentially deleted) - thus it wouldn't make sense posting.
+ I compiled using my home directory as the install target.
+ I'm playing the game on ubuntu karmic (x86) running through sun virtuallbox on win7 x64.
+ Happen always? So far every time the computer bombed (2x). Lost 2 nifty 35+ level female warriors :(
+ no, angband is not hogging the cpu, win processes are.

Had you saved your game at all before the crash, or were you playing a new character straight through?

My understanding is that Angband doesn't change the savefile until you die, save, quit, or until it gets sent a signal to be killed that it can handle. I think things like "kill -9" or overheating might not allow it to write anything before the process dies. So if you hadn't saved yet, there would be no "old version" of the savefile present when you reload.

PowerDiver
January 19, 2010, 19:22
My understanding is that Angband doesn't change the savefile until you die, save, quit, or until it gets sent a signal to be killed that it can handle.

As I indicated above, the savefile is currently written over after each dLevel change. At least, it was the last time I checked a couple months ago playing nightlies.

grassy
January 20, 2010, 03:22
d_m: I saved numerous times before the crash.
PowerDiver: copy the savefile - blasphemy I say :)

On a side not, farming a large room with an average weapon is pretty cpu intensive.

LostTemplar
February 18, 2010, 19:51
This is common problem with ext4 filesystem with ubuntu, not only related to angband. All files, modified just before crush a generally reduced to 0 bytes.