Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2

Author Topic: [40d]Sudden-Shutdown-Safe Savegames  (Read 2596 times)

Destroyer224

  • Bay Watcher
    • View Profile
[40d]Sudden-Shutdown-Safe Savegames
« on: November 08, 2008, 01:39:14 am »

Recently there have been a series of power outages in my neighborhood due to some construction work nearby. It was very aggrevating to say the least the first time it happened while I had been playing DF for an hour and a half without saving. I told myself that I would simply save/continue every ten minutes or so to prevent this from happening again. The second time it happened I figured it was going to be a minor inconvenience to re-load my save a few minutes back from where I had been... But then I found out that sudden shutdowns of my computer also happened to corrupt savegames. A medium-sized fort with ~70 dwarves was instantly unusable. I have done a search on this topic and found nothing but a million pages of nonsense about savegames which I do not wish to sort through, so if this has been talked about before, by all means post a link to a more informative thread with a not-too-chiding response.

EDIT: I have done a little testing with this problem and have discovered that it happens whether or not DF is running at the time of shutdown. If I shut my computer down normally, the savegames work just fine, but the reset button/held down power button also cause this problem. Very annoying at the least.
« Last Edit: November 08, 2008, 01:41:18 am by Destroyer224 »
Logged

Footkerchief

  • Bay Watcher
  • The Juffo-Wup is strong in this place.
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #1 on: November 08, 2008, 02:17:54 am »

What OS are you running?  Are you doing anything crazy like running DF off a flash drive?
Logged

Destroyer224

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #2 on: November 08, 2008, 03:55:17 am »

I'm running Windows XP 32-bit with Service Pack 3

And no, nothing fancy with DF other than using a custom tileset and slightly expanded view via the init.txt
Logged

Calessa Lynn Orphiel

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #3 on: November 08, 2008, 12:52:07 pm »

If I'm following this correctly, you're saying that even if DF isn't running, the save games get corrupted?

... If so, I'm not sure what Toady can do to fix it.  o.o
Logged

czolus

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #4 on: November 08, 2008, 01:54:01 pm »

Sounds like Windows is write-chaching the saves (in memory), and not getting all the data onto the hard drive in a timely manner.
Logged
Sic sum in ignis; sic sum quiritatio

Footkerchief

  • Bay Watcher
  • The Juffo-Wup is strong in this place.
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #5 on: November 08, 2008, 02:08:49 pm »

Sounds like Windows is write-chaching the saves (in memory), and not getting all the data onto the hard drive in a timely manner.

Wow, I didn't know this feature even existed.  OP, you could try this: http://support.microsoft.com/kb/259716

The tab you need is actually labeled "Policies," not "Disk Properties."
« Last Edit: November 08, 2008, 02:12:27 pm by Footkerchief »
Logged

The Doctor

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #6 on: November 08, 2008, 02:40:51 pm »

What OS are you running?  Are you doing anything crazy like running DF off a flash drive?
I did that. Ran pretty well.
Logged

Draco18s

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #7 on: November 09, 2008, 12:45:50 am »

What OS are you running?  Are you doing anything crazy like running DF off a flash drive?
I did that. Ran pretty well.

Beware of Flash drives limited number of writes (it's millions, but you never know with DF).
Logged

Destroyer224

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #8 on: November 09, 2008, 07:20:08 pm »

If I'm following this correctly, you're saying that even if DF isn't running, the save games get corrupted?
Yes, this is exactly what I am saying.

As usual, the construction work is taking an inordinate amount of time. I just reloaded windows due to getting a new, faster hard drive (DF is running on a second hard drive, although I could test it on the new one to see if it changes anything) and am just now getting everything reloaded. I'll try running DF and test a dummy save to see if the problem persists.

Thanks for all the replies everyone.
Logged

Destroyer224

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #9 on: November 12, 2008, 07:41:27 am »

Sorry for the long response time, but I tested it and everything still gets corrupted. Even giving it about 2-3 minutes in case it isn't finnished writing doesn't seem to help. The same thing happens on my new Hard Drive as well, and that thing runs at 10K RPM and can partition all 300 gigs in 15 minutes flat.

Turning off Write Caching did nothing to solve the problem, so i'm guessing it lies elsewhere.
« Last Edit: November 12, 2008, 07:49:44 am by Destroyer224 »
Logged

lordmick134

  • Bay Watcher
  • The Wanderer.
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #10 on: November 12, 2008, 09:56:21 pm »

I'm having this on my laptop, and I just log-off before I quit. Seems to work. At least, it has worked so far.
Logged

Destroyer224

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #11 on: November 13, 2008, 12:44:16 am »

That's the problem, I have no prior warning that these outages will occur, and frequently saving does not help because the file just gets corrputed and then cannot be used again unless I physically back up the last proper save game before playing.
Logged

Footkerchief

  • Bay Watcher
  • The Juffo-Wup is strong in this place.
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #12 on: November 13, 2008, 12:53:11 am »

Have you tried to duplicate this effect with... text files or something?
Logged

Calessa Lynn Orphiel

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #13 on: November 13, 2008, 06:51:45 pm »

Do the saves get corrupted if you boot the computer and a power failure occurs without running DF at all?
Logged

Rafal99

  • Bay Watcher
    • View Profile
Re: [40d]Sudden-Shutdown-Safe Savegames
« Reply #14 on: November 13, 2008, 08:03:37 pm »

DF doesn't corrupt savefiles, I am closing DF by Alt+Ctrl+Del -> Kill Process 95% of the time and never had even the smallest problem with a savegame.
Must be OS / Hard Drive problem.
Logged
The spinning Tantrum Spiral strikes The Fortress in the meeting hall!
It explodes in gore!
The Fortress has been struck down.
Pages: [1] 2