Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Discussion & Documentation Documentation, Tips & Tricks
  • Search

Automounting in userspace with ivman

Unofficial documentation for various parts of Gentoo Linux. Note: This is not a support forum.
Post Reply
Advanced search
706 posts
  • Page 1 of 29
    • Jump to page:
  • 1
  • 2
  • 3
  • 4
  • 5
  • …
  • 29
  • Next
Author
Message
Redeeman
l33t
l33t
User avatar
Posts: 958
Joined: Thu Sep 25, 2003 9:02 am
Location: Portugal

Automounting in userspace with ivman

  • Quote

Post by Redeeman » Mon Jun 14, 2004 2:22 pm

what will i learn?
you will learn how to setup ivman to automount cdrom, dvd etc. using D-BUS and HAL
what do i need to do this?
you need to use udev.
and hopefully you hate supermount :)

first, you need to have hal-cvs and dbus-cvs installed.
for that, you need some ebuilds. i made them.
but, to get them, we need subversion (you are most likely too lazy to download all files manually)

Code: Select all

emerge subversion
when thats done, we go into our portage overlay (/usr/local/portage)
and then we checkout what we need.

Code: Select all

cd /usr/local/portage
svn co http://kaspersandberg.com/fluidportage/trunk/eclass
mkdir sys-apps
cd sys-apps
svn co http://kaspersandberg.com/fluidportage/trunk/sys-apps/dbus-cvs/
svn co http://kaspersandberg.com/fluidportage/trunk/sys-apps/hal-cvs/
svn co http://kaspersandberg.com/fluidportage/trunk/sys-apps/ivman-cvs/
great, now we have the ebuilds we need. then:

Code: Select all

 ACCEPT_KEYWORDS="~arch" emerge hal-cvs
then emerge ivman-cvs

Code: Select all

 ACCEPT_KEYWORDS="~arch" emerge ivman-cvs
great.
start dbus, and hal (hal implies dbus)

Code: Select all

/etc/init.d/hald start
no errors? fine!
then edit the files in /etc/ivman for your needs.
then we start ivman

Code: Select all

/etc/init.d/ivman start
great! insert a cd and look if it gets mounted!
(hooray! it works! (we hope))
but now, you might want it to mount as another user than root, to have permissions,
then do:

Code: Select all

nano -w /etc/conf.d/ivman
to suit your needs ;) should be very selv explainary

Trobleshooting
if ivman doesent work, stop it:

Code: Select all

/etc/init.d/ivman stop
and edit the base config

Code: Select all

nano -w /etc/ivman/IvmConfigBase.xml
disable fork, and set debugging to true.
then start ivman from console

Code: Select all

ivman
and save the messages, and come to either #love-sources or #ivman @ freenode to seek help
Last edited by Redeeman on Fri Jul 30, 2004 10:28 pm, edited 2 times in total.
Top
memborg
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 121
Joined: Mon Jun 16, 2003 2:23 am
Location: Aalborg, Denmark

  • Quote

Post by memborg » Mon Jun 14, 2004 8:47 pm

What to do after this installment?
I was using supermount before and had set up my fstab to use that... What do i do now?
My fstab

Code: Select all


/dev/hda1		/boot		ext2		noauto,noatime		1 2
/dev/hda3		/		reiserfs	noatime			0 1
/dev/hda2		none		swap		sw			0 0
none			/mnt/cdrom	supermount      fs=auto,dev=/dev/cdroms/cdrom0  	0 0
#/dev/fd0		/mnt/floppy	auto		noauto			0 0
none			/mnt/usbstick	supermount	fs=auto,dev=/dev/sda1	0 0
# NOTE: The next line is critical for boot!
none			/proc		proc		defaults		0 0
Besides this question anything else whent fine... :D
Top
Redeeman
l33t
l33t
User avatar
Posts: 958
Joined: Thu Sep 25, 2003 9:02 am
Location: Portugal

  • Quote

Post by Redeeman » Mon Jun 14, 2004 10:04 pm

you just create the fstab like you would do without supermount
Top
oiper
Guru
Guru
User avatar
Posts: 316
Joined: Thu May 01, 2003 7:39 pm
Location: Alabama, US
Contact:
Contact oiper
Website

great!

  • Quote

Post by oiper » Tue Jun 15, 2004 4:13 am

I do have a sour taste from supermount. I have installed all with no problems, but I have no /etc/conf.d/ivman file. Any ideas? B/c I need user permission. Maybe post it? :?:
www.bearscanfly.org - Because hiking is cool
Top
eikketk
Apprentice
Apprentice
User avatar
Posts: 270
Joined: Tue Jun 03, 2003 1:34 pm
Location: Belgium
Contact:
Contact eikketk
Website

  • Quote

Post by eikketk » Tue Jun 15, 2004 6:40 am

memborg wrote:What to do after this installment?
I was using supermount before and had set up my fstab to use that... What do i do now?
Automounting of USB stick isnt supported (yet).

You cdrom like should be like this:

Code: Select all

/dev/cdroms/cdrom0      /mnt/cdrom      iso9660         noauto,ro              0 0
and you need to edit /etc/ivman/IvmConfigMappings.xml. Remove the comment tags (<!-- -->) around the sample line, and edit it apropriate, i.e. change /dev/hdc so it points to the correct /dev entry (which could be hdc of course).
Working day and night to enhance the Linux Desktop Experience :)

Homepage
Top
memborg
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 121
Joined: Mon Jun 16, 2003 2:23 am
Location: Aalborg, Denmark

  • Quote

Post by memborg » Tue Jun 15, 2004 8:06 am

Thanx...

That should be it then? Great...

Well i hope maybe in the next version of ivman there could be support for usbsticks and other mass storage devices... :D
Top
frisbee
n00b
n00b
Posts: 27
Joined: Fri May 02, 2003 4:31 am
Location: Santa Cruz, California

  • Quote

Post by frisbee » Tue Jun 15, 2004 3:39 pm

I get this build error:

pyrexc dbus_bindings.pyx
/usr/lib/python2.3/site-packages/Plex/Transitions.py:85: SyntaxWarning: argument named None
def get_epsilon(self,
/var/tmp/portage/dbus-cvs-20040522/work/dbus-cvs/python/dbus_bindings.pyx:415:56: C function declaration not allowed here

What now?
Top
eikketk
Apprentice
Apprentice
User avatar
Posts: 270
Joined: Tue Jun 03, 2003 1:34 pm
Location: Belgium
Contact:
Contact eikketk
Website

  • Quote

Post by eikketk » Tue Jun 15, 2004 4:14 pm

USE="-python" emerge dbus-cvs
Working day and night to enhance the Linux Desktop Experience :)

Homepage
Top
Redeeman
l33t
l33t
User avatar
Posts: 958
Joined: Thu Sep 25, 2003 9:02 am
Location: Portugal

  • Quote

Post by Redeeman » Tue Jun 15, 2004 5:38 pm

hehe
Top
frisbee
n00b
n00b
Posts: 27
Joined: Fri May 02, 2003 4:31 am
Location: Santa Cruz, California

  • Quote

Post by frisbee » Tue Jun 15, 2004 8:51 pm

Okay, so now its installed and running. I have a DVD writer that I use as my dvd/cdrom reader. I inserted a dvd with a e2fs file system on it and it did not automount. I could manually mount it but that's not the goal.

No messages in the log file. /dev/cdrom is a link to /dev/ide/host0/bus1/target0/lun0/cd

I uncommented the /dev/hdc line in IvmConfigMappings.xml and tried the debugging mode. No output. I think hald is not reporting correctly.

Here is my fstab entry:

/dev/cdroms/cdrom0 /mnt/cdrom auto noauto,noatime,ro 0 0
Top
Redeeman
l33t
l33t
User avatar
Posts: 958
Joined: Thu Sep 25, 2003 9:02 am
Location: Portugal

  • Quote

Post by Redeeman » Tue Jun 15, 2004 8:56 pm

did u remember to install hal and dbus-cvs? :)
Top
frisbee
n00b
n00b
Posts: 27
Joined: Fri May 02, 2003 4:31 am
Location: Santa Cruz, California

  • Quote

Post by frisbee » Tue Jun 15, 2004 9:01 pm

I followed the initial HOW-TO to the letter. Here is whay I emerged:

* sys-apps/hal-cvs
Latest version available: 20040522
Latest version installed: 20040522

* sys-apps/dbus-cvs
Latest version available: 20040522
Latest version installed: 20040522

* sys-apps/ivman-cvs
Latest version available: 20040524
Latest version installed: 20040524
Top
Redeeman
l33t
l33t
User avatar
Posts: 958
Joined: Thu Sep 25, 2003 9:02 am
Location: Portugal

  • Quote

Post by Redeeman » Tue Jun 15, 2004 9:12 pm

then i dont know, must be some ivman error, talk to eikke
Top
GlooM
Tux's lil' helper
Tux's lil' helper
Posts: 119
Joined: Sun Jul 13, 2003 7:42 pm
Location: $HOME

  • Quote

Post by GlooM » Tue Jun 15, 2004 9:30 pm

Redeeman,
the svn command fails saying the server is down, :| ?

Hmm, opera opened the svn links easily, guess ill dl the ebuilds manually.
Top
GlooM
Tux's lil' helper
Tux's lil' helper
Posts: 119
Joined: Sun Jul 13, 2003 7:42 pm
Location: $HOME

  • Quote

Post by GlooM » Tue Jun 15, 2004 10:10 pm

I get this on hal compilation:

configure: error: cannot find pci.ids. Use --with-hwdata to specify location

!!! ERROR: sys-apps/hal-cvs-20040522 failed.
!!! Function src_compile, Line 33, Exitcode 1
!!! (no error message)

well, using locate i found where pci.ids was, and edited the ebuild,
so the configuration would contain --with-hwdata=/path/to/file ,it seems
to have compiled. Cheers :D

ahh, bad luck again:

FATAL ERROR: Autoconf version 2.50 or higher is required for this script
Running autoconf...
FATAL ERROR: Autoconf version 2.50 or higher is required for this script

!!! ERROR: sys-apps/ivman-cvs-20040524 failed.
!!! Function econf, Line 367, Exitcode 1
!!! no configure script found

i have autoconf 2.57, what gives ?
remerging autoconf solved this :)
Top
eikketk
Apprentice
Apprentice
User avatar
Posts: 270
Joined: Tue Jun 03, 2003 1:34 pm
Location: Belgium
Contact:
Contact eikketk
Website

  • Quote

Post by eikketk » Wed Jun 16, 2004 6:39 am

frisbee wrote:Okay, so now its installed and running. I have a DVD writer that I use as my dvd/cdrom reader. I inserted a dvd with a e2fs file system on it and it did not automount. I could manually mount it but that's not the goal.

No messages in the log file. /dev/cdrom is a link to /dev/ide/host0/bus1/target0/lun0/cd

I uncommented the /dev/hdc line in IvmConfigMappings.xml and tried the debugging mode. No output. I think hald is not reporting correctly.

Here is my fstab entry:

/dev/cdroms/cdrom0 /mnt/cdrom auto noauto,noatime,ro 0 0
If there's no output in debugging mode, I'm afraid soemthings's wrong with hal.
Maybe try to run dbus-monitor --system, and insert a CD then, look if you see any new DBUS messages.
Working day and night to enhance the Linux Desktop Experience :)

Homepage
Top
eikketk
Apprentice
Apprentice
User avatar
Posts: 270
Joined: Tue Jun 03, 2003 1:34 pm
Location: Belgium
Contact:
Contact eikketk
Website

  • Quote

Post by eikketk » Wed Jun 16, 2004 6:41 am

GlooM wrote:I get this on hal compilation:

configure: error: cannot find pci.ids. Use --with-hwdata to specify location

!!! ERROR: sys-apps/hal-cvs-20040522 failed.
!!! Function src_compile, Line 33, Exitcode 1
!!! (no error message)

well, using locate i found where pci.ids was, and edited the ebuild,
so the configuration would contain --with-hwdata=/path/to/file ,it seems
to have compiled. Cheers :D

ahh, bad luck again:

FATAL ERROR: Autoconf version 2.50 or higher is required for this script
Running autoconf...
FATAL ERROR: Autoconf version 2.50 or higher is required for this script

!!! ERROR: sys-apps/ivman-cvs-20040524 failed.
!!! Function econf, Line 367, Exitcode 1
!!! no configure script found

i have autoconf 2.57, what gives ?
remerging autoconf solved this :)
No idea about this, I'm not really a autotools guru. I was happy the scripts actually worked here and on other people's machine(s).
Nice it has been solved. If you know what caused this, please let me know on ivman-devel!
Working day and night to enhance the Linux Desktop Experience :)

Homepage
Top
frisbee
n00b
n00b
Posts: 27
Joined: Fri May 02, 2003 4:31 am
Location: Santa Cruz, California

  • Quote

Post by frisbee » Wed Jun 16, 2004 7:22 am

I figured out the problem compiling dbus. I needed to upgrade pyrex to the masked version. Now it emerges without error.
Restarted everything and still no automount. I tried the suggested

Code: Select all

% dbus-monitor --system
signal interface=org.freedesktop.DBus; member=ServiceAcquired; sender=org.freedesktop.DBus
string::1.12
and nothing happened when I inserted the DVD. Question? Does my 2.6 kernel need any special feature enabled? Modules? Reboot after installing hal, dbus, or ivman?

Thanks,
[/code]
Top
GlooM
Tux's lil' helper
Tux's lil' helper
Posts: 119
Joined: Sun Jul 13, 2003 7:42 pm
Location: $HOME

  • Quote

Post by GlooM » Wed Jun 16, 2004 9:23 am

Frisbee
No, this aint windoze, you only have to reboot to boot a new kernel,
/etc/init.d/someservice start (or restart) is enough.

The problem is, I cant get it working too :evil: .
The debug doesnt show any messages, ill try the
dbus monitor thing.

Same output in dbus-monitor --system as Frisbee's.
:evil:
Top
eikketk
Apprentice
Apprentice
User avatar
Posts: 270
Joined: Tue Jun 03, 2003 1:34 pm
Location: Belgium
Contact:
Contact eikketk
Website

  • Quote

Post by eikketk » Wed Jun 16, 2004 9:55 am

Are you guys using a udev-system?
Working day and night to enhance the Linux Desktop Experience :)

Homepage
Top
GlooM
Tux's lil' helper
Tux's lil' helper
Posts: 119
Joined: Sun Jul 13, 2003 7:42 pm
Location: $HOME

  • Quote

Post by GlooM » Wed Jun 16, 2004 9:59 am

Well there is a udev process in process list.

udevd that is.
Top
eikketk
Apprentice
Apprentice
User avatar
Posts: 270
Joined: Tue Jun 03, 2003 1:34 pm
Location: Belgium
Contact:
Contact eikketk
Website

  • Quote

Post by eikketk » Wed Jun 16, 2004 10:03 am

Then you should get some output in dbus-monitor. Otherwise that's not an ivman problem, but a udev and/or dbus and/or hal problem I'm afraid.
Working day and night to enhance the Linux Desktop Experience :)

Homepage
Top
GlooM
Tux's lil' helper
Tux's lil' helper
Posts: 119
Joined: Sun Jul 13, 2003 7:42 pm
Location: $HOME

  • Quote

Post by GlooM » Wed Jun 16, 2004 10:10 am

Well it aint ivman then, hal depends on dbus, dbus is silent, so hal aint the prob too, udev then ?
Top
eikketk
Apprentice
Apprentice
User avatar
Posts: 270
Joined: Tue Jun 03, 2003 1:34 pm
Location: Belgium
Contact:
Contact eikketk
Website

  • Quote

Post by eikketk » Wed Jun 16, 2004 10:30 am

hal depends on dbus, but also on udev, like this:

device added -> udev creates a /dev entry and /sys is updated -> hal detects this -> hal sends a dbus message to registered applications.

So, if dbus-monitor gives no output, its hal and/or udedv that's broken. Hal normally isnt afaik (works on my pc and on lots of others I heard of :)) so I think (could be wrong of course) there's something wrong with your UDev setup...
Working day and night to enhance the Linux Desktop Experience :)

Homepage
Top
Chaosite
Guru
Guru
User avatar
Posts: 540
Joined: Sat Dec 13, 2003 3:54 pm
Location: Right over here.

  • Quote

Post by Chaosite » Wed Jun 16, 2004 12:25 pm

eikketk wrote:hal depends on dbus, but also on udev, like this:

device added -> udev creates a /dev entry and /sys is updated -> hal detects this -> hal sends a dbus message to registered applications.

So, if dbus-monitor gives no output, its hal and/or udedv that's broken. Hal normally isnt afaik (works on my pc and on lots of others I heard of :)) so I think (could be wrong of course) there's something wrong with your UDev setup...
This is a real long shot, but here goes...

It is a udev problem, or more exactly, a problem with the Gentoo hacks of udev. The problem is, that /dev is populated with all the devices _possible_, instead of all the devices that are actually on the system. So, udev doesn't make a new entry in /dev (Its already there!), and HAL doesn't send any message. And because Gentoo by default puts /dev in a tarball, then untars it on startup... I think you understand the problem.

The solution should be to edit this file:

Code: Select all

/etc/conf.d/rc
I don't recall the exact line the should be changed, but the file is very well commented, so you should find the right line easily.

After that, it should work properly (Unless I'm wrong, which is very probable too...). HAL was meant to work on a pure udev system...
Top
Post Reply

706 posts
  • Page 1 of 29
    • Jump to page:
  • 1
  • 2
  • 3
  • 4
  • 5
  • …
  • 29
  • Next

Return to “Documentation, Tips & Tricks”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic