Howto install duplicity rpm under RedHat / CentOS / Fedora Core Linux

Posted on in Categories , , , last updated October 16, 2007

Q. I would like to use duplicity package to automatically encrypting and storing remote backups in a bandwidth efficient manner in our backup server. The server is already configured and I’d like to install the same under RedHat Enterprise Linux. How do I install duplicity w/o compiling from source code?

A. Duplicity is a piece of software which provides easy encrypted versioned remote backup of files requiring little of the remote server. It does this using GnuPG, tar, and rdiff. To transmit data it can use ssh/scp, local file access, rsync, ftp, and Amazon S3.

The best way to install it to use rpm files from DAG’s repo. For example RHEL 4 64 bit version can be installed using RPM command:
# wget http://dag.wieers.com/rpm/packages/duplicity/duplicity-0.4.2-1.el4.rf.x86_64.rpm
# rpm -ivh duplicity-0.4.2-1.el4.rf.x86_64.rpm

In order to use duplicity you need to create a GPG key:
# gpg --gen-key
Next run duplicity as follows to make backups:
# duplicity --encrypt-key="YOUR-KEY" /home scp:[email protected]/directory
You can verify backups with –verify option:
# duplicity --encrypt-key="YOUR-KEY" --verify scp:[email protected]/directory /home

Finally, if you need to restore file use command as follows:
# mkdir -p /disk3/resored.file
# duplicity --encrypt-key="YOUR-KEY" scp:[email protected]/directory /disk3/resored.file

Read the man page of duplicity and gpg for more information and command options.

Linux or UNIX securely copy files across a network computer

Posted on in Categories , , , , , , , , , , last updated August 24, 2007

Q. FTP is insecure, how do I securely copy files across a network computer? My network has Windows and Linux systems.

A. You need to use Openssh client and server technology to copy between two more network computers. You can also find free ssh client tools. scp copies files between hosts on a network. It uses ssh for data transfer, and uses the same authentication and provides the same security as ssh.

Copy from Linux to Linux/UNIX system

Copy file called data.txt to ras.nixcraft.in Linux system (vivek is username):
$ scp data.txt [email protected]:/home/vivek

Copy more than two files:
$ scp data.txt pic.jpg [email protected]:/home/vivek
Copy /data directory and all files inside /data i.e. recursively copy entire directories:
$ scp -r /data [email protected]:/home/vivek

Copy from Windows to Linux/UNIX system

You can download any one of the following free Windows SCP client

Just install above client and follow on screen instructions.