Direkt zum Hauptbereich

Posts

Posts mit dem Label "Backup" werden angezeigt.

Systembackup using dpkg and dselect

Systembackup by integr8e As a result of many reinstallations, I've begun developing a method that quickly allows me to restore my new installation to the setup of my old one. As such, I decided to share my knowledge: -> MAKE A LIST - To create an easily restoreable list of all installed software on your system (from the repos), open Konsole and enter the following command: dpkg --get-selections | grep [^de]install$ > installed-software.txt - That will create an entry in your "/home//" directory entitled "installed-software.txt" ( is your username). -> [u]BACKUP - Backup all your important files to an external storage device (hard drive / flash disk); you may wish to backup your "/etc/X11/xorg.conf" and "/etc/apt/sources.list" configs. If you have the Medibuntu/Wine repo(s), you'll need to additionally backup your "/etc/apt/sources.list.d" directory. For an excellent guide on backing up using the...

Backup NICHT mit dd

Aus irgendeinem #$@%&!-Grund geht partimage auf meinem eeepc nicht, meldet jeweils beim *Erstellen* des Images: "image Lese fehler Bitmap block 0" . Hab allerdings diesen Beitrag gefunden: dd usually the *ABSOLUTELY WRONG* tool to use for pushing around file systems, since you have to issue the "count" command to cut off the dd at the end of the partition absolutely correctly or you will leave off the last few bits of your partition and filesystem, or start copying the *next* partition and filesystem. It also guarantees you a dd image exactly the size of the partition on disk instead of the size of the file system, which may be *vastly* smaller and thus much easier to save and faster to write. http://forum.soft32.com/linux2/Resize-Partition-dd-ftopict45930.html Wie dem auch sei, man kann ja immer noch mit dd images erstellen,(hoffe ich). Hier ne Anleitung: http://www.debianhelp.co.uk/ddcommand.htm full hard disk copy dd if=/dev/hdx of=/dev/hdy dd if=...

spiegeln mit rsync

sudo rsync -aHvP /data/dirvishBank/ /mnt/archiv/ a: archiv mode , beinhaltet: rlptgoD (aber nicht -H,-A,-X) -r, --recursive recurse into directories -l, --links copy symlinks as symlinks -p, --perms preserve permissions -t, --times preserve modification times -g, --group preserve group aber nicht: -H, --hard-links preserve hard links -A, --acls preserve ACLs (implies -p) -X, --xattrs preserve extended attributes also noch Hardlinks einschalten (-H) v: steht für verbose und P für prgresss indicator

dirvish

Dokumentation natürlich unter Welcome to Dirvish gute Doku: howto:dirvish [Open Source (tm) Guides & Tutorials] Dirvish in eigenen Worten: D kann mehrere Banken (Bank) verwalten, die jeweils mehrere Schließfächer (Vaults) enthalten. z.b. /data/dirvishBank/ ist die lokale Bank, /media/Trekstor/dirvish/ ist die auf der externe HD. /data/dirvishBank/Lehre ist ein Vault. Vaults enthalten immer ein Verzeichnis dirvish: /data/dirvishBank/Lehre/dirvish und darin default.conf z.B. client: localhost tree: /data/Lehre expire-default: +5 weeks expire-rule: wd { sun } +3 months wd { sun } md { 1-7 } +1 year wd { 1 } md { 1-7 } mo { 1,4,7,10 } never hr { 10-20 } +10 days client: der rechner auf dem die zu backuppenden daten liegen tree: gibt das verzeichnis, an, für das ein Snapshot angelegt werden soll expire-default und expire-rule, wann snapshot gelöscht werden. Hier: default nach 5Wo., die Sonntags-Backups, we...

SMART MonTools

Moderne Festplatten sind mit der Self-Monitoring, Analysis and Reporting Technology oder auch S.M.A.R.T. ausgerüstet. Diese sollen die Zuverlässigkeit der Festplatten überwachen und so Laufwerksfehlern vorbeugen. Natürlich können immer noch plötzliche Fehler auftreten, das Risiko kann jedoch minimiert und Datensicherungen rechtzeitig vorgenommen werden. Mit den SMART MonTools lassen sich die Überwachungswerte überprüfen. Laufwerk-Informationen ausgeben sudo smartctl -i /dev/ x d y Gesundheitsstatus überprüfen sudo smartctl -H /dev/ x d y failed » Festplatte weist Fehler auf, so wurden zum Beispiel schon fehlerhafte Sektoren durch SMART ersetzt passed » Festplatte ist fehlerlos SMART-Attribut Bedeutung Raw Read Error Rate -> Lesefehlerrate Spin-Up Time -> Motoranlaufzeit Rellocated Sector Count -> ausgelagerte Daten in Reservesektoren Power on Hours Count -> Anzahl der Betriebsstunden Power Cycle Count -> Anzahl der Einschaltv...

System gebackuped

sudo dd if=/dev/sda of=/media/Trekstor/backup_Valinor_MBR_2009-02-21 bs=512 count=1 sudo tar cvpzf /media/Trekstor/backup_Valinor_2009-02-21.tgz --exclude=/data --exclude=/home --exclude=/video --exclude=/media --exclude=/proc --exclude=/lost+found --exclude=/backup.tgz --exclude=/mnt --exclude=/sys /

dirvish reloaded

Hab heute mal wieder (seit langem) mit dem Datenbackup beschäftigt. Es gibt immer noch keine GUI für dirvish. (Würde ich bevorzugen, da ich gerade beim Datenbackup eine grafisches UI für weniger fehleranfällig als ein Kommandozeilen UI halte. Beispiel, hab gerade festgestellt, dass der Photo-Vault so konfiguriert war, dass er Musik up-backte, aber Photos nicht archiviert wurden! Gottseidank ist in der Zwischenzeit nichts passiert!) Eine "Schwierigkeit" war das Archivieren von anderen Accounts: Am besten dirvish als root laufen lassen (sudo dirvish). Problem: dirvish macht Backups immer per ssh, (auch wenn host und client derselbe rechner sind). Ein login als root auf localhost scheiterte aber an zwei Stellen: 1.) hatte ich noch kein root-Schlüsselpaar erstellt. (s. ssh hier im blog) der public key muss diesmal im gleichen Verzeichnis (.ssh) an authorized_keys angehängt werden. cat id_dsa.pub >> authorized_keys 2.) sshd war so konfiguriert, dass Anmeldungen als root n...

Dirvish zum Backup auf externer Festplatte

Um ein Filesystem Backup wichter Verzeichnisse auf eine externe Festplatte zu machen, das sich aber ohne externe Mittel als ganz normales Verzeichnis lesen lässt, bietet sich dirvish an. Hier /etc/dirvish/master.conf: bank: /media/Trekstor/dirvish image-default: %Y%m%d log: gzip index: gzip xdev: 1 exclude: Hier /etc/dirvish/post-server-skript.sh , das das post-server-skript, das einen Link auf den aktuellen Snapshot legt und alle Schreibrechte entfernt: (darf scheinbar nicht auf der externen Platte liegen, sonst kann dirvish es nicht ausführen) #!/bin/bash # muss zumindest user read und executable sein LOGFILE=/media/Trekstor/dirvish/dirvishTest/dirvish/Log VAULT=${DIRVISH_IMAGE%%:*} if [[ -a /media/Trekstor/$VAULT ]] then rm /media/Trekstor/$VAULT fi ln -s $DIRVISH_DEST /media/Trekstor/$VAULT Die einzelnen Snapshots liegen in den Vaults /media/Trekstor/dirvish/ . in jedem Vault gibt es ein Verzeichnis dirvish, dass default.conf enthält, z.B.: /media/Trekstor/dirvish/A...

Komplett backup

Hier ist ein gutes Howto, der sich sowohl mit partimage als auch dem MBR befasst: http://ubuntuforums.org/showthread.php?t=360283 SFDISK (partition table backup) (untested) Make: sfdisk -d /dev/hda > bak-hda Restore: sfdisk /dev/hda MBR BACKUP (untested) Backup: dd if=/dev/hdx of=MBR-backup bs=512 count=1 Restore: dd if=MBR-backup of=/dev/hdx bs=512 count=1 Backup Boot Code Only: dd if=/dev/hdx of=MBR-backup bs=448 count=1 Restore Boot Code Only: dd if=MBR-backup of=/dev/hdx bs=448 count=1 Install Grub: grub-install /dev/hda PARTIMAGE (command line method) partimage -z1 -o -d save /dev/hda5 /mnt/myhd/rescuefile Image einer partition erstellen, aber nur bei runtergefahrenem System möglich: http://wiki.ubuntuusers.de/partimage Hier habe ich eine einfache Methode gefunden, wie sich unter Linux ein Komplettbackup erstellen lässt: http://ubuntuforums.org/showthread.php?t=35087 : Backup erstellen: tar cvpzf backup.tgz --exclude=/proc --exclude=/lost+found --exclude=/backup....