Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 260409 - sys-apps/hal-0.5.11-r8: doesn't automount hotplugged eSATA hard drives
Summary: sys-apps/hal-0.5.11-r8: doesn't automount hotplugged eSATA hard drives
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High enhancement (vote)
Assignee: Freedesktop bugs
URL: http://bugs.freedesktop.org/show_bug....
Whiteboard:
Keywords:
: 260625 260666 (view as bug list)
Depends on: 313389
Blocks:
  Show dependency tree
 
Reported: 2009-02-26 17:31 UTC by Dmitry
Modified: 2011-09-18 09:26 UTC (History)
8 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
/etc/hal/fdi/policy/11-x11-synaptics-ubuntu-das.fdi (11-x11-synaptics-ubuntu-das.fdi,4.63 KB, text/plain)
2009-03-26 05:25 UTC, hirakendu
Details
/etc/hal/fdi/policy/99-storage-policy-fixed-drives.fdi (99-storage-policy-fixed-drives.fdi,1.25 KB, text/plain)
2009-03-26 05:28 UTC, hirakendu
Details
Improved policy file of Comment #14 (99-storage-policy-fixed-drives.fdi,1.21 KB, text/plain)
2010-08-24 12:42 UTC, tbartdev
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry 2009-02-26 17:31:10 UTC
after upgarding from 0.5.11-r1 to 0.5.11-r8 i've lost all my /media/drive-X automounted ntfs volumes. I've formated an usb pen drive in ntfs and it was sucsessfully automounted to /media/disk.

Downgrading to 0.5.11-r1 helps. All volumes are automounted as well.

Reproducible: Always

Steps to Reproduce:
1. upgrade hal to 0.5.11-r1
2. reboot
3. In gnome DE try to find your local ntfs volumes in /media



Expected Results:  
the local drives shoud be automounted as it allways happed at least last year.

emerge --info
Portage 2.1.6.7 (default/linux/x86/2008.0, gcc-4.1.2, glibc-2.6.1-r0, 2.6.27-gentoo-r8 i686)
=================================================================
System uname: Linux-2.6.27-gentoo-r8-i686-Intel-R-_Core-TM-2_CPU_6600_@_2.40GHz-with-glibc2.0
Timestamp of tree: Wed, 25 Feb 2009 00:30:01 +0000
app-shells/bash:     3.2_p39
dev-java/java-config: 2.1.6-r1
dev-lang/python:     2.5.2-r7
dev-util/cmake:      2.4.8
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.63
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=prescott -O2 -pipe "
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-march=prescott -O2 -pipe "
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="ru_RU.UTF-8"
LC_ALL=""
LDFLAGS="-Wl,-O1"
LINGUAS="ru en"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://172.16.1.1/gentoo-portage"
USE="7zip X a52 aac acl acpi aiglx alsa animgif apache2 async audiofile automount bash-completion berkdb bonobo bzip2 c++ cairo cdaudio cdr cdrom charconv chardet chm cli cpio cpudetection cracklib crypt cups dbus disk-partition divx djvu dmi dri dts dv dvd dvdnav dvdr dvdread dvi emerald esd evolution exif fam fat fax fbcon ffmpeg flac fortran ftp gd gdbm gedit gif gimpprint glitz gmail gmedia gnome gnome-print gnomedb gnuplot gpm graphviz gs gstreamer gtk gtkhtml hal iconv icq ieee1394 imap imlib iproute2 isdnlog jabber java java5 javascript jpeg jpeg2k kqemu lame libnotify logrotate mad matroska midi mjpeg mmx mmxext mng mouse mozdevelop mp2 mp3 mp4 mp4live mpeg mpeg2 mpi mplayer mudflap nautilus ncurses nls nptl nptlonly nsplugin ntfs nvidia objc objc++ ogg openal opengl openmp openssh openssl pam pcre pdf perl png ppds pppd python quicktime quotas radio rar rdesktop readline reflection rt73usb samba scanner session sms snmp sockets socks5 speex spl sqlite sse sse2 ssl svg sysfs syslog tcpd tga threads tiff trayicon truetype type1 uml unicode usb v4l v4l2 vcd vorbis wav win32codecs wma wmf wmp x86 xcb xcomposite xine xinerama xml xorg xpm xscreensaver xulrunner xv xvid zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="ru en" USERLAND="GNU" VIDEO_CARDS="fbdev glint i810 intel mach64 mga neomagic nv r128 radeon savage sis tdfx trident vesa vga via vmware voodoo"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 1 Rafał Mużyło 2009-02-26 18:43:54 UTC
You didn't lose them, they're still there.

And seriously, it's not really a bug:
99-storage-policy-fixed-drives.fdi sets drives that are both
not hotpluggable and not removable to be ignored by hal.

That's seems like a sane setting, cause, as those drives are most
probably fixed, so they should have entries in /etc/fstab.
Comment 2 Dmitry 2009-02-26 19:07:56 UTC
(In reply to comment #1)
> You didn't lose them, they're still there.
> 
> And seriously, it's not really a bug:
> 99-storage-policy-fixed-drives.fdi sets drives that are both
> not hotpluggable and not removable to be ignored by hal.
> 
> That's seems like a sane setting, cause, as those drives are most
> probably fixed, so they should have entries in /etc/fstab.
> 

Thanks a lot. Removing 99-storage-policy-fixed-drives.fdi helped. In my sircumstances i can't write hard all drives to fstab as i plug/unplug sata drives from time to time (like a big floppy) so automouinting is the perfect way to manage them.
Comment 3 Rafał Mużyło 2009-02-28 21:49:10 UTC
*** Bug 260666 has been marked as a duplicate of this bug. ***
Comment 4 Rafał Mużyło 2009-03-01 01:08:05 UTC
*** Bug 260625 has been marked as a duplicate of this bug. ***
Comment 5 Marco DR 2009-03-01 21:15:24 UTC
Please re-open this bug. I had the same problem, and it took me half a day to realise why my eSATA disk was not hotplugging anymore. 

The problem is that 99-storage-policy-fixed-drives.fdi tells hal to ignore any drive where "storage.hotpluggable = false". This is unacceptable for eSATA drives, as they are NOT recognised as hotpluggable (using AHCI driver, where hotplugging is actually supported).
Comment 6 Dmitry 2009-03-02 07:35:10 UTC
Comment  #5 From Marco DR  2009-03-01 21:15:24 0000 
Comment 7 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-03-02 09:11:27 UTC
please bring this matter upstream. This setting can be reverted locally in /etc/hal/... eSATA disks not being dectected as external disks might simply be not solvable but upstream is certainly more knowledgeable on information exposed by the kernel, etc.
Comment 8 Marco DR 2009-03-02 10:01:44 UTC
Gilles, this problem has nothing to do with upstream. It was introduced in version 0.5.11-r2 by fixing another bug, http://bugs.gentoo.org/show_bug.cgi?id=232195
The vanilla version of hal 0.5.11 doesn't ship with 99-storage-policy-fixed-drives.fdi.

Comment 9 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-03-02 10:30:33 UTC
this is still an upstream matter because eSATA disks are external and should be detected as such...
Comment 10 Marco DR 2009-03-02 12:25:51 UTC
You're right. The fact that eSATA are not recognised differently from normal SATA devices is an upstream bug. It is also already reported at Freedesktop: http://bugs.freedesktop.org/show_bug.cgi?id=12127

But until this is solved, the problem here is to understand whether it is worse for the user to have too many devices recognised (SATA + eSATA) or too few (none of these). I would opt for the latter, and eliminate the file 99-storage-policy-fixed-drives.fdi from gentoo. The user can always decide to hide single SATA drives if he likes to.
Comment 11 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-03-02 12:48:28 UTC
imho, eSATA users are really a small portion of sata users and this change would hit each desktop out there and start showing things that were kept hidden for over a year so I'm not really hot about changing this given that hal allows you to invert that rule for specific devices if you really want it. On the other hand, I've looked at the upstream bug and it seems the issue stalled for a while already. I will try to push things forward.
Comment 12 hirakendu 2009-03-26 05:25:47 UTC
Created attachment 186295 [details]
/etc/hal/fdi/policy/11-x11-synaptics-ubuntu-das.fdi
Comment 13 hirakendu 2009-03-26 05:26:13 UTC
This default Gentoo hal policy (99-storage-policy-fixed-drives.fdi) is not really reasonable. While it is easy enough to edit fstab and add them, I think it would be nice if internal hard drive partitions are auto mounted. This policy sort of negates the benefits of hal mounting. Two things:

1) Gnome shouldn't show all mounted partitions on desktop by default. Sure showing up a recently plugged in cdrom / usb-stick on desktop is useful, but the clutter is bad. May be just a tray icon notification? The volumes_visble key in gconf should be disabled by default and its useful to have computer_icon_visible to be enabled by default. (To change them, use gconf-editor and set these keys in apps -> nautilus -> desktop.

2) The Gentoo HAL package should inform about this policy when emerging hal. (Afaik, it doesn't at the moment.) There should be also an example script, say /etc/hal/fdi/policy/99-storage-policy-fixed-drives.fdi, similar to touchpad (synaptics) hal script, that can help customize the behavior, for example hide system partitions etc. I have attached one such example (it reverts the gentoo policy - which can be commented out, and has a commented out example to hide a partition.)
Comment 14 hirakendu 2009-03-26 05:28:35 UTC
Created attachment 186296 [details]
/etc/hal/fdi/policy/99-storage-policy-fixed-drives.fdi

Oops, ignore the wrong attachment from last time.
Comment 15 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-03-26 09:25:44 UTC
(In reply to comment #13)
> This default Gentoo hal policy (99-storage-policy-fixed-drives.fdi) is not
> really reasonable.

this has already been discussed in other bugs, on the upstream ml, and probably in some other places you could find by searching. I think that given the amount of information the hal ebuild prints at installation, it would probably be a good idea to start writing some comprehensive documentation.

Adding chainsaw since he might have ideas here.
Comment 16 David D. Huff Jr. 2009-06-22 19:05:02 UTC
I am stunned to think that internal hard drives must be in the fstab. -r9 has the same PROBLEM
Comment 17 Nirbheek Chauhan (RETIRED) gentoo-dev 2009-06-24 18:24:06 UTC
(In reply to comment #16)
> I am stunned to think that internal hard drives must be in the fstab. -r9 has
> the same PROBLEM
> 

Internal hard drives needing to be in fstab is NOT a bug, it's a security feature. (You would not want internal partitions not mounted by fstab to show up on any random user's desktop, automounting is for EXTERNAL DEVICES hotplugged by the logged-in user)

The upstream bug is about eSATA hard disks which are hot-pluggable being considered fixed instead.
Comment 18 tbartdev 2010-08-24 12:39:44 UTC
Comment #14 works like a charm for me.

For those who struggle like I did to hide internal disks: use the commented paragraph in the fdi file.

BUT!

You will get
error in fdi file /etc/hal/fdi/policy/99-storage-policy-fixed-drives.fdi:32: junk after document element
in your syslog.

This is because <deviceinfo> is the root node of this XML file and it may not appear twice.
My suggestion is to use the attached fdi file...
Comment 19 tbartdev 2010-08-24 12:42:23 UTC
Created attachment 244397 [details]
Improved policy file of Comment #14

</deviceinfo> node moved to the end
Comment 20 Samuli Suominen (RETIRED) gentoo-dev 2011-09-18 09:26:58 UTC
sys-apps/hal was removed from tree wrt #313389, closing as OBSOLETE