[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Dynamically sizing swap by memory size?



On Wed, 8 May 2002, John Stoffel wrote:

>Is there any way to dynamically resize swap space according to how much
>memory is installed on a system?
>
>I figure I could just do 'parted' after the system is up, but this seems
>pretty hacky, and a pain since it would have to run during the %post
>phase, which would require me to unmount the /mnt/sysimage to do the
>work.
>
>Basically, we would love to setup swap partitions according to some
>simple rules, such as:
>
>    2 x system RAM, minum of 256mb, max of 2gb.
>
>Any clue would be great.

You could try and partition things in %pre with a redirect in to
fdisk, and give --onpart arguments in the first section when setting
it up.  The trouble then becomes determining the size of memory inside
of %pre, since you don't get access to all utilities there.

-- 
					Gary Jackson
					bargle umiacs umd edu





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]