Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
doku:backup [2021/09/29 09:31] – [Backup] goldenbergdoku:backup [2024/08/01 11:59] (current) – [Backup] goldenberg
Line 1: Line 1:
 ======Backup====== ======Backup======
 +User Data on VSC is only backed up for desaster recovery (such as a fire or complete hardware failure). Individual resores are not possible.
 +Due to the size of our volumes, some data may not make it into the backup.
  
-User Data on VSC is not backuped.+{{:doku:folie_10_backup.png?nolink|}}
  
 **Backup is solely the responsibility of each user.** **Backup is solely the responsibility of each user.**
- +Disk Pools are used on the storage servers to protect against single disk failure. 
-RAID-5 or RAID-6 is used on NFS and BeeGFS servers and Disk Pools on the GPFS servers to protect against single disk failure. +Up to several disks failing concurrently can be sustained.
-Up to one (RAID-5) or two (RAID-6) or more (Disk Pool) disks failing concurrently can be sustained.+
  
 Other failure modes like disk controller failure or filesystem software faults are very seldom but might lead to loss of data. Other failure modes like disk controller failure or filesystem software faults are very seldom but might lead to loss of data.
  
 +======Continuous Backup of User Data to Local Machines=====
  
-======Continous Backup of user Data to remote Machines=====+To set up a continuous backup from VSC to your local machine, follow these steps:
  
-A continuous backup from VSC has to circumvent the entering of the OTP numbers. If it its possible to keep a ssh session alive for a longer time, it can be used to create a tunnel for connecting to a rsync daemon. **Each time this tunnel has been disconnected (e.g. reboot of your machine or a VSC login node) you have to re-login with a OTP to reestablish the ssh tunnel**+**Download and Configure the Backup Script**
  
-Do the following steps: +On your local machine, download the `backupvsc.sh` script: 
-  - on the remote machine, download script an execute it. It will setup the configuration for a rsync daemon: <code> + 
-wget https://wiki.vsc.ac.at/lib/exe/fetch.php?media=doku:rsync:rsyncd_setup_remote.sh -O rsyncd_setup_remote.sh +<code> 
-bash rsyncd_setup_remote.sh+[...]$ wget https://wiki.vsc.ac.at/lib/exe/fetch.php?media=doku:backupvsc.odt -O backupvsc.sh
 </code> </code>
-  - On the local machine, also download a script, it will compile the commands for creating the ssh tunnel and using the rsync:<code> + 
-wget https://wiki.vsc.ac.at/lib/exe/fetch.php?media=doku:rsync:rsyncd_setup_local.sh -O rsyncd_setup_local.sh +Make the script executable: 
-bash rsyncd_setup_local.sh+<code> 
 +[...]$ chmod +x backupvsc.sh
 </code> </code>
-  - start the rsync daemon with the 'start_rsync' command specified in the 'alias' on the remote machine (**!!! remember on which login node you started the daemon, you have to connect to it later**). The command looks like:<code> + 
-rsync --daemon --config=/home/ ..../ rsyncd.conf+Run the script for the first time to configure it: 
 +<code> 
 +[...]$ ./backupvsc.sh
 </code> </code>
-  - open the ssh tunnel 'tunnel_vsc_rsync' on the local machine this will tunnel map a local port to the remote port of the listening rsync daemon. This example maps the local port 5100 to port 8077 on the login node l32: <code> ssh -L 5100:l32.cm.cluster:8077 <user>@l32.vsc.ac.at </code> **(the login node "l32" conntected to  must be the same as in step 3)** 
-  - do the 'backup_vsc' on the local machine. This command connects via the local port of the ssh-tunnel from step 4 to the remote rsync daemon: <code>rsync --password-file=/home/.../rsyncd.secrets -av --port 5100 rsync://<user>@localhost/myfiles /tmp/ </code> 
  
 +You will be prompted to enter:
 +  *Remote username
 +  *Remote host (e.g., `vsc5.vsc.ac.at`)
 +  *Path to the remote directory to back up
 +  *Path to the local backup directory
  
 +These details will be saved in a configuration file at `~/.backup_config`.
  
 +The script will also add useful aliases to your `.bashrc` file:
 +  *`backupvsc`: Runs the backup process
 +  *`addbackupfolder`: Adds an additional remote folder to the backup list
 +  *`removebackupfolder`: Removes a remote folder from the backup list
 +
 +To activate these aliases, run:
 +<code>
 +[...]$ source ~/.bashrc
 +</code>
 +
 +**Running the Backup**
 +
 +To run the backup process, use the alias:
 +<code>
 +[...]$ backupvsc
 +</code>
 +This will start the backup process, copying the specified remote directory and any additional folders to your local backup directory.
 +
 +**Adding a Folder to the Backup**
 +
 +To add an additional folder to the backup list, use the alias:
 +<code>
 +[...]$ addbackupfolder
 +</code>
 +You will be prompted to enter the path to the additional remote folder. This folder will be included in subsequent backups.
 +
 +**Removing a Folder from the Backup**
 +
 +To remove a folder from the backup list, use the alias:
 +<code>
 +[...]$ removebackupfolder
 +</code>
 +You will be prompted to enter the path to the remote folder you wish to remove from the backup list.
  • doku/backup.txt
  • Last modified: 2024/08/01 11:59
  • by goldenberg