# Hal, dbus, udev, gamin, ivman, /mnt Vs /media - I'm confused

## Joffer

So I followed the install guide, and other guides on gentoo.org and have installed and started at boot programs/daemons like hal, dbus, udev, gamin, ivman, portmap and probably others I just don't exactly know what do or provide my system... and then there is /mnt Vs /media too. I'm very confused.

Does anyone care to try to explain how it all fits together? I'm using Gnome-2.14 btw.

----------

## at240

What are you actually trying to do? Mount removable devices automatically? Or something else?

----------

## Joffer

Apart from trying to understand what depends on what and connects with what (and being confused).. well.. a few things first at least:

1) Why is there a /mnt and a /media? Isn't /mnt enough?

2a) If I insert a CD/DVD into my DVD-ROM or CD-ROM (I got one of each) I get 4 new "drives" in "Computer", namely "CD-RW Drive"; "CD-RW/DVD+-R Drive", "CD-ROM", "DVD-ROM".

2b) Some times only "CD-RW Drive"; "CD-RW/DVD+-R Drive". But I can't open the drives. I have 'noauto,user' as an option in fstab for both drives, and I've added my user to disk,floppy,cdrom,plugdev,cdrw,usb groups. The "CD-RW/DVD+-R Drive" even thinks there is a blank DVD+R disc in the drive even though it's been taken out of the drive.

3) I do also have a memcardreader in my computer. It is a 8-in-1 thingy. The only think that displays in "Computer" is "Generic              CF", and inserting a memorycard in one of the slots does nothing.

4) Do I need to configure custom udev rules?

5) What controls /media? Does mounts coexist in /mnt and /media?

6) Where does ivman fit into this? It depends on hal I understand from the description in emerge. Do udev rules figure into this at all?

7) Where do I confugre the system to allow my user to mount/access drives located in "Computer"? I tried what's said in 2b)...

As you can see.. it's a bit of a mess in my head at the moment. I inserted a data-CD into the CD-ROM drive, and it just keeps spinning at full speed, without ever spinning down.. hmm..

I have managed to install and use captive-ntfs on my ADM64 system for my external usb drive though  :Very Happy:  But thats about all there is to it. But I'm not able to mount the disk as a user, I need to be root  :Sad: 

----------

## at240

1. According to FHS, /media is the mount point for removable media; /mnt is the mount point for temporarily mounted file systems. http://www.pathname.com/fhs/pub/fhs-2.3.html#MEDIAMOUNTPOINT  I guess that raises the question, well, what about temporarily mounted file systems ON removable media...? Now MY head's spinning...

2-3 & 7. Don't know, but the thing in GNOME that deals with all this is gnome-volume-manager, so you might want to investigate that.

6. My understanding, very roughly, is that hal gathers data about hardware, using DBUS for some communication. ivman is the automounter, which gets its information from hal.  

Not sure about udev either, really.

Yeah, the more I think about it, the more I realise I don't really understand it all either. Let's hope someone who does will explain all.   :Smile: 

----------

## Joffer

 :Confused: 

Will look into gnome-volume-manager at least.. 

Are mountpoints ("folders") in /media automade when needed then, or do I have to prepare those myself?

----------

## superczar

1) Why is there a /mnt and a /media? Isn't /mnt enough?

Like it was said above, convention would have you place mount points in the different areas depending on if it was a temporary mount or removable media.

2a) If I insert a CD/DVD into my DVD-ROM or CD-ROM (I got one of each) I get 4 new "drives" in "Computer", namely "CD-RW Drive"; "CD-RW/DVD+-R Drive", "CD-ROM", "DVD-ROM".

This happened to me to when I was running all those services, I think it is just to accomodate programs that are expecting things to be in different places.

2b) Some times only "CD-RW Drive"; "CD-RW/DVD+-R Drive". But I can't open the drives. I have 'noauto,user' as an option in fstab for both drives, and I've added my user to disk,floppy,cdrom,plugdev,cdrw,usb groups. The "CD-RW/DVD+-R Drive" even thinks there is a blank DVD+R disc in the drive even though it's been taken out of the drive.

I'm not sure on this one, is it throwing an error when youre trying to open it?  There could be a variety of reasons that it would be doing this, although all I had to do was the same things you already did.

3) I do also have a memcardreader in my computer. It is a 8-in-1 thingy. The only think that displays in "Computer" is "Generic              CF", and inserting a memorycard in one of the slots does nothing.

Gonna have to ask someone else on this one

4) Do I need to configure custom udev rules?

With automounters it's not entirely necessary, not many people do.  But, i did so that i knew the automounters would put my ipod and usbstick in the same place every time.

5) What controls /media? Does mounts coexist in /mnt and /media?

hal, dbus, udev, ivman, and gnome-volume-manager handle it just like /mnt.

6) Where does ivman fit into this? It depends on hal I understand from the description in emerge. Do udev rules figure into this at all?

basically, when a device is inserted, the kernel tells udev, and udev sets up /dev/* files referencing it.

hal then does something (i'm unclear on hal's purpose) with dbus to tell ivman that the device has been plugged in and ivman sets up the mounts for it and mounts the drive.

7) Where do I confugre the system to allow my user to mount/access drives located in "Computer"? I tried what's said in 2b)...

like i said earlier thats all i had to do.  If you post the errors, maybe we can help more.

----------

## Joffer

Thanks.. it's a bit more clearer.. I think I will look more into hal/iwman and udev rules, and gnome-volume-manager...

----------

## mdeininger

3) just wanted to throw some light into the memcard reader thing:

usually, these 8-in-1 multislot things will be emulated as a #-of-slots-multiLUN scsi device. there's a kernel option to make linux check for all luns on scsi drives, this would hopefully allow gnome to recognise all of the slots. not sure about automounting them though, *shrugs*

I'm too lazy to setup automounting =)

----------

## Joffer

 *mdeininger wrote:*   

> 3) just wanted to throw some light into the memcard reader thing:
> 
> usually, these 8-in-1 multislot things will be emulated as a #-of-slots-multiLUN scsi device. there's a kernel option to make linux check for all luns on scsi drives, this would hopefully allow gnome to recognise all of the slots. not sure about automounting them though, *shrugs*
> 
> I'm too lazy to setup automounting =)

 

Thats true.. I forgot about that... recompiling now.. and I just did also.. arg.. hehe

----------

