Re: hotplugd(8) mount flash drive

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: OpenBSD Misc <misc@...>
Date: Tuesday, January 29, 2008 - 6:01 am

On Jan 29, 2008 12:24 AM, Chris wrote:

I figured (from /var/log/messages) that the flash drive is mounted as
"JetFlash" so I changed the script to reflect this and still no luck.
Following the /var/log/message after the flash drive is plugged in and
also the new modified script.

Jan 29 19:40:44 red /bsd: sd1 detached
Jan 29 19:40:44 red /bsd: scsibus2 detached
Jan 29 19:40:44 red /bsd: umass0 detached
Jan 29 19:40:47 red /bsd: umass0 at uhub0 port 2 configuration 1 interface 0
Jan 29 19:40:47 red /bsd:
Jan 29 19:40:47 red /bsd: umass0: JetFlash Mass Storage Device, rev
2.00/1.41, addr 2
Jan 29 19:40:47 red /bsd: umass0: using SCSI over Bulk-Only
Jan 29 19:40:47 red /bsd: scsibus2 at umass0: 2 targets
Jan 29 19:40:47 red /bsd: sd1 at scsibus2 targ 1 lun 0: SCSI2 0/direct removable
Jan 29 19:40:47 red /bsd: sd1: 7799MB, 994 cyl, 255 head, 63 sec, 512
bytes/sec, 15974398 sec total

#!/bin/sh

DEVCLASS=$1
DEVNAME=$2

case $DEVCLASS in
2)
# disk devices

disklabel=`/sbin/disklabel $DEVNAME 2>&1 | \
sed -n '/^label: /s/^label: //p'`
case $disklabel in
JetFlash)
# flash drive
mount /dev/"$DEVNAME"i /mnt/flash
;;
esac
;;
3)
# network devices

/sbin/dhclient $DEVNAME

;;
esac

Is there anything I am doing wrong? Thanks for any help.

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
hotplugd(8) mount flash drive, Chris, (Tue Jan 29, 4:24 am)
Re: hotplugd(8) mount flash drive, Chris, (Tue Jan 29, 6:01 am)
Re: hotplugd(8) mount flash drive, Heinrich Rebehn, (Tue Jan 29, 6:35 am)
Re: hotplugd(8) mount flash drive, Chris, (Fri Feb 1, 2:40 am)
Re: hotplugd(8) mount flash drive, Johan Fredin, (Fri Feb 1, 7:30 am)
Re: hotplugd(8) mount flash drive, frantisek holop, (Fri Feb 1, 7:19 am)
Re: hotplugd(8) mount flash drive, Chris, (Fri Feb 1, 7:43 am)
Re: hotplugd(8) mount flash drive, Johan Fredin, (Tue Jan 29, 6:26 am)
Re: hotplugd(8) mount flash drive, frantisek holop, (Tue Jan 29, 11:35 am)