[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to reinstall without changing anything?



Mike Oliver wrote:
A couple of times I've gotten nervous about whether I could have been hacked,
back before I got a good iptables set up and turned off sshd etc.  I've run
various diagnostic scripts but generally found them to be overly prone to
false positives.  My *guess* is that I'm fine, given that no one's made any
charges to my credit cards and no one's complained that my machine is being
used to attack others.

Still, if there were a simple way to reinstall, keeping all the same
packages and not losing any customizations, I might do it.  But I don't
recall any way to avoid answering a million questions at install time.
Really, I shouldn't have to answer *any* -- I want all the same packages,
same /etc/fstab, same rcconf configuration, same cups configuration, etc etc etc.

So is there any way to do a sarge installation while keeping all the
same stuff, not having to go through all the tiresome interactive questionnaires,
and (preferably) with iptables enabled, so that no one can hack in
during the install itself?



I am not sure this answers what you want. My guess is that strictly speaking what you want cannot be done.

But I have a similar situation perhaps and solved it my way.

I wanted what you want: the very same system but newly installed and everything the same to the last letter.

So I wrote a script in which I apt-get -qq install <package> after setting dpkg-reconfigure debconf to no interaction.

Before running the script I save all relevant files. E.g. all needed config files, scripts, tex, etc. Everything that I need to keep. Included in that are things like XF86Config-4 so X will run immediately, etc/hotplug settings, ppp settings.

In the end you have everything that you need and the questions you must answer are very few: you have to reconfigure ddclient and ppp among others, but the list is very small.

Downside, you have to go through the effort of what you want and need in terms not only of packages, but files.

If neded I can send my script: obviously it can be used only on this system.

HTH

H












Reply to: