How to Mount iSCSI NAS to Bacula SD

For performance issues, you should only use iSCSI to present storage disk to your Bacula Storage Daemon for backup writing. Always avoid CIFS or NFS sharing since they have natural protocol limitations.

1. Install iscsi tools:

# CentOS & RedHad
yum install iscsi-initiator-utils

# Ubuntu & Debian
apt-get install open-iscsi

If your storage requires you will need to know the unique name of your server iSCSI in order to access the disks. This information can be fetched or changed at the following file:

cat /etc/iscsi/initiatorname.iscsi

2. Start the iscsi daemon:

# CentOS & RedHad
service iscsi start

# Ubuntu & Debian
service open-iscsi start

3. In your NAS web console, create the disk and/or pool that Bacula will access. I’m not using password authentication at this tutorial. If you need the IQN of your Bacula machine, fill it with the information fetched in step 1.

4. Test the connection and fetch your STORAGE IQN. From the Bacula server:

iscsiadm -m discovery -t sendtargets -p

5. Now login to your storage for the first time. Replace the example IQN for the one obtained in the last step:

iscsiadm -m node --targetname "" --portal "" --login

6. Verify the dmesg messages in order to verify the disk presentation to the operating system:


7. You should be able to see the new disk device with the command:

fdisk -l

8. Create a new partition with fdisk(e.g. – follow fdisk partition creating

fdisk /dev/sdb

9. Create a FS:

mkfs.xfs /dev/sdb1

10. Fetch your storage disk unique ID:

blkid /dev/sdb1

11. Use the information to add a new line to fstab, so the storage is always mounted to the Operational System:

vi /etc/fstab

# add similar line
UUID=50b6c967-f903-4144-880d-e85c64c8905b /mnt/backup ext4 _netdev,user=bacula,rw 0 0

12. Mount your new disk:

mount /mnt/backup

13. Make sure your Bacula Storage all daemon disk devices from the desired Autochanger has “Archive Device” configured to write backups to the same path:

Archive Device = /mnt/backup

Disponível em: pt-brPortuguês (Portuguese (Brazil)) enEnglish

Leave a Reply

Close Menu