Skip to content

Instantly share code, notes, and snippets.

@joshuaob
Created June 20, 2017 12:53
Show Gist options
  • Save joshuaob/eb30b03aabd63681b564baf7c893c7fc to your computer and use it in GitHub Desktop.
Save joshuaob/eb30b03aabd63681b564baf7c893c7fc to your computer and use it in GitHub Desktop.

Revisions

  1. joshuaob created this gist Jun 20, 2017.
    23 changes: 23 additions & 0 deletions example.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,23 @@
    # format and mount volume according to Digital Ocean instructions
    # I followed the instructions found by clicking the "config instructions" link on the volume
    #
    $ sudo mkfs.ext4 -F /dev/disk/by-id/scsi-0DO_Volume_volume-fra1-01
    $ sudo mkdir -p /mnt/volume-fra1-01;
    $ sudo mount -o discard,defaults /dev/disk/by-id/scsi-0DO_Volume_volume-fra1-01 /mnt/volume-fra1-01;
    $ echo /dev/disk/by-id/scsi-0DO_Volume_volume-fra1-01 /mnt/volume-fra1-01 ext4 defaults,nofail,discard 0 0 | sudo tee -a /etc/fstab
    $ sudo reboot
    $ ls /mnt/
    #
    # the volume existed at this point
    #
    $ ls /mnt/volume-fra1-01/
    $ cd /mnt
    $ cd volume-fra1-01/
    $ sudo mkdir var
    $ cd var/
    $ sudo mkdir lib
    $ cd lib/
    $ sudo mkdir elasticsearch
    $ cd elasticsearch/
    $ cd
    $ sudo chown -R elasticsearch:elasticsearch /mnt/volume-fra1-01/var/lib/elasticsearch/