Quoting Colin O'Keeffe (ilugcolin at gmail.com):
> Is there a way to backup important debian files like X settings and
> kernel image incase I break something ?
Well, I sometimes make a safety copy of /etc like this:
# cd /etc
# tar cvzf etc-$(date --iso-8601).tar.gz /etc
The resulting tarball's tiny enough to fit on {shudder} a floppy, if
need be.
I'm not clear on why you'd need/want to keep a copy of a kernel _image_.
You would certainly want to keep a copy of your kernel .config file, if
you compile your own.
What you might want to make a safety copy of is your current list of
installed packages:
# dpkg --get-selections >selections.txt
And get their current versions:
# COLUMNS=150 dpkg -l > packages.txt
> Also , where is the package list stored on a machine or does it fetch
> it from the server ?
The _available_ packages list is stored as text file
/var/lib/dpkg/available, mashed down from the individual package
repositories' Packages[.gz] files fetched to /var/lib/apt/lists .
(There's also a binary index somewhere to speed up reads, generated
dynamically as needed.) The _installed_ packages are recorded in
/var/lib/dpkg/status -- and I believe that's likewise hashed
dynamically, somewhere.
But doing the above commands, honestly, gets you what you need to make a
copy of. Because, given "selections.txt", you can rebuild your system,
not including local customisations and data files, from a minimal Debian
Base System install plus this:
# dpkg --set-selections <selections.txt
# apt-get -u dist-upgrade
(or maybe "apt-get dselect-upgrade" might be better -- same idea,
anyway)
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!