LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-15-2004, 01:49 PM   #1
Mr_Penguin_02
LQ Newbie
 
Registered: Aug 2004
Location: Spokane WA
Distribution: Fedora Core 1, Red Hat 9, SUSE 9.2 Pro
Posts: 10

Rep: Reputation: 0
SWAP Space



Last edited by Mr_Penguin_02; 07-04-2005 at 06:19 PM.
 
Old 08-15-2004, 02:04 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,698

Rep: Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895
You have a couple of options. You can create a swap file similar to what windows uses or create an additional swap partition.

The swap file will be slower then a new partition but easier to configure.
To create a 20MB swap file:
dd if=/dev/zero of=/usr/local/newswap bs=1000000 count=20
chmod 600 /usr/local/newswap
mkswap /usr/loca/newswap
swapon /usr/local/newswap
Add to your /etc/fstab file
/usr/local/newswap swap swap defaults 0 0

You can change the file name and location as desired.

To create an additional swap partition you will need to resize an existing partition to create some free space and then create the swap partition. linux as a couple of apps to resize, parted or the GUI qtparted. Once the swap partition is created you can use the previous steps starting with the mkswap command but instead of the file name use the swap partition ID i.e.
mkswap /dev/hdax. (Where x is the partition ID number)

Last edited by michaelk; 08-15-2004 at 02:06 PM.
 
Old 08-15-2004, 02:39 PM   #3
Mr_Penguin_02
LQ Newbie
 
Registered: Aug 2004
Location: Spokane WA
Distribution: Fedora Core 1, Red Hat 9, SUSE 9.2 Pro
Posts: 10

Original Poster
Rep: Reputation: 0
Okay,

You've given me re-assurance that I don't need to format! So, since I'm a newbie, is the second option how I would resize my SWAP partition? Also, on the first option do I just type in what you typed? THANKS ALOT!

James
 
Old 08-15-2004, 02:59 PM   #4
Mr_Penguin_02
LQ Newbie
 
Registered: Aug 2004
Location: Spokane WA
Distribution: Fedora Core 1, Red Hat 9, SUSE 9.2 Pro
Posts: 10

Original Poster
Rep: Reputation: 0
Also, will QTParted work on Red Hat 8.0?
 
Old 08-15-2004, 04:39 PM   #5
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,698

Rep: Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895
QTparted should work with RH but you can not modify partitions that are mounted. You can use the RH 1st install CD and boot to rescue mode but you will only be able to run the command line parted. I think that QTparted is included on knoppix which is a liveCD linux version.

You can resize swap but I my suggestion was to create a 2nd swap partition just to make things easier.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to reduce swap space and reclaim the space grantm Linux - Newbie 7 08-16-2012 07:05 AM
swap space alphisb0t Linux - Software 1 07-05-2004 03:16 PM
How to unmount actual swap and mount a new(bigger) swap space? isaac Linux - Newbie 1 06-06-2004 01:23 AM
swap space not being used bishal Linux - Software 16 05-07-2004 12:28 AM
Swap Space bawbag Slackware 6 07-16-2003 10:59 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration