Skip to content

Instantly share code, notes, and snippets.

@jlehtoma
Last active October 14, 2016 11:55
Show Gist options
  • Save jlehtoma/f5a13e97d4fc573c78d0b104db5b3cf3 to your computer and use it in GitHub Desktop.
Save jlehtoma/f5a13e97d4fc573c78d0b104db5b3cf3 to your computer and use it in GitHub Desktop.
Mount Ceph datablock on SURFsara HPC Cloud VM

Mount the datadisk in the VM

In this section we show you how you can start using the new disk.

  1. On the UI, from the menu at the left pane select the Virtual Machines page under Virtual Resources. Create a new VM by selecting the Template you created in the previous step.
  2. Once the VM is in RUNNING state, ssh as root to the machine using your SSH-key.
  3. Run fdisk -l and see that your new datablock is there (Disk /dev/vdb: 10.5 GB).
  4. Mount the datadisk in the VM:
sudo mkdir /data  
sudo mkfs -t xfs /dev/vdb  
sudo mount /dev/vdb /data
sudo chmod 755 /etc/rc.local
sudo sh -c "echo '/dev/vdb /data xfs defaults 0 0' >> /etc/fstab"

NOTE:

The first two commands only need to be run once (and destroy everything on your disk!). The mount command (third one) only needs to be run once, the final line will do the mounting each time the VM is started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment