Categories
Encryption file system Information Security Linux Linux Mint ubuntu

Encrypt secondary disk – Linux

To set up cryptographic volumes, you need to back up the data first and restore data after the encryption is setup.

rsync -Pav <source/> <backup_destination/>

Once the backup is completed, install cryptsetup
sudo apt install cryptsetup

Create the encrypted partition
sudo cryptsetup --verbose --verify-passphrase luksFormat <device_name>
Provide passphrase once prompted, you could use fdisk -l to find the correct device.

Open the encrypted device
sudo cryptsetup luksOpen /dev/vdb1 vdb1 # the device name was vdb1 in my case
This will prompt the passphrase to open the device

Create the required file system
mkfs.ext4 /dev/mapper/vdb1

You could remove the ext4 reservation if not required
tune2fs -m 0 /dev/mapper/vdb1

Create mount directory
mkdir /mnt/secondary

Mount the device
mount /dev/mapper/vdb1 /mnt/secondary

Categories
Linux Linux Mint

Upgrading Linux Mint 13 (maya) to Linux Mint 14 (nadia).

Linux Mint 14
Linux Mint 14

Take a backup of the current sources.list, preferably make a full backup of the system.

Edit the sources.list file,
replace the occurrences of maya with nadia and precise with quantal.

$ vi /etc/sources.list
:%s/maya/nadia/g
:%s/precise/quantal/g

Resulting file may look like.

deb http://packages.linuxmint.com/ nadia main upstream import
deb http://archive.ubuntu.com/ubuntu/ quantal main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ quantal-updates main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu/ quantal-security main restricted universe multiverse
deb http://archive.canonical.com/ubuntu/ quantal partner
deb http://packages.medibuntu.org/ quantal free non-free

Update the system

$ sudo apt-get update
$ sudo apt-get dist-upgrade