aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Pages: 1 2 [3]

Author Topic: Amule.conf corruption risk  (Read 21058 times)

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: Amule.conf corruption risk
« Reply #30 on: June 26, 2009, 06:01:55 PM »

Back it up on shutdown, not on any other occasion.
Logged

wuischke

  • Developer
  • Hero Member
  • *****
  • Karma: 183
  • Offline Offline
  • Posts: 4292
Re: Amule.conf corruption risk
« Reply #31 on: June 26, 2009, 08:21:55 PM »

Done.

BTW: Yay for code reuse!
Logged

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: Amule.conf corruption risk
« Reply #32 on: June 26, 2009, 08:34:13 PM »

That's what it's for!
Logged

stoatwblr

  • Sr. Member
  • ****
  • Karma: 12
  • Offline Offline
  • Posts: 318
Re: Amule.conf corruption risk
« Reply #33 on: August 22, 2009, 03:34:49 PM »

May I ask why your computer is crashing so often in the first place? Do you live in a zone with an unstable power supply?

If it was that easy I'd have fixed it (Several UPSes on hand).

It turns out the Intel Desktop Motherboard model D865GLC(*) has hardware issues with RAM addressing. It's 100% reproduceable across the 20+ systems I've tested. (Anyone with one of these boards can trigger the fault by using memtest86+ and getting it to probe memory. The system will lockup halfway through the first test pass. It manifests in Linux as a system lockup during heavy I/O activity and I've been unable to trigger it at all in windowsXP)

Quote
Anyway, we make backups of other important files, so why not backup the configuration file, too? I have to go now, but I'll implement it later. (Unless I forget to...)

Thanks. I see you've implemented this, but it's not quite enough to solve the problem:

(I've had another couple of truncation incidents recently and noticed the bak file was anything up to 14 days old.)

There's no point in only making a backup at exit, because if there's a crash it will l never be written.

There should be a backup made each time a new config file is written, or at the very least each time anything other than a statistics change occurs.

Statistics in config files:

I'll second the comment made in another thread that writing out statistics into the config file is a Really Bad Idea.

This whole thread would have been a non-issue if it wasn't for that being done. Config files should be as static as possible.


(*) It's suprising that Intel can produce unstable motherboards! We ended up replacing 22 desktop machines 2 years ahead of schedule at $orkplace as a result of finding this problem as it explained why some researchers were getting random lockups. I don't have the budget to change the home box out just yet.

Logged

Morse

  • Full Member
  • ***
  • Karma: 6
  • Offline Offline
  • Posts: 105
Re: Amule.conf corruption risk
« Reply #34 on: August 26, 2009, 01:08:24 AM »

Well, the topic goes some weird way... but may i return to the subj?

I've had an issue several times (my power supply isn't the best, and i can't afford an UPS now), and the workaround was easy: to edit an init script so it checked a .conf file and replaced it with backup if size=0.
But i was wondering about the cause of this. amule(d) edits conf file regularly to update stats, but it's a conf file - a file for amule configuration. not for logs or stats or whatever. isn't it a somekind wrong place for those? i always thought that conf file must contain only the data that is pivotal for program's proper working, so the editing of this file would be rare. what's the idea of putting the stats in conf?

PS i've lost my conf file because i've installed XFS on my server being impressed by Kry's story. So i won't blame XFS, i will blame Kry! Agrrrrrrr!
Logged

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: Amule.conf corruption risk
« Reply #35 on: August 26, 2009, 08:36:26 AM »

Go ahead and blame me for your inability to choose a proper filesystem for your situation.
Logged

Morse

  • Full Member
  • ***
  • Karma: 6
  • Offline Offline
  • Posts: 105
Re: Amule.conf corruption risk
« Reply #36 on: August 26, 2009, 11:18:41 AM »

hey guys, what's with your sense of humour? are you talking too much with simple-minded complainers?

But anyway, i'm really curious about what stats are doing in conf file. may be i don't understand something?
Logged

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: Amule.conf corruption risk
« Reply #37 on: August 26, 2009, 05:00:41 PM »

hey guys, what's with your sense of humour? are you talking too much with simple-minded complainers?

Where's yours? I've been told I'm way too deadpan when poking fun at someone, and it seems it works online as well!
Logged
Pages: 1 2 [3]