How to migrate to a new openSUSE version
From openSUSE
| This article is in need of attention! This article currently does not meet the standard expected on the openSUSE Wiki. |
|
This article should help those that want to upgrade their openSUSE version. This might be done by selecting upgrade in the installation process, however the latter can cause trouble, if you installed 3rd party packages or the version you run is a lot older than the new one. If it works, you do not need this article anyway.
This article does also help those that want to migrate from another linux distribution to openSUSE. Please feel free to add to it!
If the Upgrade via the DVD or zypper fails, there is still th possibility to do a a new installationwithout loosing your users' settings and data, which reside in /home, such as email and documents. However your system-wide settings, e.g. your printer set-up etc. are lost. The advantage of a new installation is that there are no conflicts with 3rd party packages, simply because they are removed.
This article is not meant for pros, i.e. will not get into details such as migrating your web- or email-server. If you run those you are probably skilled enough to migrate on your own anyway.
Preparing the migration
Backup your data
Your users reside in /home/a_username. So if you want to make sure that absolutely nothing gets lost, you have to copy those to some external media. You will have to backup everything within /home if you do not use a separate partition for it, see Remembering partitions for more details.
Backing up data is a bit different than just copying. Make sure that you preserve the user and permissions of the files, if not you will end-up with read-only settings-files your new system cannot write to.
If you burn your files to a DVD, tell the burning application that you are doing a backup. In K3B you can do this in the dialogue that pops-up when you click on Burn by going to the Filesystem tab, clicking on the Advanced-button next to the filesystem setting and ticking the checkbox for Preserve permissions (Backup).
If you want to copy all of your user's files to an external harddisk, it's easiest to do it via a konsole. Make sure your external harddisk is mounted and accessible. If you did not change anything, it can be found in /media/folder_of_your_external_harddisk. You can find out by navigating through your system with your favourite filemanager. If you know the path to your external harddisk, just open a konsole and do:
su cd /home cp -b -vvv username_to_be_backed_up /media/folder_of_your_external_harddisk
This will copy the whole user's folder to the external harddisk. If you are logged in as the user whose data you copy to an external harddisk (not burning them), you should not have to worry about files' permissions.
If you just backup your own user, you do not need the su.
Selective backup
Backing up everything is the safest method, but might not be necessary. You can copy files manually from your user's folder to the external harddisk. The tricky bit is to know which folder holds what data.
There are the non-hidden files, i.e. those you see, they are straight-forward. Yet there are some important ones that one might forget about.
your.username.revoke - If you created and published an encryption key, you need this file to revoke it
There are hidden folders and files as well. To see them, open your filemanager and enable Show hidden files, which in KDE's Dolphin is situated in the View-menu or can be toggled via ALT+..
The hidden files and folders' name start with a ".". You can back them all up or select those you know are important. Their names are mostly straight-forward:
.kde - KDE3 settings .kde4 - KDE4 settings .mozilla - Thunderbird/Firefox settings .gnome - Gnome settings .bogofilter - Bogofilter spam-tool settings .ssh - SSH key .gnupg - encryption keys for encrypting/signing emails and files, also used by front-ends such as kgpg. .ooox - OpenOffice settings .strigi - desktop search indices . . .
Remembering partitions
Your harddisk is divided into so called partitions. You might have one with your Windows on it, another for your Linux and yet another for your data.
To find out, open a konsole and do:
df
You will see a list of all partitions. You need to write down their partition, e.g.
/dev/sda1 = /windows/C /dev/sda2 = / (Your linux sysstem) /dev/sdb1 = /home (your users) /dev/sdb4 = SWAP
If you do not see any /dev/sxyz = /home but just /dev/sxyz = /, then you must backup all data within /home since everything in there will be lost!
Installing
Start the openSUSE installtion and pick new Installation instead of Upgrade. the important bit about the installation is to make sure that the installer gets your harddisk partitions right. So check twice, if it assigns the correct mount-point to the partitions, i.e. that /dev/sda2 is mounted as /, if we follow the example above. Same for /home.
The installer will mark all partitions it will format with a F and red font-colour. Make sure it only formats / and not /home. If done right, this will result in a new installation of the linux system on / but your users, which are on /home will be preserved.
In case the installer wants to resize your partitions you will have to change its recommendation. Make sure to assign the existing partitions to the correct mount-points and only format /.
If asked for a username, pick the same username you used before, the installer will re-use your old data from /home.
Make sure your webcam, printer etc. are attached and switched on, otherwise the installer cannot detect them.
Subsequent work
If everything went as expected you do not need to copy anything from your backup to you system, as everything in your users' folder was preserved.
However you do need to set-up system-wide things like printer and or graphics-drivers. You can do this via YaST.
For multimedia make sure you add the Packman repository, via YaST > Repositories > Add > Community Repositories > Packman. It holds packages like libxine1 which you need to update in order to play mp3 files. See opensuse-community.org/Multimedia for details.
Further articles on how to set-up your printer and other hardware can be found in the HOWTOs-section of this wiki.

