James Litchfield
2008-Jul-07 00:05 UTC
[zfs-discuss] Why can''t ZFS find a plugged in disk
Currently on SNV92 + some BFUs but this has bene going on for quite a while. If I boot my system without a USB drive plugged in and then plug it in, rmformat sees it but ZFS seems not to. If I reboot the system, ZFS will have no problem with using the disk.> # zpool import > # rmformat > Looking for devices... > 1. Logical Node: /dev/rdsk/c1t0d0p0 > Physical Node: /pci at 0,0/pci-ide at 1f,2/ide at 1/sd at 0,0 > Connected Device: MATSHITA DVD-RAM UJ-841S 1.40 > Device Type: DVD Reader/Writer > Bus: IDE > Size: 2.8 GB > Label: <None> > Access permissions: Medium is not write protected. > 2. Logical Node: /dev/rdsk/c2t0d0p0 > Physical Node: /pci at 0,0/pci1179,1 at 1d,7/storage at 7/disk at 0,0 > Connected Device: WDC WD16 00BEAE-11UWT0 0000 > Device Type: Removable > Bus: USB > Size: 152.6 GB > Label: <None> > Access permissions: Medium is not write protected. >Perhaps because I didn''t label the disk before giving to ZFS? If so, bad ZFS for either not complaining or else asking me for permission to label the disk. Jim ----
James Litchfield
2008-Jul-07 00:28 UTC
[zfs-discuss] Why can''t ZFS find a plugged in disk
Indeed, after rebooting we see the following. You''ll have to trust me that /ehome and /ehome/v1 are the relevant ZFS filesystems. If it makes any different, this file system had been previously mounted. My memory is suggesting that zpool import works in this situation whenever the FS hasn''t been previously mounted. Jim ---- bash-3.2$ rmformat> ld.so.1: rmformat: warning: libumem.so.1: open failed: No such file in > secure directories > Looking for devices... > 1. Logical Node: /dev/rdsk/c1t0d0p0 > Physical Node: /pci at 0,0/pci-ide at 1f,2/ide at 1/sd at 0,0 > Connected Device: MATSHITA DVD-RAM UJ-841S 1.40 > Device Type: CD Reader > Bus: IDE > Size: 2.8 GB > Label: <None> > Access permissions: Medium is not write protected. > 2. Logical Node: /dev/rdsk/c2t0d0p0 > Physical Node: /pci at 0,0/pci1179,1 at 1d,7/storage at 7/disk at 0,0 > Connected Device: WDC WD16 00BEAE-11UWT0 0000 > Device Type: Removable > Bus: USB > Size: 152.6 GB > Label: <None> > Access permissions: Medium is not write protected. > bash-3.2$ /usr/sbin/mount | egrep ehome > /ehome on ehome > read/write/setuid/devices/nonbmand/exec/xattr/noatime/dev=2d90006 on > Sun Jul 6 17:08:12 2008 > /ehome/v1 on ehome/v1 > read/write/setuid/devices/nonbmand/exec/xattr/noatime/dev=2d90007 on > Sun Jul 6 17:08:12 2008James Litchfield wrote:> Currently on SNV92 + some BFUs but this has bene going on for quite a while. > > If I boot my system without a USB drive plugged in and then plug it in, > rmformat sees it but ZFS seems not to. If I reboot the system, ZFS > will have no problem with using the disk. > > > >> # zpool import >> # rmformat >> Looking for devices... >> 1. Logical Node: /dev/rdsk/c1t0d0p0 >> Physical Node: /pci at 0,0/pci-ide at 1f,2/ide at 1/sd at 0,0 >> Connected Device: MATSHITA DVD-RAM UJ-841S 1.40 >> Device Type: DVD Reader/Writer >> Bus: IDE >> Size: 2.8 GB >> Label: <None> >> Access permissions: Medium is not write protected. >> 2. Logical Node: /dev/rdsk/c2t0d0p0 >> Physical Node: /pci at 0,0/pci1179,1 at 1d,7/storage at 7/disk at 0,0 >> Connected Device: WDC WD16 00BEAE-11UWT0 0000 >> Device Type: Removable >> Bus: USB >> Size: 152.6 GB >> Label: <None> >> Access permissions: Medium is not write protected. >> >> > Perhaps because I didn''t label the disk before giving to ZFS? > If so, bad ZFS for either not complaining or else asking me > for permission to label the disk. > > Jim > ---- > > _______________________________________________ > zfs-discuss mailing list > zfs-discuss at opensolaris.org > http://mail.opensolaris.org/mailman/listinfo/zfs-discuss > >
James Litchfield
2008-Jul-09 02:09 UTC
[zfs-discuss] Why can''t ZFS find a plugged in disk
Turns out zfs mount -a will pick up the file system. Fun question is why the OS can''t mount the disk by itself. gnome-mount is what puts up the "Can''t access the disk" and whines to stdout (/dev/null in this case) about:> ** (gnome-mount:1050): WARNING **: Mount failed for > /org/freedesktop/Hal/devices > /pci_0_0/pci1179_1_1d_7/storage_7_if0_0/scsi_host0/disk1/sd1/p0 > org.freedesktop.Hal.Device.Volume.UnknownFailure : cannot open > ''/dev/dsk/c2t0d0p > 0'': invalid dataset namegnome-mount never attempts to open, access or mount the disk. It comes to the above conclusion after an exchange of messages with hald. Further questions will be directed in that direction. Jim --- James Litchfield wrote:> Indeed, after rebooting we see the following. You''ll have to trust me that > /ehome and /ehome/v1 are the relevant ZFS filesystems. If it makes any > different, this file system had been previously mounted. My memory is > suggesting that zpool import works in this situation whenever the FS > hasn''t been previously mounted. > > Jim > ---- > bash-3.2$ rmformat > >> ld.so.1: rmformat: warning: libumem.so.1: open failed: No such file in >> secure directories >> Looking for devices... >> 1. Logical Node: /dev/rdsk/c1t0d0p0 >> Physical Node: /pci at 0,0/pci-ide at 1f,2/ide at 1/sd at 0,0 >> Connected Device: MATSHITA DVD-RAM UJ-841S 1.40 >> Device Type: CD Reader >> Bus: IDE >> Size: 2.8 GB >> Label: <None> >> Access permissions: Medium is not write protected. >> 2. Logical Node: /dev/rdsk/c2t0d0p0 >> Physical Node: /pci at 0,0/pci1179,1 at 1d,7/storage at 7/disk at 0,0 >> Connected Device: WDC WD16 00BEAE-11UWT0 0000 >> Device Type: Removable >> Bus: USB >> Size: 152.6 GB >> Label: <None> >> Access permissions: Medium is not write protected. >> bash-3.2$ /usr/sbin/mount | egrep ehome >> /ehome on ehome >> read/write/setuid/devices/nonbmand/exec/xattr/noatime/dev=2d90006 on >> Sun Jul 6 17:08:12 2008 >> /ehome/v1 on ehome/v1 >> read/write/setuid/devices/nonbmand/exec/xattr/noatime/dev=2d90007 on >> Sun Jul 6 17:08:12 2008 >> > > > James Litchfield wrote: > >> Currently on SNV92 + some BFUs but this has bene going on for quite a while. >> >> If I boot my system without a USB drive plugged in and then plug it in, >> rmformat sees it but ZFS seems not to. If I reboot the system, ZFS >> will have no problem with using the disk. >> >> >> >> >>> # zpool import >>> # rmformat >>> Looking for devices... >>> 1. Logical Node: /dev/rdsk/c1t0d0p0 >>> Physical Node: /pci at 0,0/pci-ide at 1f,2/ide at 1/sd at 0,0 >>> Connected Device: MATSHITA DVD-RAM UJ-841S 1.40 >>> Device Type: DVD Reader/Writer >>> Bus: IDE >>> Size: 2.8 GB >>> Label: <None> >>> Access permissions: Medium is not write protected. >>> 2. Logical Node: /dev/rdsk/c2t0d0p0 >>> Physical Node: /pci at 0,0/pci1179,1 at 1d,7/storage at 7/disk at 0,0 >>> Connected Device: WDC WD16 00BEAE-11UWT0 0000 >>> Device Type: Removable >>> Bus: USB >>> Size: 152.6 GB >>> Label: <None> >>> Access permissions: Medium is not write protected. >>> >>> >>> >> Perhaps because I didn''t label the disk before giving to ZFS? >> If so, bad ZFS for either not complaining or else asking me >> for permission to label the disk. >> >> Jim >> ---- >> >> _______________________________________________ >> zfs-discuss mailing list >> zfs-discuss at opensolaris.org >> http://mail.opensolaris.org/mailman/listinfo/zfs-discuss >> >> >> > > _______________________________________________ > zfs-discuss mailing list > zfs-discuss at opensolaris.org > http://mail.opensolaris.org/mailman/listinfo/zfs-discuss > >
James Litchfield
2008-Jul-09 18:46 UTC
[zfs-discuss] And the answer to why can''t ZFS find a plugged in disk is ...
From an email exchange with a HAL developer...>> This comes about because I boot back and forth between Windows >> and Solaris and when on the Windows side I have the drive unplugged. >> On occasion, I forget to plug it back in before returning to Solaris. > > I wonder then, if Solaris should export removable ZFS volumes on > shutdown. > >> Seems a strange limitation for HAL to not attempt to mount a zfs file >> system. If it''s not imported the mount fails and an error can be >> generated. If >> it''s imported then everything just works. What was the reasoning for >> this? > > There are multiple reasons. Initially, when HAL was introduced in > Solaris (PSARC 2005/399), ZFS did not support hotplug very well or at > all. Also, HAL''s object model only accomodates traditional single > device volumes; it needs to be expanded to account for ZFS''s volumes > than span multiple devices. There are also more operations than just > mount/unmount possible, and sometimes necessary, on ZFS datasets, and > HAL simply lacks such interfaces. The third problematic area is that > now that ZFS itself includes some sort of hotplug magic, there needs > to be coordination with HAL-based volume managers. There are also > potential difficulties related to different security models between > traditionally mounted filesystems and ZFS. > > In other words, there is nothing fundamentally preventing HAL from > supporting ZFS, but the amount of new design is enough for a > full-blown project. >