Adding in a SAS card renumbered my devices

Last night, I added a SAS card into a box which is connected to a tape library (photos here). After starting up the box, Nagios reported that the tape device was no longer present. I first added such checks back in 2012 and updated them for more recent acquisitions.

This means that the copy-to-tape jobs did not run last night, because there was no sa0, instead, there was an sa1, which was not very useful to Bacula.

This is what I saw when I went to fix the issue:

$ ls -l /dev/*sa*
crw-rw----  1 root  operator  0x78 Mar  2 00:55 /dev/esa1
crw-rw----  1 root  operator  0x77 Mar  2 00:55 /dev/nsa1
crw-rw----  1 root  operator  0x76 Mar  2 00:55 /dev/sa1
crw-rw----  1 root  operator  0x75 Mar  2 00:55 /dev/sa1.ctl

$ sudo camcontrol devlist
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 2 lun 0 (da0,pass0)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 10 lun 0 (da1,pass1)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 11 lun 0 (da2,pass2)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 12 lun 0 (da3,pass3)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 13 lun 0 (da4,pass4)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 14 lun 0 (da5,pass5)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 16 lun 0 (da6,pass6)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 17 lun 0 (da7,pass7)
<TOSHIBA DT01ACA300 MX6OABB0>      at scbus2 target 0 lun 0 (ada0,pass8)
<CT480BX200SSD1 MU01.4>            at scbus5 target 0 lun 0 (ada1,pass9)
<CT480BX200SSD1 MU01.4>            at scbus6 target 0 lun 0 (ada2,pass10)
<TOSHIBA DT01ACA300 MX6OABB0>      at scbus6 target 1 lun 0 (ada3,pass12)
<COMPAQ SuperDLT1 5F5F>            at scbus8 target 1 lun 0 (sa1,pass13)
<COMPAQ MSL5000 Series 0520>       at scbus8 target 3 lun 0 (ch0,pass14)

I went into /boot/device.hints and found this:

# sa0 should be the Compaq library
hint.sa.0.at="scbus7"
hint.sa.0.target="1"
hint.sa.0.unit="0"
 
# ch0 is the Compaq auto-changer
hint.pass.11.at="scbus7"
hint.pass.11.target="3"
hint.pass.11.unit="0"

If you look at lines 19 & 20 above, you can see that I needed to change scbus7 to scbus8. I did that, and rebooted.

Now I have:

$ ls -l /dev/*sa*
crw-rw----  1 root  operator  0x78 Mar  2 22:09 /dev/esa0
crw-rw----  1 root  operator  0x77 Mar  2 22:09 /dev/nsa0
crw-rw----  1 root  operator  0x76 Mar  2 22:09 /dev/sa0
crw-rw----  1 root  operator  0x75 Mar  2 22:09 /dev/sa0.ctl

$ sudo camcontrol devlist
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 2 lun 0 (da0,pass0)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 10 lun 0 (da1,pass1)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 11 lun 0 (da2,pass2)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 12 lun 0 (da3,pass3)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 13 lun 0 (da4,pass4)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 14 lun 0 (da5,pass5)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 16 lun 0 (da6,pass6)
<ATA TOSHIBA DT01ACA3 ABB0>        at scbus1 target 17 lun 0 (da7,pass7)
<TOSHIBA DT01ACA300 MX6OABB0>      at scbus2 target 0 lun 0 (ada0,pass8)
<CT480BX200SSD1 MU01.4>            at scbus5 target 0 lun 0 (ada1,pass9)
<CT480BX200SSD1 MU01.4>            at scbus6 target 0 lun 0 (ada2,pass10)
<TOSHIBA DT01ACA300 MX6OABB0>      at scbus6 target 1 lun 0 (ada3,pass12)
<COMPAQ SuperDLT1 5F5F>            at scbus8 target 1 lun 0 (sa0,pass13)
<COMPAQ MSL5000 Series 0520>       at scbus8 target 3 lun 0 (ch0,pass11)

Nagios is happy. Bacula is happy. I’m happy.

Website Pin Facebook Twitter Myspace Friendfeed Technorati del.icio.us Digg Google StumbleUpon Premium Responsive

Leave a Comment

Scroll to Top