You are not logged in.

#1 2008-03-23 00:41:57

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Hide a partition from GNOME (not show up on desktop)

Hi, I just want to hide my /data partition from the GNOME desktop. It's showing up as a volume, the same as removable devices. So if I disable show_volumes in Gconf-editor it would also hide those, which is something I don't want. Here is my fstab:

# /etc/fstab: static file system information
#
# <file system>        <dir>         <type>    <options>          <dump> <pass>
none                   /dev/pts      devpts    defaults             0      0
none                   /dev/shm      tmpfs     defaults             0      0

#/dev/cdrom             /media/cd   auto    ro,user,noauto,unhide   0      0
#/dev/dvd               /media/dvd  auto    ro,user,noauto,unhide   0      0
#/dev/fd0               /media/fl   auto    user,noauto             0      0

/dev/sda1                 swap         swap     defaults                 0      0
/dev/sda3                 /data         ext3     defaults                 0      1
/dev/sda5                 /boot         ext3     defaults                 0      1
/dev/sda6                 /             ext3     defaults                 0      1
/dev/sda7                 /var         ext3     defaults                 0      1
/dev/sda8                 /tmp         ext3     defaults                 0      1
/dev/sda9                 /home         ext3     defaults                 0      1

Should I just add the noauto option to the /data entry?

Thanks!


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#2 2008-03-23 00:46:03

dyscoria
Member
Registered: 2008-01-10
Posts: 1,007

Re: Hide a partition from GNOME (not show up on desktop)

noauto will mean that it won't auto mount at boot, and when you do mount it there will be an icon on your desktop.

It's a wild stab, but I think if you create a folder in /mnt and remount it there, that might solve it (so that it's more of a part of your root directory):

mkdir -p /mnt/recent
/dev/sda3   /mnt/data   ext3    default   0   1

flack 2.0.6: menu-driven BASH script to easily tag FLAC files (AUR)
knock-once 1.2: BASH script to easily create/send one-time sequences for knockd (forum/AUR)

Offline

#3 2008-03-23 04:31:02

praka123
Member
From: Kerala,India
Registered: 2008-03-04
Posts: 188
Website

Re: Hide a partition from GNOME (not show up on desktop)

I think if u mount inside  /media/anydir only Gnome shows the mounted icon in Desktop.so,why dont make a /disks directory with sub-dir for each partitions u mount. smile

Offline

#4 2008-03-23 10:47:04

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Hide a partition from GNOME (not show up on desktop)

Mounting in in /mnt/data seems like a good idea, however, I've always mounted a partition in /data while using other distros and GNOME didn't act this way. So there has to be something else.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#5 2008-03-23 14:02:27

Phrodo_00
Member
From: Seattle, WA
Registered: 2006-04-09
Posts: 342
Website

Re: Hide a partition from GNOME (not show up on desktop)

You have to hide it from hal, by puting a file in /etc/hal.d/polices or something like that... I posted the file that did it sometime before, I don't have it anymore though so you'd have to look for it in the forum.

Offline

#6 2008-03-23 17:52:05

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Hide a partition from GNOME (not show up on desktop)

I'm not at home right now, but I think the cleanest solution would be to mount my partition under /mnt/data and make a soft link to /data....

Thanks!


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#7 2008-03-23 22:15:59

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Hide a partition from GNOME (not show up on desktop)

Mounting under  /mnt makes no difference, partitions are still displayed. OMG it's so annoying.....


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#8 2008-03-23 22:30:56

tehanomaly
Member
From: UK
Registered: 2007-11-28
Posts: 12

Re: Hide a partition from GNOME (not show up on desktop)

Try giving the partition a unique label:

sudo tune2fs -L MYDISKSLABEL /dev/sda3

then create a '/etc/hal/fdi/policy/preferences.fdi' file and adding the following to it (changing the label as appropriate wink )

<?xml version="1.0" ?>
<deviceinfo version="0.2">
    <device>
        <match key="volume.label" string="MYDISKSLABEL">
            <merge key="volume.ignore" type="bool">true</merge>
        </match>
    </device>
</deviceinfo>

This method is depreciated (I believe) but it may work...

EDIT: oh, and don't forget to restart HAL (/etc/rc.d/hal restart) after creating the file

Last edited by tehanomaly (2008-03-23 22:33:12)


'I cannot teach anybody anything, I can only make them think...'

Offline

#9 2008-03-24 00:09:37

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Hide a partition from GNOME (not show up on desktop)

Thanks, that works! So is that the only solution right now ? Maybe GNOME should add an option like this.....


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#10 2008-03-24 00:18:35

praka123
Member
From: Kerala,India
Registered: 2008-03-04
Posts: 188
Website

Re: Hide a partition from GNOME (not show up on desktop)

thanks @tehanomaly smile
this hal thing is pretty much tough to figure out(pattern!)

Offline

Board footer

Powered by FluxBB