Linux Format forums Forum Index Linux Format forums
Help, discussion, magazine feedback and more
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

HAL/DBUS how it affects you

 
Post new topic   Reply to topic    Linux Format forums Forum Index -> Discussion
View previous topic :: View next topic  
Author Message
davecs
LXF regular


Joined: Sun Apr 10, 2005 12:13 am
Posts: 530
Location: Dagenham, Essex

PostPosted: Mon Apr 25, 2005 7:57 pm    Post subject: HAL/DBUS how it affects you Reply with quote

HAL is a new background program in Linux (or daemon as geeks call them). It depends also on a slightly older but still fairly new one called DBUS. What do they do? This is all to do with mounting your storage devices. And it works with KDE3.4 out of the box.

If you have upgraded to KDE3.4, there is a list of sidebar modules in Konqueror File Manager on the left. The one consisting of three tiny hexagons, orange, blue and green, is called "devices:/". By an oversight, this has been left in but doesn't work anymore. You can delete it, and put a new one in called "media:/". This is done by right-clicking below the last module, and selecting Add New ... > Folder. You should then set the name to Media, the url to media:/ and the icon to "kwikdisk". If you select media:/, you will see a graphical representation of all your hard drives. If HAL/DBUS are running, plug in a CD and it will mount, and it will be added to the icons. Better still, plug in a USB storage device. This will mount and appear also. But you can right-click on it, and select "Remove Safely". This will unmount it properly so that any data you wrote to it is written behind so you can now pull it out.

Once that's all working, you can hop over to KDE Control Centre > Desktop (Look and Feel in some distros) > Behaviour > Device Icons tab. You should enable all the devices you have, EXCEPT hard discs. Both mounted and unmounted. Now when you plug in your USB card, or put a CD in the drive, the icon will appear. The name under the icon defaults to the volume label of the drive, and if there isn't one, its size! Not helpful. By selecting it you can then press F2 to change it. Your change will be saved for next time, but each user (including root) has to do this separately. With this set up, plug in your USB key, after a pause, a mounted icon appears on the desktop. Right click it and select "Remove Safely", the icon changes to the unmounted version. Finally, pull it out, the icon disappears. Perfect!

Anyway, I have upgraded the kernel and KDE/HAL/DBUS via synaptic in PCLinuxOS and this works fine. This will be standard in the next release (0.9) which will be on the mirrors any time soon.

In Gentoo, for some reason, the "Remove Safely" bit did not work. So I added pmount. When you add pmount to hal and dbus, it works differently. When you plug an item in, an unmounted icon pops up. You can then mount it and unmount it to your hearts content before pulling it. The only proviso is that this only works for devices NOT in /etc/fstab.

Basically when you use HAL/DBUS, mount points are created automatically at /media/, and anyone can unmount them. With PMOUNT, mount points are prepared but not mounted. Provided there is no reference in fstab, anyone can mount, and the same person can unmount. If there is a reference in fstab, pmount just runs the normal mount command, so the default properties defined there will prevail.

All in all this is very exciting. It puts supermount, submount and autofs in the shade somewhat. I always had a feeling of disaster waiting to happen with supermount, especially when you could not unmount a writeable device. By the way, for Gnome users, there is a program called Gnome Volume Manager which uses pmount. So gnome users have to use the pmount method. All in all, Linux is moving ahead preparing for the "ordinary guy's" desktop.

To see HAL/DBUS in action, try downloading the PCLinuxOS live CD version 0.9 when it appears in the next week or so, and give it a spin. It may well be in other distros also, but I don't know which they are.
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8364
Location: Warrington, UK

PostPosted: Mon Apr 25, 2005 9:33 pm    Post subject: RE: HAL/DBUS how it affects you Reply with quote

You can avoid the problems with supermount and writeable media by adding the sync option to /etc/fstab. As long as you wait for the LED to go out, it is safe to unplug the device.
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
davecs
LXF regular


Joined: Sun Apr 10, 2005 12:13 am
Posts: 530
Location: Dagenham, Essex

PostPosted: Tue Apr 26, 2005 12:22 am    Post subject: RE: HAL/DBUS how it affects you Reply with quote

I would like to see improvements to the HAL system. My idea is by using UDEV to give every device a unique name, (ie make /dev/usb/cfreader the Name and /dev/sdxn the Symlink,) you could allocate an icon symbol and title according to the device node.

Once that is done, every other auto-mounting system will be dust, I think.
Back to top
View user's profile Send private message
View previous topic :: View next topic  
Display posts from previous:   
Post new topic   Reply to topic    Linux Format forums Forum Index -> Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Linux Format forums topic RSS feed 


Powered by phpBB © 2001, 2005 phpBB Group


Copyright 2011 Future Publishing, all rights reserved.


Web hosting by UKFast