LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   swap not mounted? (https://www.linuxquestions.org/questions/linux-newbie-8/swap-not-mounted-462644/)

blackzone 07-10-2006 10:45 AM

swap not mounted?
 
Actually it is mounted, since I can see it when using "free" command.

Quote:

total used free shared buffers cached
Mem: 256152 197144 59008 0 10404 103768
-/+ buffers/cache: 82972 173180
Swap: 538168 0 538168
But I can't see it when typing "mount"
Quote:

/dev/hda3 on / type ext3 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
/dev/hda1 on /boot type ext3 (rw)
tmpfs on /dev/shm type tmpfs (rw)
/dev/fd0 on /mnt/fd0 type vfat (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
automount(pid1424) on /net type autofs (rw,fd=4,pgrp=1424,minproto=2,maxproto=4)
Below is my /etc/fstab. Notice there isn't a "/" before swap. Swap don't need
to be a physical directory?

Quote:

/dev/hda2 swap swap defaults 0 0

AzrielMacKay 07-10-2006 10:57 AM

No it doesnt. If you see it when you do free it should be good. You can also check with "top".

antidrugue 07-10-2006 11:01 AM

Quote:

Originally Posted by blackzone
Swap don't need
to be a physical directory?

Nope it doesn't. A typical swap entry in /etc/fstab would look like that :
Quote:

Originally Posted by /etc/fstab
/dev/hda2 none swap sw 0 0

Issuing
Code:

cat /proc/swaps
informs you about your swap file physical location and its priority.

AzrielMacKay 07-10-2006 12:41 PM

Yea having swap mounted would be very bad. Think of swap as just a stick of memory. If you were to be able to go into a stick of memory your kernel is using and just start sticking crap in there or removing stuff your kernel would not be too happy ;).


All times are GMT -5. The time now is 10:51 AM.