Quoting Vincent Cunniffe <vcunniff at dogma.slashnull.org>:
> Tony Bolger wrote:
> >
> > One of my rather overspeced linux servers had an attack of the old
> > 'Unable to fork' problem on Sunday. Normally, this would be annoying
> > enough, but on a server with 400MB of free RAM, its just not on. This
> > machine is a 2.2.12 box, and needed a reboot to fix. Free command
> gives:
> >
> > total used free shared buffers cached
> > Mem: 517088 485400 31688 54996 339928 82776
> > -/+ buffers/cache: 62696 454392
> > Swap: 130748 1884 128864
> >
> > I know swap is supposed to be > RAM, but turbolinux's mkswap only
> > supported 128MB swap partitions, even though a gig has been allocated.
> > Need to fix that i suppose.
> >
> > Any ideas? Will a newer kernel or the 1GB swap fix it?
>> Well, you can delete the existing 1GB swap partition, create an extended
> partition with 8 x 128MB ones, and put them all into /etc/fstab as swap
> spaces.
>Apart from the fact that this is pointless, there is no major need.
(Putting 8 swap partitions on the same drive is pointless, as there
is no useful limit on the size of swap partitions in 2.2 (I think
it's up near 2GB or so), and it won't improve performance (it might
even lower performance, as it will jump between swap partitions the whole
time).
Assuming you have something like:
hda1 /
hda2 swap
hda3 /whatever
and you have free space between hda2 and hda3, then drop to single user
mode, swapoff -a, fdisk hda, delete hda2, and recreate it as whatever size
you require. Then save settings, reboot, and login. mkswap <-c> /dev/hda2
and swapon -a will give you what you need. (-c for checking block integrity).
Then again, Linux isn't like Solaris/DU/Irix, and it doesn't dump memory
to swap when it oops, so there's no use IMHO in having a huge swap partition.
Most of my machine have 128/200, enough to have it there if something wants
it, but it's virtually never used (advantage of having machines with 256MB+
ram).
Regards
L.
---
Liam Bedford | It's
WBT | the
01-4170153 | G-A-D to the G-E-T
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!