On Sun, 30 Jan 2000, Arnie Metz wrote:
> After some recent <self-induced> disasters, you know when you hit yourself
> with a brick, I think its time to get serious about backing up a few files.
> Question is: which ones and where are they kept.
If you have done any kind of customization on your system, changed any
configuration files, they would be the ones to backup (other than your
data files). Typically, they would be in /etc .
> Being an Win95 convert I got comfortable having a program called FirstAid.
> It took a snapshot of the essential config (and similar) files every time 95
> shutdown.
> Seems to me I should be able to write a reasonably simple script that would
> do this.
> Conceptually:
>
> script_name:
> startx
> tar a few specific files to a directory
> #end of script, return user to the prompt
>
You lost me here. Why, in heavens name, do you need the 'startx'?
Backing up with tar can be done perfectly fine from the command prompt.
Just because it executes without a graphical environment doesnt make it
any less effective.
There are two requirements to writing a shell script. (1) The file
must have the execute attributes set (see the man pages for 'chmod'). (2)
The very first thing in the file must be '#!/bin/bash' (if you are using
the bash shell - chances are that you are).
For the actual language definition of the scripting language, read
the 'bash' man page.
> Kind of crude, but after a disaster one could merely grab some backup files
> and put yourself back where you where before you broke it.
>
> For that matter couldn't I write a script that would replace the corrupted
> files with the backups?
>
Sure, why not?
Regards,
Kenneth
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/