| Author |
Message |
Brian C
Guest
|
Posted: Sun 22 Jan 2006, 21:00 Post subject:
Does puppy auto-sync the pup001? |
|
We have had a series of random/unexpected power outages around here, which have caused my puppy linux live-cd computer to shut down. Does puppy automatically syncronise itself with a pup001 file on my HD at regular intervals? Can I make it?
|
|
Back to top
|
|
 |
MU

Joined: 24 Aug 2005 Posts: 13642 Location: Karlsruhe, Germany
|
Posted: Sun 22 Jan 2006, 21:10 Post subject:
|
|
you could create a small shellscript
script: mysync
| Code: | #!/bin/bash
sync
sleep 180
$0 |
Save it as /usr/local/bin/mysync
Make it executable in a consolewindow with this command:
chmod 755 /usr/local/bin/mysync
Add the line
/usr/local/bin/mysync &
to /etc/rc.d/rc.local0 (as second line after the line "#!/bin/sh")
so that it runs automatically, when you boot puppy.
It will write changes to disk every 3 minutes (180 seconds).
Mark
|
|
Back to top
|
|
 |
GuestToo
Puppy Master
Joined: 04 May 2005 Posts: 4078
|
Posted: Sun 22 Jan 2006, 22:47 Post subject:
|
|
maybe this would be better:
| Code: | #!/bin/bash
sync
sleep 180
exec $0 |
or maybe:
| Code: | #!/bin/bash
while true
do
sleep 180
sync
done |
i think ext3 automatically does a sync every 5 seconds anyway (ext3 is optimised for reliablility), unless it was mounted with other options ... i don't know if ext2 does an automatic sync every 5 seconds
|
|
Back to top
|
|
 |
Pizzasgood

Joined: 04 May 2005 Posts: 6270 Location: Knoxville, TN, USA
|
Posted: Sun 22 Jan 2006, 23:06 Post subject:
|
|
| Quote: | | to /etc/rc.d/rc.local0 |
Actually, use /etc/rc.d/rc.local instead. You use rc.local0 for a remaster, but otherwise you use rc.local.
_________________ Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib

|
|
Back to top
|
|
 |
Brian C
Joined: 09 Feb 2006 Posts: 168
|
Posted: Mon 13 Feb 2006, 15:11 Post subject:
|
|
Is there a way to sync a multisession disk manually? When I shut down Puppy, the multisession disk doesn't always burn like it's supposed to, and I'd like the opportunity to sync it while I'm still booted in Puppy.
|
|
Back to top
|
|
 |
BarryK
Puppy Master

Joined: 09 May 2005 Posts: 6866 Location: Perth, Western Australia
|
Posted: Mon 13 Feb 2006, 19:56 Post subject:
|
|
| Brian C wrote: | | Is there a way to sync a multisession disk manually? When I shut down Puppy, the multisession disk doesn't always burn like it's supposed to, and I'd like the opportunity to sync it while I'm still booted in Puppy. |
Well, the puppy2 saving at shutdown should potentially be more reliable,
when we get the bugs out of the alpha release that is.
saving back to DVD is a simple script, that can be launched periodically, or manually by
a icon on the desktop -- TedDog posted an example one line of script that does
that for puppy2 - see the Cutting Edge section I think. I intend to include the desktop icon in the beta release.
|
|
Back to top
|
|
 |
|