- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- swap question
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2005 06:16 PM
11-10-2005 06:16 PM
swap question
on my machine swap is not getting used, i have even tried creating a additional swap file and added it still no luck. this is happening on 2.2 kernel.
--chakri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2005 06:37 PM
11-10-2005 06:37 PM
Re: swap question
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2005 07:22 PM
11-10-2005 07:22 PM
Re: swap question
can you post the output of the command "free -m"? Did you get any errors because of insufficient memory? Linux don´t use swap if it not must.
Regards,
Patrick
Patrick
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2005 07:22 PM
11-10-2005 07:22 PM
Re: swap question
After creating the swap partition, you need to format it by using :
mkswap
Then you can mount it with :
swapon
If you want this to be done automagically at boot, add the following line in /etc/fstab :
/dev/vg01/lvswap swap swap defaults 0 0
Good lcuk.
Kodjo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2005 10:33 PM
11-10-2005 10:33 PM
Re: swap question
This should be not a problem, the problem is if the swap is too used.
Why are you worried about the use of the swap.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2005 12:11 AM
11-11-2005 12:11 AM
Re: swap question
No seroiusly, you can check if and what swap device/file is enabled by
$ /sbin/swapon -s
Filename Type Size Used Priority
/dev/sda3 partition 1028152 79976 -1
alternatively look up in /proc
cat /proc/swaps
Filename Type Size Used Priority
/dev/sda3 partition 1028152 79976 -1
Usually, as already said by others creating and activating swap is as easy as using the two commands mkswap and swapon.
However, it could be that (for what ever reason) you have set a swapiness too low (if set at all)
Check by
# sysctl -a | grep swap
if it's set.
Also see
http://kerneltrap.org/node/3000/print
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2005 01:41 AM
11-11-2005 01:41 AM
Re: swap question
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2005 01:41 AM
11-11-2005 01:41 AM
Re: swap question
total used free shared buffers cached
Mem: 895 316 578 0 13 80
-/+ buffers/cache: 223 672
Swap: 2047 0 2047
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2005 02:02 AM
11-11-2005 02:02 AM
Re: swap question
Your machine isn't using swap space because it isn't necessary.
Everything is ok.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2005 02:12 AM
11-11-2005 02:12 AM
Re: swap question
total used free shared buffers cached
Mem: 895 876 18 0 68 48
-/+ buffers/cache: 760 135
Swap: 2047 0 2047
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2005 02:26 AM
11-11-2005 02:26 AM
Re: swap question
The -+buffers line in the free command shows the free memory without buffers.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2005 08:14 AM
11-11-2005 08:14 AM
Re: swap question
short answer: 135MB of 895MB memory are free and your system does not need to swap. :)
Most linux-systems have a memory usage of over >50%, but the memory is used for cache and buffers. This memory will be used if an application needs more memory.
So everything´s right. :)
Regards,
Patrick
Patrick