Copying the Dradis Pro data across

Restarting in Rescue Mode

Because we’re going to overwrite some critical files in the system, we need to shut down the server and start in rescue mode.

If the system is still running, shut it down. Go to the “Rescue” tab and Reboot into Rescue Mode.

Mount the root partition

Next thing we need is to mount the root partition so we can SCP data across.

Before we begin, we need to check the version of cryptsetup using the command: cryptsetup --version. If the version is below the 2.1.0, cryptsetup will need to be updated using apt.

First, we need to unlock the LUKS volume:

root@ttyS0:~# cryptsetup open --type luks2 /dev/sdb crypt-sdb
Enter passphrase for /dev/sdb:

Next, activate the lvm volumes:

root@ttyS0:~# lvscan
root@ttyS0:~# vgchange -ay

Then, mount the open volume into a temporary location:

root@ttyS0:~# mount /dev/mapper/dradispro—vg-root /mnt/

And we’re good to go.

SSH access

Because we’re going to SSH into the rescue mode server, we have to make some minimal configuration: a) a temporary root password and b) enabling SSH access.

root@ttyS0:~# passwd
root@ttyS0:~# /etc/init.d/ssh start

Now, make a note of the server’s IP address:

root@ttyS0:~# /sbin/ifconfig eth0

For this example we’ll use

Use rsync to send the data

We’re going to copy across the entire file system from your local instance of Dradis Pro into the cloud server.

Make sure your local instance is running, and open and SSH connection to it (as root).

Now the moment of truth, rsync from the Dradis Pro console to the remote server

root@dradispro:~# cd /
root@dradispro:/# rsync -avh --progress --exclude={/boot/*,/etc/fstab,/etc/crypttab,/etc/inittab,/dev/*,/proc/*,/sys/*,/tmp/*,/run/*,/mnt/*,/media/*,/lost+found} . root@

Note that we’re excluding the /boot directory, /etc/fstab, /etc/crypttab, and /etc/inittab this is because the server layout (kernel, disk images, LUKS and LVM configuration, etc.) is significantly different in your local appliance than it will be in your cloud instance.

This operation will take a few minutes, so maybe you want to grab a cup of tea now :)

Umount the partition and reboot the system

After the rsync operation is complete, you can go back to your cloud server and umount the /mnt partition:

root@ttyS0:~# ls /mnt/opt/
dradispro  rbenv
root@ttyS0:~# umount /mnt/

If you see a /opt/dradispro directory in there, it sounds like things worked out as they should.

You can shutdown the server.

root@ttyS0:~# shutdown -h now

Next article in guide: Launch the Instance→

Streamline InfoSec Project Delivery

Learn practical tips to reduce the overhead that drags down security assessment delivery with this 5-day course. These proven, innovative, and straightforward techniques will optimize all areas of your next engagement including:

  • Scoping
  • Scheduling
  • Project Planning
  • Delivery
  • Intra-team Collaboration
  • Reporting and much more...

Your email is kept private. We don't do the spam thing.