First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 116731
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Gentoo's Team for Core System packages <base-system@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Pekka Enberg <penberg@cs.helsinki.fi>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
linux-2.6.16-scsi-eject.patch Patch scsi block for 2.6.16 patch Roy Marples (RETIRED) 2006-04-23 06:40 0000 882 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 116731 depends on: Show dependency tree
Show dependency graph
Bug 116731 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)







View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2005-12-25 13:14 0000
When I try tro unmount Ipod nano volume in Nautilus, I get the following error:
/usr/bin/eject: unable to eject, last error: Invalid argument. I am using dbus,
hal, and ivman and have added myself to the disk group. I can fix the problem
by making /usr/bin/eject a suid binary.

Portage 2.1_pre1 (default-linux/x86/2005.0, gcc-3.3.4, glibc-2.3.5-r3, 2.6.14.4
i686)
=================================================================
System uname: 2.6.14.4 i686 Intel(R) Celeron(R) CPU 2.80GHz
Gentoo Base System version 1.12.0_pre12
dev-lang/python:     2.4.2
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1-r1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r3
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium3 -g"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config
/var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/texmf/web2c /etc/env.d"
CXXFLAGS="-O2 -march=pentium3 -g"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks nostrip sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="en_US.utf8"
LC_ALL="en_US.utf8"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X aac acl acpi adns alsa apm audiofile avi berkdb bitmap-fonts bzip2
cdr crypt cscope cups curl dbus eds emboss encode esd exif expat fam ffmpeg
flac foomaticdb gd gdbm gif glut gnome gphoto2 gpm gstreamer gtk gtk2 guile hal
idn imagemagick imlib ipod ipv6 jack java jpeg junit lcms libg++ libwww mad
mikmod mmx mng mono motif mozilla mp3 mpeg ncurses nls nptl ogg oggvorbis
opengl oss pam pcre pdflib perl png python qt quicktime readline ruby sdl slang
spell sqlite sse sse2 ssl tcltk tcpd tetex tiff truetype truetype-fonts
type1-fonts udev usb vorbis win32codecs xine xml xml2 xmms xv xvid zlib
elibc_glibc kernel_linux userland_GNU"
Unset:  ASFLAGS, CTARGET, LDFLAGS, LINGUAS, MAKEOPTS

------- Comment #1 From Steev Klimaszewski 2005-12-25 13:25:27 0000 -------
are you in the plugdev group?

------- Comment #2 From Pekka Enberg 2005-12-26 03:16:03 0000 -------
> are you in the plugdev group?

Yes, I am.

------- Comment #3 From Pekka Enberg 2005-12-26 05:06:06 0000 -------
> > are you in the plugdev group?
> 
> Yes, I am.

While doing testing for another bug [1], I noticed that I cannot unmount Ipod
nano device when logged in as myself if I plug in the device when X is in the
GDM login screen. So the SUID bit doesn't completely fix the problem.

  https://bugs.gentoo.org/show_bug.cgi?id=116729

------- Comment #4 From Pekka Enberg 2005-12-26 05:07:00 0000 -------
(Please note the I upgraded my kernel and portage so I have included emerge
info here again.)

Portage 2.1_pre2 (default-linux/x86/2005.0, gcc-3.3.4, glibc-2.3.5-r3,
2.6.15-rc7 i686)
=================================================================
System uname: 2.6.15-rc7 i686 Intel(R) Celeron(R) CPU 2.80GHz
Gentoo Base System version 1.12.0_pre12
dev-lang/python:     2.4.2
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1-r1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r3
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium3 -g"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config
/var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/texmf/web2c /etc/env.d"
CXXFLAGS="-O2 -march=pentium3 -g"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks nostrip sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="en_US.utf8"
LC_ALL="en_US.utf8"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X aac acl acpi adns alsa apm audiofile avi berkdb bitmap-fonts bzip2
cdr crypt cscope cups curl dbus eds emboss encode esd exif expat fam ffmpeg
flac foomaticdb gd gdbm gif glut gnome gphoto2 gpm gstreamer gtk gtk2 guile hal
idn imagemagick imlib ipod ipv6 jack java jpeg junit lcms libg++ libwww mad
mikmod mmx mng mono motif mozilla mp3 mpeg ncurses nls nptl ogg oggvorbis
opengl oss pam pcre pdflib perl png python qt quicktime readline ruby sdl slang
spell sqlite sse sse2 ssl tcltk tcpd tetex tiff truetype truetype-fonts
type1-fonts udev usb vorbis win32codecs xine xml xml2 xmms xv xvid zlib
elibc_glibc kernel_linux userland_GNU"
Unset:  ASFLAGS, CTARGET, LDFLAGS, LINGUAS, MAKEOPTS

------- Comment #5 From Pekka Enberg 2005-12-27 05:18:02 0000 -------
I haven't tested this patch [1] yet but it should fix the error. Relevant
discussion is here [2]. I'll report once I have the chance to test it.

1. http://bugzilla.ubuntu.com/attachment.cgi?id=5415
2. http://marc.theaimsgroup.com/?l=linux-kernel&m=113508268711624&w=2

------- Comment #6 From Pekka Enberg 2005-12-27 07:59:30 0000 -------
(In reply to comment #5)
> I haven't tested this patch [1] yet but it should fix the error. Relevant
> discussion is here [2]. I'll report once I have the chance to test it.
> 
> 1. http://bugzilla.ubuntu.com/attachment.cgi?id=5415
> 2. http://marc.theaimsgroup.com/?l=linux-kernel&m=113508268711624&w=2

This patch fixes the permission problem so I don't have the SUID
/usr/bin/eject. Please consider applying.

------- Comment #7 From Saleem Abdulrasool 2006-02-17 15:12:04 0000 -------
Is this bug still reproducible?

------- Comment #8 From Pekka Enberg 2006-02-19 02:56:44 0000 -------
> Is this bug still reproducible?

Yes it is. I have a slightly different configuration now. No ivman, just
gnome-volume-manager. I have downgraded everything to Gentoo stable now (I used
to be ~x86). I still need to chmod u+s /usr/bin/eject for ipod unmount to work
properly.

raquel penberg # emerge info
Portage 2.0.54 (default-linux/x86/2005.0, gcc-3.4.4, glibc-2.3.5-r2, 2.6.15
i686)
=================================================================
System uname: 2.6.15 i686 Intel(R) Celeron(R) CPU 2.80GHz
Gentoo Base System version 1.6.14
dev-lang/python:     2.4.2
sys-apps/sandbox:    1.2.12
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium3 -g"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config
/usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/
/usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/
/usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=pentium3 -g"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks nostrip sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="en_US.utf8"
LC_ALL="en_US.utf8"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X aac acl acpi adns alsa apm audiofile avi berkdb bitmap-fonts bzip2
cdr crypt cscope cups curl dbus eds emboss encode esd exif expat fam ffmpeg
flac foomaticdb gd gdbm gif glut gmp gnome gphoto2 gpm gstreamer gtk gtk2
gtkhtml guile hal idn imagemagick imlib ipod ipv6 jack java jpeg junit lcms
libg++ libwww mad mikmod mmx mng mono motif mozilla mp3 mpeg ncurses nls nptl
ogg oggvorbis opengl oss pam pcre pdflib perl png python qt quicktime readline
ruby sdl slang spell sqlite sse sse2 ssl tcltk tcpd tetex tiff truetype
truetype-fonts type1-fonts udev usb vlc vorbis win32codecs xine xml xml2 xmms
xv xvid zlib userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LDFLAGS, LINGUAS, MAKEOPTS

------- Comment #9 From Roy Marples (RETIRED) 2006-04-23 06:37:51 0000 -------
After getting my iPod and doing some research, this issue is now in two
distinct parts.

1) eject-2.1.4 is required
2) a patch to block/scsi_ioctl.c in linux kernel is required

With patch applied, eject works with my iPod Nano without having to be suid
root.

As such, it's not GNOME bug at all. Re-assigning to kernel team as eject has
already been fixed in portage.

------- Comment #10 From Roy Marples (RETIRED) 2006-04-23 06:40:35 0000 -------
Created an attachment (id=85271) [edit]
Patch scsi block for 2.6.16

Patch ripped from a Ubuntu kernel.

Fixes above issue, request inclusion in gentoo-sources.

------- Comment #11 From Daniel Drake 2006-04-23 08:32:15 0000 -------
Please get that included upstream, and/or fix eject. Ejecting works as a user
over SCSI transport, as long as the device is opened for read+write.

------- Comment #12 From Roy Marples (RETIRED) 2006-04-23 09:10:06 0000 -------
(In reply to comment #11)
> Please get that included upstream, and/or fix eject. Ejecting works as a user
> over SCSI transport, as long as the device is opened for read+write.

eject-2.1.4 is already fixed. 

http://www.ussg.iu.edu/hypermail/linux/kernel/0512.2/0808.html
Note the comment at the bottom - I'll quote here.

>bcollins@colorless:~$ id -a
> uid=1000(bcollins) gid=1000(bcollins)
> groups=4(adm),20(dialout),24(cdrom),25(floppy),29(audio),30(dip),44(video),46(plugdev),104(lpadmin),105(scanner),106(admin),1000(bcollins)
> bcollins@colorless:~$ ls -l /dev/hdc
> brw-rw---- 1 root plugdev 22, 0 Dec 19 2005 /dev/hdc
> bcollins@colorless:~$ eject -s /dev/hdc
> eject: unable to eject, last error: Operation not permitted
> bcollins@colorless:~$ eject -r /dev/hdc
> bcollins@colorless:~$
> 
> Write permissions is not enough.

What is the proper action for getting this included upstream if you won't put
it in gentoo-sources?

------- Comment #13 From Daniel Drake 2006-04-23 09:38:44 0000 -------
That's an eject bug because it opens for read-only.

From "strace eject -s /dev/sdb1":
open("/dev/sdb1", O_RDONLY|O_NONBLOCK)  = 3

I am using eject v2.1.4

------- Comment #14 From Roy Marples (RETIRED) 2006-04-23 15:42:43 0000 -------
You're right, sorry.

------- Comment #15 From Roy Marples (RETIRED) 2006-04-23 15:43:33 0000 -------
I'll take this then and patch eject as it looks like the kernel is now fine.

------- Comment #16 From Roy Marples (RETIRED) 2006-04-23 15:46:42 0000 -------
Fixed in eject-2.1.4-r1

------- Comment #17 From SpanKY 2006-06-11 07:42:26 0000 -------
*** Bug 135229 has been marked as a duplicate of this bug. ***

First Last Prev Next    No search results available      Search page      Enter new bug