media:/ shows unnecessary media

Rajeev J Sebastian rajeev_jsv at dinamis.com
Sat May 28 00:13:54 CDT 2005


I have a question:

Is it only me ? or is anyone else having to mount via console ?

pmount just isn't working. And there is no bug filed in bugzilla either. This 
is wierd, no one is reporting the inability to mount hard disks wuthin 
media:/.

Anyway, after waiting for Kari to respond for 2 days, I have made a simple 
script to do the renaming of media nodes with the following features:

1) If the partition has a volume label, it sets that as the label in media:/
2) else if the user has already changed the name to something more appropriate 
in media:/, it sets that as the label in media :/
3) else, it constructs a string "<OS> <device><partitionNumber>" where <OS> is 
currently, "Linux", "Windows" and ".Linux Swap", the <device> is A,B,C,D, 
etc. Volker's suggestion of using "." paid off and swap partitions are 
hidden.

It works on my machine, only if /etc/defaults/hal is edited and the last line 
commented (the one with --drop-privileges). (This is also necessary if 
fstab-sync/pmount is to be used for mounting, and so now, I am totally 
confused: does kubuntu actually use fstab-sync/pmount ?)

to actually run this, you need to install python2.4, python2.4-dcop and 
python2.4-dbus (those are what I have).


Since I do not have any windows partitions, I cannot verify this works for 
windows (including the volume labels part). So, could someone please check it 
for that ? 

Sometimes, media:/ shows strange behavior: such as right as, now as I type 
this, my media:/ does not show any swap partitions (even if show hidden files 
is enabled and the view refreshed several times).


Rajeev J Sebastian

Rajeev J Sebastian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rename_hdd.py
Type: application/x-python
Size: 1908 bytes
Desc: not available
Url : http://lists.ubuntu.com/archives/kubuntu-devel/attachments/20050528/953382f6/rename_hdd.bin


More information about the kubuntu-devel mailing list