Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Need to resize SWAP partition on a NetraX1
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc
View previous topic :: View next topic  
Author Message
stty0
n00b
n00b


Joined: 26 Feb 2004
Posts: 15

PostPosted: Thu Jan 13, 2005 12:01 am    Post subject: Need to resize SWAP partition on a NetraX1 Reply with quote

What is the best way to change the size of the swap partition on a Netra X1 (no video/KB/Mouse?)

I need to change swap from 512MB to 1GB prior to an Oracle install.
The first thing that comes to mind is: boot from the LiveCD and run fdisk to remove the swap partition, and then re-create it with a bigger size(?) What would that do to my existing partitions?

I have:

/dev/hda1 as boot 512MB <-- yes, I know that is large.
/dev/hda2 as swap 512MB
/dev/hda4 as / 18GB

Any advice for a linux neophyte like myself?
Back to top
View user's profile Send private message
syg00
l33t
l33t


Joined: 23 Aug 2004
Posts: 907
Location: Brisbane, AUS

PostPosted: Thu Jan 13, 2005 12:12 am    Post subject: Reply with quote

I like the "keep it simple" philosophy.
Surely Linux can handle multiple swap's ???.
Just define another, add it with "swapon", then update fstab to match.
If you want "neat", afterwards "swapoff" the (current) small one, and just run with the larger one.
Back to top
View user's profile Send private message
stty0
n00b
n00b


Joined: 26 Feb 2004
Posts: 15

PostPosted: Thu Jan 13, 2005 8:12 pm    Post subject: solved Reply with quote

Well, after looking at some alternatives, like qparted and such (which seem a bit unreliable), It came down to 2 alternatives:

1) add a 2nd HD and use a partition on it for swap. not practical since I dont have a spare lying around.

2) create a swapfile. This is what I did:

Code:

dd if=/dev/zero of=/swpfile bs=1024k count=512


That creates a 512MB swapfile located at /swpfile

Then, to activate it:

Code:

mkswap /swpfile
swapon /swpfile


Note that swap is additive, so the original 512MB swap partition + 512MB swapfile = 1GB of total swap. You can use top to see the total swap space u have.

Cheers.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum