Re: Etch: Gnome, Hal & Iomega Clik 40

2007-06-09 Thread Jacob L. Anawalt
Jacob L. Anawalt wrote:
> Does lshal include any merged information when showing it's output?
>   
The answer appears to be yes.

I joined #hal on freenode and mbiebl pointed out that storage.bus in
/usr/share/hal/fdi/preprobe/10osvendor/10-ide-drives.fdi wasn't matching
my pcmcia device. So I put a modified copy of it into
/etc/hal/fdi/preprobe as clik-pcmcia.fdi (attached.) After restarting
hald (invoke-rc.d restart dbus) lshal included the information from
clik-pcmcia.fdi.

Now double-clicking the icon in Gnome was trying to mount the right
volume, but it was failing most of the time. It appeared to be a problem
with the pmount filesystem autodetection routines. From the command line
I would have less than a 10% chance of pmount working without the
filesystem type argument. With it, pmount worked every time. The mount
command worked every time without the argument, so pmount seemed to do a
little more than just wrap mount with a policy.

The easiest solution was to add an entry to /etc/fstab and create
/media/hdc4.

/dev/hdc4   /media/hdc4 vfatuser,noauto 0   0

Since this system is a laptop and hardware isn't changing much, it seems
to be a workable solution. Another option that seemed to work was to use
pmount from the command line with the filesystem type. Once the drive is
mounted, you can get to it via the GUI. (After all this mucking about
it's best to log out and back in to get a fresh view in Gnome from HAL.

I'll try to discover where 10osvendor/10-ide-drives.fdi comes from and
submit a bug report/patch for the pcmcia clik drive if it's not already
fixed in a later version.

-- 
Jacob




  


  
	
	
	
  zip
  true
  true
  
	  4
	
	
  


  



Etch: Gnome, Hal & Iomega Clik 40

2007-06-05 Thread Jacob L. Anawalt
Hello,

I've recently acquired an Iomega Clik! 40 (aka PocketZip) PCMCIA drive
and a few disks with a slick looking silver case.

http://paulbristow.net/main/2002/02/24/clik/

If you know the device, have looked it up, or guessed the 40 means 40
Mb, you're probably thinking "what a useless device, you can pick up CF
cards with more memory from the local discount rack." I acknowledge this
and offer no rational explanation for wanting to get this to work
better. It's just something to try and an opportunity to understand hal
and other systems a little better.

When I insert the PCMCIA card it is recognized. It automatically shows
up in the Computer window next to the other devices, filesystems and
locations in the Gnome desktop. The disks are loaded by a floppy device
driver as /dev/hdc. I can mount /dev/hdc4 by hand just fine. The
automagic ends when I double-click the "External Floppy Drive" icon and
this is where I would like some help.

The attached pmount-error.txt file contains the error displayed on the
desktop when I try double-clicking the drive icon. It looks like it
isn't trying /dev/hdc4. I don't know if this is because of some "auto"
option behaving badly, or if hal isn't merging the contents of
10-ide-drives.fdi no matter where I put it (lshal seems to support this
theory.)

Does lshal include any merged information when showing it's output?

(The attached lshal.txt file shows it's output.)

At first I expected that /usr/share/hal/fdi would be iterated for .fdi
files to load. Then I wondered if I needed to copy files from there to
/etc/hal/fdi. With either lshal doesn't seem to show 4 being appended to
block.device nor is the storage.requires_eject setting set to true.

Any pointers to good documentation on hal (especially anything Debian
specific, if required) or suggestions are appreciated.

-- 
Jacob
libhal-storage.c 1344 : info: called libhal_free_dbus_error but dbuserror was 
not set.
libhal-storage.c 1345 : info: called libhal_free_dbus_error but dbuserror was 
not set.
libhal-storage.c 1401 : info: called libhal_free_dbus_error but dbuserror was 
not set.
process 3151: applications must not close shared connections - see 
dbus_connection_close() docs. this is a bug in the application.
mount: wrong fs type, bad option, bad superblock on /dev/hdc,
   missing codepage or other error
   in some cases useful info is found in syslog - try
   dmesg | tail  or so

error: could not execute pmount


Start monitoring devicelist:
-
pcmcia__1__1 added
pcmcia__1__1_ide_1_0 added
storage_model_IOMEGA_Clik__40_CZ_ATAPI added

lshal output snipped:
-
udi = '/org/freedesktop/Hal/devices/storage_model_IOMEGA_Clik__40_CZ_ATAPI'
  volume.mount.valid_options = {'ro', 'sync', 'dirsync', 'noatime', 
'nodiratime', 'noexec', 'quiet', 'remount', 'exec', 'utf8', 'shortname=', 
'codepage=', 'iocharset=', 'umask=', 'uid='} (string list)
  org.freedesktop.Hal.Device.Volume.method_execpaths = {'hal-storage-mount', 
'hal-storage-unmount', 'hal-storage-eject'} (string list)
  org.freedesktop.Hal.Device.Volume.method_argnames = {'mount_point fstype 
extra_options', 'extra_options', 'extra_options'} (string list)
  org.freedesktop.Hal.Device.Volume.method_signatures = {'ssas', 'as', 'as'} 
(string list)
  org.freedesktop.Hal.Device.Volume.method_names = {'Mount', 'Unmount', 
'Eject'} (string list)
  info.interfaces = {'org.freedesktop.Hal.Device.Volume'} (string list)
  block.storage_device = 
'/org/freedesktop/Hal/devices/storage_model_IOMEGA_Clik__40_CZ_ATAPI'  (string)
  info.udi = 
'/org/freedesktop/Hal/devices/storage_model_IOMEGA_Clik__40_CZ_ATAPI'  (string)
  storage.requires_eject = false  (bool)
  storage.hotpluggable = true  (bool)
  info.capabilities = {'storage', 'block'} (string list)
  info.category = 'storage'  (string)
  info.product = 'IOMEGA Clik! 40 CZ ATAPI'  (string)
  storage.size = 0  (0x0)  (uint64)
  storage.removable = true  (bool)
  storage.removable.media_available = false  (bool)
  storage.physical_device = '/org/freedesktop/Hal/devices/pcmcia__1__1'  
(string)
  storage.vendor = ''  (string)
  storage.model = 'IOMEGA Clik! 40 CZ ATAPI'  (string)
  storage.drive_type = 'floppy'  (string)
  storage.automount_enabled_hint = true  (bool)
  storage.media_check_enabled = false  (bool)
  storage.no_partitions_hint = true  (bool)
  storage.bus = 'pcmcia'  (string)
  block.is_volume = false  (bool)
  block.minor = 0  (0x0)  (int)
  block.major = 22  (0x16)  (int)
  block.device = '/dev/hdc'  (string)
  linux.hotplug_type = 3  (0x3)  (int)
  info.parent = '/org/freedesktop/Hal/devices/pcmcia__1__1_ide_1_0'  (string)
  linux.sysfs_path_device = '/sys/block/hdc'  (string)
  linux.sysfs_path = '/sys/block/hdc'  (string)