Outils pour utilisateurs

Outils du site


installation_d_obnam

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
installation_d_obnam [2017/03/03 12:12] – [Configuration] simoninstallation_d_obnam [Date inconnue] (Version actuelle) – supprimée - modification externe (Date inconnue) 127.0.0.1
Ligne 1: Ligne 1:
-====== Installation d'Obnam ====== 
  
-===== Présentation ===== 
-//TO DO// 
- 
-===== Installation ===== 
-Je vais suivre le [[https://obnam.org/tutorial/|tutoriel]] sur le site d'obnam.org. On commence par installer, dans mon cas sur Debian8 - Jessie : 
-<code bash> 
-# apt-get install obnam 
-</code> 
-<hidden> 
-<code bash> 
-Reading package lists... Done 
-Building dependency tree        
-Reading state information... Done 
-The following extra packages will be installed: 
-  fuse libfuse2 python-cliapp python-crypto python-ecdsa python-fuse python-larch 
-  python-paramiko python-six python-tracing python-ttystatus 
-Suggested packages: 
-  libjs-query libjs-underscore python-crypto-dbg python-crypto-doc libjs-jquery 
-The following NEW packages will be installed: 
-  fuse libfuse2 obnam python-cliapp python-crypto python-ecdsa python-fuse python-larch 
-  python-paramiko python-six python-tracing python-ttystatus 
-0 upgraded, 12 newly installed, 0 to remove and 0 not upgraded. 
-Need to get 1,686 kB of archives. 
-After this operation, 5,382 kB of additional disk space will be used. 
-Do you want to continue? [Y/n]  
-Get:1 http://ftp.debian.org/debian/ jessie/main libfuse2 amd64 2.9.3-15+deb8u2 [135 kB] 
-Get:2 http://ftp.debian.org/debian/ jessie/main fuse amd64 2.9.3-15+deb8u2 [70.7 kB] 
-Get:3 http://ftp.debian.org/debian/ jessie/main python-tracing all 0.8-1 [33.8 kB] 
-Get:4 http://ftp.debian.org/debian/ jessie/main python-cliapp all 1.20140719-1 [80.8 kB] 
-Get:5 http://ftp.debian.org/debian/ jessie/main python-larch all 1.20131130-1 [78.4 kB] 
-Get:6 http://ftp.debian.org/debian/ jessie/main python-ttystatus all 0.23-1 [15.1 kB] 
-Get:7 http://ftp.debian.org/debian/ jessie/main python-crypto amd64 2.6.1-5+deb8u1 [256 kB] 
-Get:8 http://ftp.debian.org/debian/ jessie/main python-six all 1.8.0-1 [12.6 kB] 
-Get:9 http://ftp.debian.org/debian/ jessie/main python-ecdsa all 0.11-1 [35.1 kB] 
-Get:10 http://ftp.debian.org/debian/ jessie/main python-paramiko all 1.15.1-1 [107 kB] 
-Get:11 http://ftp.debian.org/debian/ jessie/main python-fuse amd64 2:0.2.1-10 [40.2 kB] 
-Get:12 http://ftp.debian.org/debian/ jessie/main obnam amd64 1.8-1 [822 kB] 
-Fetched 1,686 kB in 0s (5,055 kB/s) 
-debconf: delaying package configuration, since apt-utils is not installed 
-Selecting previously unselected package libfuse2:amd64. 
-(Reading database ... 15238 files and directories currently installed.) 
-Preparing to unpack .../libfuse2_2.9.3-15+deb8u2_amd64.deb ... 
-Unpacking libfuse2:amd64 (2.9.3-15+deb8u2) ... 
-Selecting previously unselected package fuse. 
-Preparing to unpack .../fuse_2.9.3-15+deb8u2_amd64.deb ... 
-Unpacking fuse (2.9.3-15+deb8u2) ... 
-Selecting previously unselected package python-tracing. 
-Preparing to unpack .../python-tracing_0.8-1_all.deb ... 
-Unpacking python-tracing (0.8-1) ... 
-Selecting previously unselected package python-cliapp. 
-Preparing to unpack .../python-cliapp_1.20140719-1_all.deb ... 
-Unpacking python-cliapp (1.20140719-1) ... 
-Selecting previously unselected package python-larch. 
-Preparing to unpack .../python-larch_1.20131130-1_all.deb ... 
-Unpacking python-larch (1.20131130-1) ... 
-Selecting previously unselected package python-ttystatus. 
-Preparing to unpack .../python-ttystatus_0.23-1_all.deb ... 
-Unpacking python-ttystatus (0.23-1) ... 
-Selecting previously unselected package python-crypto. 
-Preparing to unpack .../python-crypto_2.6.1-5+deb8u1_amd64.deb ... 
-Unpacking python-crypto (2.6.1-5+deb8u1) ... 
-Selecting previously unselected package python-six. 
-Preparing to unpack .../python-six_1.8.0-1_all.deb ... 
-Unpacking python-six (1.8.0-1) ... 
-Selecting previously unselected package python-ecdsa. 
-Preparing to unpack .../python-ecdsa_0.11-1_all.deb ... 
-Unpacking python-ecdsa (0.11-1) ... 
-Selecting previously unselected package python-paramiko. 
-Preparing to unpack .../python-paramiko_1.15.1-1_all.deb ... 
-Unpacking python-paramiko (1.15.1-1) ... 
-Selecting previously unselected package python-fuse. 
-Preparing to unpack .../python-fuse_2%3a0.2.1-10_amd64.deb ... 
-Unpacking python-fuse (2:0.2.1-10) ... 
-Selecting previously unselected package obnam. 
-Preparing to unpack .../archives/obnam_1.8-1_amd64.deb ... 
-Unpacking obnam (1.8-1) ... 
-Processing triggers for man-db (2.7.0.2-5) ... 
-Setting up libfuse2:amd64 (2.9.3-15+deb8u2) ... 
-Setting up fuse (2.9.3-15+deb8u2) ... 
-update-initramfs: deferring update (trigger activated) 
-Setting up python-tracing (0.8-1) ... 
-Setting up python-cliapp (1.20140719-1) ... 
-Setting up python-larch (1.20131130-1) ... 
-Setting up python-ttystatus (0.23-1) ... 
-Setting up python-crypto (2.6.1-5+deb8u1) ... 
-Setting up python-six (1.8.0-1) ... 
-Setting up python-ecdsa (0.11-1) ... 
-Setting up python-paramiko (1.15.1-1) ... 
-Setting up python-fuse (2:0.2.1-10) ... 
-Setting up obnam (1.8-1) ... 
-Processing triggers for libc-bin (2.19-18+deb8u7) ... 
-Processing triggers for initramfs-tools (0.120+deb8u2) ... 
-</code> 
-</hidden> 
- 
-===== Configuration ===== 
-On peut faire un fichier de configuration, il est optionnel mais permet de ne pas retaper tous les arguments à chaque fois. 
-<code bash> 
-# vim ~/.obnam.conf 
- 
-# cat ~/.obnam.conf  
-[config] 
-repository = /mnt/bkp/ 
-log = /var/log/obnam.log 
-</code> 
- 
-===== Tests de backups ===== 
-==== Premier backup ==== 
-On peut sauvegarder tout le //home// d'un utilisateur, par exemple : 
-<code bash> 
-# obnam backup --repository="/mnt/bkp/" /home/simon/ 
-Backed up 14245 files (of 14245 found), uploaded 218.0 MiB in 1h11m11s at 52.4 KiB/s average speed 
-</code> 
- 
-(Le dossier /mnt/bkp/ est un montage via sshfs, ça ralenti le backup!) 
- 
-<code bash> 
-# cd /mnt/bkp/ 
-/mnt/bkp# obnam generations 
-2 2017-02-19 18:19:12 .. 2017-02-19 19:29:43 (14245 files, 236801863 bytes)  
-</code> 
- 
-On peut lancer un autre backup sans rien changer, juste pour voir. Ça va très vite! 
-<code bash> 
-# obnam backup --repository="/mnt/bkp/" /home/simon/ 
-Backed up 0 files (of 14245 found), uploaded 0.0 B in 56s at 0.0 B/s average speed 
-</code> 
- 
-Si on rajoute un/des fichier(s), et qu'on relance un backup : 
-<code bash> 
-# obnam backup --repository="/mnt/bkp/" /home/simon/ 
-Backed up 2 files (of 14246 found), uploaded 0.0 B in 51s at 0.0 B/s average speed 
-</code> 
- 
-On voit qu'on a plusieurs "générations" : 
-<code bash> 
-/mnt/bkp# obnam generations 
-2 2017-02-19 18:19:12 .. 2017-02-19 19:29:43 (14245 files, 236801863 bytes)  
-36 2017-02-19 20:16:22 .. 2017-02-19 20:16:39 (14245 files, 236801863 bytes)  
-70 2017-02-19 20:18:11 .. 2017-02-19 20:18:24 (14246 files, 236801863 bytes)  
-</code> 
- 
-==== Backup du dossier /var/www/ ==== 
-<code bash> 
-# obnam backup --repository="/mnt/bkp/" /var/www/ 
-Backed up 48803 files (of 48803 found), uploaded 311.0 MiB in 4h21m3s at 20.3 KiB/s average speed 
- 
-# ls -al /mnt/bkp/ 
-total 32 
-drwxrwxr-x 1  549  549 4096 Feb 20 08:29 . 
-drwxr-xr-x 3 root root 4096 Feb 19 18:11 .. 
-drwx------ 1  549  549 4096 Feb 20 12:50 114327624274822128 
-drwx------ 1  549  549 4096 Feb 20 12:50 chunklist 
-drwx------ 1  549  549 4096 Feb 20 12:50 chunks 
-drwx------ 1  549  549 4096 Feb 20 12:50 chunksums 
-drwx------ 1  549  549 4096 Feb 20 08:29 clientlist 
-drwx------ 1  549  549 4096 Feb 20 08:29 metadata 
- 
-# obnam backup --repository="/mnt/bkp/" /var/www/ 
-Backed up 277 files (of 48987 found), uploaded 974.0 KiB in 4m31s at 3.6 KiB/s average speed 
-</code> 
- 
-===== À essayer ===== 
-  * Faire des modifications puis restaurer et vérifier que tout est bien comme avant. 
-  * Envoyer le backup dans un dossier [[encfs]] pour le chiffrement. 
-  * Évaluer tout ce qu'on veut sauvegarder sur un serveur et mettre tout dans un script. 
-  * ... 
-===== Sources ===== 
-  * [[https://sanskritfritz.wordpress.com/2014/04/24/backup-with-obnam-and-encfs/|backup with obnam and encfs (sanskritfritz.wordpress.com)]] 
-  * [[https://nos-oignons.net/wiki-admin/Proc%C3%A9dures/Manipuler_les_sauvegardes/|Manipuler les sauvegardes (nos-oignons.net)]] 
installation_d_obnam.1488543159.txt.gz · Dernière modification : 2020/08/09 12:59 (modification externe)