Changeset 2913 in MondoRescue


Ignore:
Timestamp:
Dec 9, 2011, 8:26:23 PM (12 years ago)
Author:
Bruno Cornec
Message:
  • Fix #358 by using an external program (hpsa_obdr_mode) which can set the mode of the tape to CD-ROM or Sequential at will.

That program will have to be downloaded from http://cciss.sf.net

Location:
branches/3.0/mindi
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/3.0/mindi/mindi

    r2907 r2913  
    26462646    if [ -d "/lib/firmware" ]; then
    26472647        cp -rp /lib/firmware $mountpoint/lib
     2648    fi
     2649
     2650    # Copy an additional ProLiant tool for OBDR support
     2651    if [ -f $MINDI_TMP/OBDR ]; then
     2652        if [ -x /usr/bin/hpsa_obdr_mode ]; then
     2653            mkdir -p $mountpoint/usr/bin
     2654            cp -a /usr/bin/hpsa_obdr_mode $mountpoint/usr/bin
     2655            LogIt "Copying /usr/bin/hpsa_obdr_mode to ramdisk for improved OBDR support"
     2656        else
     2657            LogAll "WARNING: You're using OBDR mode without having the /usr/bin/hpsa_obdr_mode tool"
     2658            LogAll "         This may lead to a tape not going back to sequential mode after OBDR boot"
     2659        fi
    26482660    fi
    26492661
  • branches/3.0/mindi/rootfs/etc/init.d/rcS

    r2908 r2913  
    652652EnableCcissIfAppropriate() {
    653653    local f
     654
     655    # In some cases, the OBDR tape remains in CD-ROM mode. This branch solves that issue (#498)
     656    if [ "`grep -i 'obdr ' /tmp/mondo-restore.cfg 2>/dev/null`" ] && [ -x /usr/bin/hpsa_obdr_mode ]; then
     657            for lun in `/usr/bin/hpsa_obdr_mode -m query /dev/cciss/* 2>&1 | grep "is an OBDR device" | cut -d' ' -f4`; do
     658            /usr/bin/hpsa_obdr_mode -m query -l $lun /dev/cciss/* 2>&1 | grep -q "is in CD-ROM mode"
     659            if [ $? -eq 0 ]; then
     660                # This tape/lun should be brought back in Sequential mode
     661                LogIt "Putting back tape $lun in Sequential mode..."
     662                /usr/bin/hpsa_obdr_mode -m tape -l $lun /dev/cciss/* 2>&1 > /dev/null
     663            fi
     664        done
     665    fi
     666
     667    # Now engage all Smart Array controllers to detect attached devices
    654668    for f in /proc/driver/cciss/cciss* ; do
    655669        LogIt "Engaging $f"
Note: See TracChangeset for help on using the changeset viewer.