montar la unidad ltfs al iniciar el sistema Mac OS X

montar la unidad ltfs al iniciar el sistema Mac OS X

Mac OS X Server 10.6.8
Unidad LTO 5: Unidad de cinta IBM System Storage TS2250
HBA: ExpressSAS H680 de ATTO

He instalado HBA y LTO en mi Mac y puedo formatear y montar los medios de cinta. Me gustaría que el medio de cinta se monte al iniciar el sistema. Creé un LaunchAgent:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"  "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Label</key>
    <string>com.pilotware.ltfs_mount</string>
    <key>ProgramArguments</key>
    <array>
            <string>/usr/local/bin/ltfs</string>
            <string>/mnt/ltfs</string>
            <string>-o</string>
            <string>devname=0</string>
    </array>
    <key>RunAtLoad</key>
    <true/>
</dict>
</plist>


Sin embargo, cada vez que reinicio la máquina, la cinta no se monta, aunque el registro del sistema muestra que sí se montó:

9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS9015W Setting the locale to 'en_US.UTF-8'. If this is wrong, please set the LANG environment variable before starting ltfs.
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS14000I LTFS starting, LTFS version 1.2.5 (201202290), log level 2
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS14058I LTFS Format Specification version 2.0.0
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS14063I Sync type is "time", Sync time is 300 sec
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS12158I Opening a device through iokit driver (0)
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS12118I Drive identification is 'ULT3580-HH5     '
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS12162I Vendor ID is IBM     
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS12159I Firmware revision is BBNF
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS12160I Drive serial is 1068062747
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS17160I Maximum device block size is 1048576
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS11005I Mounting the volume
9/19/12 3:15:32 PM  com.pilotware.ltfs_mount[321]   LTFS12015I Attempting to load the medium
9/19/12 3:15:52 PM  com.pilotware.ltfs_mount[321]   LTFS11031I Volume mounted successfully


Si ejecuto 'mount', el montaje no aparece en la lista. Si ejecuto el comando manualmente, /usr/local/bin/ltfs /mnt/ltfs -o devname=0, el medio de cinta se monta, monte:
ltfs en /mnt/ltfs (osxfusefs, nodev, nosuid, sincrónico, montado por pw )

Intenté encapsular el comando en un script bash y hacer que LaunchAgent ejecutara el script sin éxito. Incluso agregué más opciones, /usr/local/bin/ltfs /mnt/ltfs -o devname=0 -o gid=20 -o uid=501 -o work_directory=/tmp/ltfs

No estoy seguro si es Mac OS X (vi /private/etc/security/audit_control y /etc/security/audit_class abiertos cuando se ejecuta launchd, pero no cuando lo hago manualmente), ltfs (1.2.5) o FUSE (IBM usa OSXFUSE 2.3.8) .
Irónicamente, si lanzo el comando bash en una aplicación de Automator y lo ejecuto como un elemento de inicio de sesión de usuario a través de Preferencias del sistema, la cinta se monta.

Los permisos de LaunchAgent son correctos, probé LaunchDaemons y User LaunchAgents. Incluso edité /etc/security/audit_control, eliminando la política argv y eliminando naflags.

No lo entiendo. Cualquier ayuda se agradece.

Respuesta1

Tuve que agregar:

<string>-f</string>

a la matriz ProgramArguments en LaunchAgent para FUSE para poner en primer plano la operación y ejecutarla correctamente...

información relacionada