Hide your swap Partition .... it's easy!!

Zeus

Registered
Hi all,
if you want to hide yous swap partition you just have to:
1) for MAC OS X
reneame it from swap (for ex.) in .swap ...
(be sure to have the show all files function disabled)
Then update the /etc/rc and, if present, the /etc/fstab
reboot and .... enjoy

2) for Mac OS 9
just restart from your restore cd open your Drive setup an select the Volume settings command in the option menù.
Disable the automount function, quit and reboot!!!
 

ksuther

Registered
How do you rename the disk? It would definitely be nice to make in invisible.

Thanks. :)
 

GraphiteMacG4

Registered
I tried the above suggestions but nothing, what could I have done wrong. I have the Dev tools installed and typed in exactly what you have. I get an error about "cannot find / or does not exist something like this"
 

lavitus

Registered
You may have to have root access to run the command from the terminal.

Make sure you specify the name of your swap volume in the command line.
 

andymoraitis

Registered
Ummm, Excuse me but I wrote a guide on this which can be found on http://homepage.mac.com/andymoraitis.

If want a simple way of doing this, make sure you have DevTools installed. Switch to root or use sudo in front of the following command:

/Developer/Tools/SetFile - a V /Volumes/yourdrivename

Log out and back in and the changes will take. Since the "V" flag controls invisibility, to make your partition visible again, run the same command with a small "v", logout and your partition will once again be visible.

Have fun!
 

GraphiteMacG4

Registered
Ok I did Try it as Root and still did not work, Also I have the Dev tools installed, the error I get is Command not found.

I just Noticed you have it originally like this:

sudo ./Developer/Tools/SetFile -a V /Volumes/swap_name


and Now I see it it like this:


/Developer/Tools/SetFile - a V /Volumes/yourdrivename

Notice The Dot in the first one... Could that be it. Dont know But I will Try Again This evening. Thanks. Oh I tried to get to your page and no dice. Thanks
 

beef

Dinner
Originally posted by GraphiteMacG4
Ok I did Try it as Root and still did not work, Also I have the Dev tools installed, the error I get is Command not found.

I just Noticed you have it originally like this:

sudo ./Developer/Tools/SetFile -a V /Volumes/swap_name


and Now I see it it like this:


/Developer/Tools/SetFile - a V /Volumes/yourdrivename

Notice The Dot in the first one... Could that be it. Dont know But I will Try Again This evening. Thanks. Oh I tried to get to your page and no dice. Thanks
/ -> root

./ -> current directory where-ever you are
or you can use
./whatevercommand to run the command... (to run stuffs that's not in the path, usually, I think)

if you want to do ./Developer/Tools/SetFile -a blah blah blah, I think you need to be at the root. I think it'll only look up from where you are.

/Developer/Tools/SetFile -a V blah blah blah should work from anywhere. AFAIK, sudo isn't necessary... I think you own the swap volume

and...you need to make sure that you type "SetFile" not "setfile"... if you use this often, you might want to set an alias for it...
 

ksuther

Registered
Hmmm, my swapdisk has the V flag set on it when I run GetInfo, but it still is sitting there...

Any ideas?
:(
 

ksuther

Registered
Yup, I use SetFileInfo, and GetFileInfo gets the attributes, it has the V flag in it, but the disk is still sitting there. Weird :( I want it to go away!
 

ksuther

Registered
YAY! It's gone! All that was wrong was that the drive was called Swapdisk, and under my volumes dir there were two drives, one called swapdisk and one called Swapdisk 1, and I kept making swapdisk invisible, instead of Swapdisk 1. When i changed it's name to just swap, it's good.

Thanks!
 
Top