8

I'm going to install Windows 7 RC soon and want to save all (or at least almost all) of my settings that I have in Ubuntu 9.04. How can I do this?

Wesley
  • 32,320
  • 9
  • 80
  • 116
Kredns
  • 496
  • 1
  • 8
  • 15

3 Answers3

12

Ok this really depends what you use your machine for.

If it's just a desktop machine then backing up your home directory /home/username will be enough.

This will make sure you keep all of your documents, music, application settings, chosen theme and the like.

If you've been been installing services list apache, mail servers etc then I would advise also taking a backup of /etc also and cherry pick stuff to restore when you re-install. It's generally fairly obvious where things live (apache config lives in /etc/apache2, mysql config in /etc/mysql etc...)

Another thing you might want to do is to create a list of all the packages you have installed.

To do this do the following:

dpkg --get-selections > package_list.txt

Backup package_list.txt Then when you are ready to put ubuntu back on install as normal and do the following:

dpkg --set-selections < package_list.txt

apt-get dselect-upgrade

It will then go off an re-install everything you had on before.

Hope that helps.

Nathan
  • 1,177
  • 6
  • 9
  • As an addendum to this I would also save /etc/ in case there are any application configurations you need to save. Of course, restore with care as version changes may invalidate the files. – Nick Devereaux May 06 '09 at 02:31
4

Copy your entire home directory (~/) and /etc. All settings should be in those two folders.

Adam Gibbins
  • 7,147
  • 2
  • 28
  • 42
  • 1
    **Most** settings should be in those two folders. Bind, for example, has part of its configuration in /var/named/. If you have Apache HTTPD running, your web pages are stored under /var/www/. – Eddie May 05 '09 at 21:13
  • Also, backup '/var' . I contains mail spools, crontabs, web server hosts, database storage binaries (ideally you should dump these these in case of database software version changes) and some other stuff – sirlark Mar 05 '12 at 14:41
1

Also see Ubuntu, how to setup a new machine like an existing one

Hamish Downer
  • 9,142
  • 6
  • 36
  • 49