Installing additional packages:
For CentOS 6
yum install libfuse2 fuse-utils dmsetup
For CentOS 7
yum install fuse fuse-devel device-mapper
Installing TrueCrypt:
Note! Version 7.2 lacks encryption capabilities, so download version 7.1a
tar -xzvf truecrypt-7.1a-linux-console-x64.tar.gz
sh truecrypt-7.1a-setup-console-x64
Installing package... usr/bin/truecrypt usr/bin/truecrypt-uninstall.sh usr/share/truecrypt/doc/License.txt usr/share/truecrypt/doc/TrueCrypt User Guide.pdf
Create directories where the drives will be mounted
mkdir /backup
Check which drives need to be mounted:
ls /dev/sd* or fdisk -l
Create partitions:
fdisk /dev/sda -> n -> w
Format as ext4
mkfs.ext4 /dev/sda1
Create an encrypted partition
truecrypt -c /dev/sda1
truecrypt --filesystem=ext4 /dev/sda1 /terabackup
truecrypt -d -f
However, when dealing with many drives, they can get mixed up, so it is better to mount them by ID.
Check:
lsblk -f and blkid will not help because the drives are encrypted.
Instead, use
ls -l /dev/disk/by-id
and you will see:
lrwxrwxrwx 1 root root 9 Apr 17 2016 ata-GeIL_ZENITH_R3_120GB_GJ608A04T-1608003374 -> ../../sda
lrwxrwxrwx 1 root root 10 Apr 17 2016 ata-GeIL_ZENITH_R3_120GB_GJ608A04T-1608003374-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Apr 17 2016 ata-GeIL_ZENITH_R3_120GB_GJ608A04T-1608003374-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Apr 17 2016 ata-GeIL_ZENITH_R3_120GB_GJ608A04T-1608003374-part3 -> ../../sda3
lrwxrwxrwx 1 root root 9 Nov 23 11:32 ata-ST1000DM003-1CH162_Z1D460PC -> ../../sdc
lrwxrwxrwx 1 root root 10 Nov 23 13:53 ata-ST1000DM003-1CH162_Z1D460PC-part1 -> ../../sdc1
lrwxrwxrwx 1 root root 9 Nov 23 13:43 ata-ST1000DM003-1CH162_Z1D462T4 -> ../../sdb
We need
lrwxrwxrwx 1 root root 10 Nov 23 13:53 ata-ST1000DM003-1CH162_Z1D460PC-part1 -> ../../sdc1
Mount it:
truecrypt --filesystem=ext4 /dev/disk/by-id/ata-ST1000DM003-1CH162_Z1D460PC-part1 /backup
