Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
02-02-2009, 09:04 AM
|
#1
|
Member
Registered: May 2008
Location: France
Distribution: Debian / Fedora / Gentoo
Posts: 178
Rep:
|
Consequences of no swap
Hi all,
I am running a small embedded system with a small HDD capacity.
However, RAM is 512 MB, which seems a lot compared to the applications running on it.
I am wondering of removing swap parition or file, to have more free space on the tiny HDD.
Did somebody try running without swap already ?
What happens if there is not enough physical RAM space ?
Thanks
|
|
|
02-02-2009, 09:19 AM
|
#2
|
Senior Member
Registered: Mar 2004
Location: UK
Distribution: CentOS 6/7
Posts: 1,375
|
Generally the results of not having enough memory are things gridding to a near halt or even crashing. But it takes alot to really cause that effect. I believe if their is no swap, some distributions may use a section of / as swap (similarily to windows and virtual memory out of C:) but not certain of that. Generally it'd be wise to have 1GB of dedicated swap on that system. When you are talking a small capacity HDD, how small and what's it running?
|
|
|
02-02-2009, 09:27 AM
|
#3
|
Member
Registered: Jan 2009
Location: Palermo, Italy
Distribution: Slackware
Posts: 236
Rep:
|
Quote:
Did somebody try running without swap already ?
|
I tried once and nothing happened, but my RAM is 1 Gb.
Quote:
What happens if there is not enough physical RAM space ?
|
Your PC will crash or will get slow.
In the end...How large is your swap? 1 Gb, 512 Mb? What do you recover with one 1 gb. or 512 Mb...You may have complications...
Last edited by metrofox; 02-02-2009 at 12:02 PM.
|
|
|
02-02-2009, 09:32 AM
|
#4
|
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809
|
I assume that the behavior when running out of memory will be very different depending on what SW you are running. There are typically a number of calls to allocate memory, and then a decision as to what to do if the request is not successful.
I can't think of any way to definitively answer your question except by running tests.
I've never heard of a distro "using /" for swap space but, regardless, this would still use disk space.
|
|
|
02-02-2009, 09:34 AM
|
#5
|
Senior Member
Registered: Mar 2004
Location: UK
Distribution: CentOS 6/7
Posts: 1,375
|
I could have been wrong about / . I dunno that much about the indepths of linux, however on such a low speced system, if it's important I wouldn't be able to sleep at night if it didn't have a proper defined swap.
|
|
|
02-02-2009, 09:37 AM
|
#6
|
Member
Registered: Jan 2009
Location: Palermo, Italy
Distribution: Slackware
Posts: 236
Rep:
|
Any way...I do not need of a swap...My swap uses the 1% of its resources...
To PlatinumX: How many resources your swap uses?(I think higher than mine)...
|
|
|
02-02-2009, 09:49 AM
|
#7
|
Member
Registered: May 2008
Location: France
Distribution: Debian / Fedora / Gentoo
Posts: 178
Original Poster
Rep:
|
Quote:
To PlatinumX: How many resources your swap uses?(I think higher than mine)...
|
I don't have a the precise answer here.
I will check this.
Thanks for info guys
|
|
|
02-02-2009, 11:37 AM
|
#8
|
Senior Member
Registered: Mar 2004
Location: UK
Distribution: CentOS 6/7
Posts: 1,375
|
Just use the top command in bash or a ssh shell and it will tell you. It's q to quit for top.
|
|
|
02-02-2009, 12:02 PM
|
#9
|
Member
Registered: Jan 2009
Location: Palermo, Italy
Distribution: Slackware
Posts: 236
Rep:
|
Code:
Swap: 2096440k total, 0k used, 2096440k free, 420832k cached
That's what my swap says...As you can see my swap doesn't consume resources, 0k used...I don't know why I gave 2 Gb to swap when it needs 1Gb at max.(next installation I'll remove it )...Maybe I had in my head that swap had to be double than RAM, but that technical worked for 2.4.x kernels...
|
|
|
All times are GMT -5. The time now is 10:22 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|