On Sun, 29 Jan 2017 14:52:14 +0100, Steffen Bendix wrote:
> How can I reinstall Jessie without loosing files and already configured
> applications? I am a Linux beginner and have my Raspi running for a long
> time but it seems that it gets more and more corrupted. It does not load
> any updates anymore for weeks although I did not installed anything.
>
> I use the Raspi for Resilio sync and Nextcloud. There are more than 26
> GB data on the card for syncing. I won't setup the programs again
> because I had to setup connected remote computers as well (security keys
> for Resilio). This would cause endless resyncing even when I manually
> copy the files to the Raspberry Pi. I would like to avoid this.
>
> Therefore, is it possible to replace the running operating system for a
> fresh one and keep the configurations and data of the programs?
>
The following link explains how I do clean restores for Redhat Fedora
systems:
http://www.libelle-systems.com/free/linux/easier_upgrades.html
The same approach should work for a standard Raspbian installation except
that /home is just another top-level directory in the main ext3
partition. So, the clean install will overwrite /home with its default
content and after its complete you'll have to put it back the way it used
to be by overwriting it with the contents of your latest backup, which
will be quite slow.
Your back up scheme should keep at least two copies of /home and its
subdirectories, and you may also want to keep backup copies of /etc. so
you can look at modified configuration files in the backups and/or
compare them with the version set up by the clean install instead of
scratching your head while trying remember what changes you've made to
them.
I use two USB-attached external hard drives for backups and keep them in
a fire safe, though there's no reason why you shouldn't use SD cards in
place of hard drives for this. I use two hard drives so that there is
ALWAYS a backup copy in the firesafe with the door closed. This is
protection against the disk being used to make the most recent backup
getting corrupted by a bad backup, fried by a mains spike or otherwise
destroyed.
I use rsync to make the backups. There's no reason you shouldn't use tar
or another program that can copy a complete directory tree, except that:
- rsync is much faster because it does the minimum work needed to make
the backup copy identical to the directory tree its copying, i.e. it
deletes copies of files that you got rid of, adds copies of new files
and copies files that have been changed. It takes about the same time
as tar to make each of the initial backup copies but after that its
a lot quicker.
- don't use zip. Its fine for exchanging files with other operating
systems, but as a backup its deficient because it can scramble
permissions and may not deal correctly with symbolic and hard links.
--
martin@ | Martin Gregorie
gregorie. | Essex, UK
org |
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|