ISCSI Storage

From IVS Wiki
Jump to: navigation, search

The following instructions will configure the Valt appliance to store videos on an iSCSI SAN. Prior to performing these steps it is recommend that you configure the Valt appliance with a dedicated NIC for iscsi traffic.

WARNING: This instructions will remove any previously recorded videos. This should only be performed with a new Valt installation.

If you need to perform this operation on an existing Valt server, you must copy the contents of /usr/local/WowzaStreamingEngine/content to your iSCI LUN before proceeding.

  1. Connect to the server via SSH or log in to the teminal
  2. Type sudo apt install open-iscsi and press enter.
    Storage6.png
  3. Type sudo nano /etc/iscsi/iscsid.conf and press enter.
    Storage7.png
  4. Locate the line node.startup = manual and change it to node.startup = automatic
  5. Press CTRL-X
  6. Enter Y to save.
  7. Do not change the file name and press enter.
  8. Type sudo mkdir /mnt/iscsi and press enter.
  9. Type sudo service WowzaStreamingEngine stop and press enter.
  10. Type sudo umount /usr/local/WowzaStreamingEngine/content and press enter.
  11. Type sudo rm -r /usr/local/WowzaStreamingEngine/content and press enter.
  12. Type sudo ln -s /mnt/iscsi /usr/local/WowzaStreamingEngine/content and press enter.
  13. Type sudo iscsiadm -m discovery -t st -p ipaddressofsan and press enter.
    Replace the italicized text with the ip address for your iSCSI SAN.
    Storage9.png
    When you run this command, all available targets will be listed. By default a connection will be established for each available target. You can prevent a target from connecting by running the following command:
    sudo iscsiadm -m node -T iqn.2005-10.org.freenas.ctl:test -o delete
    Replace the italicized text with the iqn for the target you don't want to connect to.
  14. Type sudo iscsiadm -m node --login and press enter.
  15. Type sudo lshw -C disk and press enter.
  16. You should now see a list of the available disks on the machine. Locate the iSCSI disk you just connected. In this case it is /dev/sdb
  17. Type sudo parted /dev/sdb and press enter.
    • Replace /dev/sdb with the appropriate disk identified in step 2.
    Install42.png
  18. You will now be taken to a GNU Parted prompt
  19. Type mklabel gpt and press enter.
  20. Type mkpart pri 1 -1 and press enter.
  21. Type quit and press enter.
  22. Type sudo mkfs -t ext4 /dev/sdb1 and press enter.
    • Replace /dev/sdb1 with the appropriate disk identified in step 2.
  23. Type sudo blkid and press enter.
  24. This will display the UUIDs for each partition. Note the UUID for the partition you just formatted.
  25. Type sudo nano /etc/fstab and press enter.
    Install45.png
  26. Delete the line that mounts the local hard drive in /usr/local/WowzaStreamingEngine/content. It will most likely be the last line in fstab
  27. Add a line for the iSCSI disk. It should read similar to the following:
    UUID=5a8a1dd9-4e21-4753-a473-13416c83b907 /mnt/iscsi ext4 defaults,auto,_netdev 0 0
    Replace the italicized text with the appropriate information for your environment.
    Storage8.png
  28. Press CTRL-X
  29. Enter Y to save.
  30. Do not change the file name and press enter
  31. Type sudo mount -a and press enter.
    Storage3.png
  32. Type sudo /usr/local/valt/bin/Storage and press enter
    In some installation the Storage script may be located at /home/ivsadmin/ValtInstall/Storage. If the script is not in either location, please contact IVS technical support for assistance.
  33. Type sudo service WowzaStreamingEngine start and press enter.

The Valt appliance should now be configured to store all videos on an iSCSI SAN.