LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (http://www.linuxquestions.org/questions/linux-general-1/)
-   -   swap question (http://www.linuxquestions.org/questions/linux-general-1/swap-question-4175437321/)

pretruder 11-15-2012 02:59 PM

swap question
 
I don't think I allowed enough swap space for my swap partition when I initially set up my partitions. If I add a swap file, will this interfere with my swap partition? If not, will the system use both? I am trying to increase my swap memory with out having to mess with the disk.

johnsfine 11-15-2012 03:25 PM

Quote:

Originally Posted by pretruder (Post 4830293)
If I add a swap file, will this interfere with my swap partition?

No.

Quote:

If not, will the system use both?
If both are enabled and if the space is necessary, Linux will use both.

What Linux distribution are you using?

The instructions to create a swap file should be easy to find and should be pretty independent of distribution, similarly the instructions to enable the swap file right after you create it.

But I think you need to do a bit more to cause the swap file to be enabled again automatically on each reboot of Linux. I'm not sure of those instructions and I think the best way of doing that may depend on which distribution of Linux you have. In case that is true, identifying your distribution will help someone, who knows more than I about swap files, to give you a better answer.

jefro 11-15-2012 03:28 PM

You could even set a priority for use if you want. Many people use swap files.

Swap file is an easy way to add swap but it does have one limit at least. If you want to suspend/hibernate it may cause an issue.

I think you can create even a sort of swap raid so you could have swap across a number of disks.

pretruder 11-16-2012 06:30 AM

Yes, I have found plenty of information on how to do it, activate it, etc., and it is pretty straight forward and simple. I just couldn't find anything related to my question on the effects it would have to my existing swap. Thank you for clarifying that for me.


All times are GMT -5. The time now is 09:40 AM.