swap高手请进:为什么操作系统一直没有使用交换分区!!!
pengd 2003-10-07 08:12:27 我的操作系统是Redhat7.2,物理内存是2011M,SWAP交换分区的内存是2008M,系统运行许多服务,有apache,mysql,resin,postfix,imap等,系统运行了一整天,物理内存差不多用完了,而交换分区的内存仍然没有使用used=0,导致apache,mysql,resin,postfix,imap服务都死了,无法使用的,
我用free命令查看的结果是:
free -m
total used free shared buffers cached
Mem: 2011 2007 4 0 48 1719
-/+ buffers/cache: 238 1772
Swap: 2008 0 2008
我用top命令查看的结果是:
top
9:50pm up 1 day, 4:53, 3 users, load average: 1.20, 1.25, 1.26
536 processes: 533 sleeping, 2 running, 0 zombie, 1 stopped
CPU0 states: 0.1% user, 54.3% system, 0.0% nice, 45.1% idle
CPU1 states: 0.4% user, 60.0% system, 0.0% nice, 39.1% idle
Mem: 2059588K av, 2055364K used, 4224K free, 48K shrd, 49792K buff
Swap: 2056280K av, 0K used, 2056280K free 1761268K cached
PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND
644 mysql 16 0 1884 1884 1476 R 99.9 0.0 1622m mysqld
28926 root 17 0 1384 1384 836 R 13.9 0.0 2:24 top
8 root 9 0 0 0 0 SW 0.3 0.0 1:48 kupdated
5 root 9 0 0 0 0 SW 0.1 0.0 147:17 kswapd
501 root 9 0 620 620 524 S 0.1 0.0 0:28 syslogd
8772 postfix 9 0 1240 1240 896 S 0.1 0.0 0:18 trivial-rewrite
29003 postfix 9 0 1492 1492 1100 S 0.1 0.0 0:00 smtpd
29028 mysql 9 0 17160 16M 1888 S 0.1 0.8 0:00 mysqld
1 root 8 0 520 520 452 S 0.0 0.0 0:03 init
2 root 9 0 0 0 0 SW 0.0 0.0 0:00 keventd
3 root 19 19 0 0 0 SWN 0.0 0.0 0:00 ksoftirqd_CPU0
4 root 19 19 0 0 0 SWN 0.0 0.0 0:00 ksoftirqd_CPU1
6 root 9 0 0 0 0 SW 0.0 0.0 3:47 kreclaimd
7 root 9 0 0 0 0 SW 0.0 0.0 0:21 bdflush
9 root -1 -20 0 0 0 SW< 0.0 0.0 0:00 mdrecoveryd
15 root 9 0 0 0 0 SW 0.0 0.0 0:00 AIFd
19 root 9 0 0 0 0 SW 0.0 0.0 0:27 kjournald
94 root 9 0 0 0 0 SW 0.0 0.0 0:00 khubd
506 root 9 0 1116 1116 448 S 0.0 0.0 0:00 klogd
请问高手是什么原因导致swap一直没有被使用的,谢谢!!!