Link to home
Start Free TrialLog in
Avatar of sganta
sganta

asked on

How to distribute the swap memory across the disks ?

Could you please tell me how to distribute the swap area
across the disks ?

Thanks in Advance
Avatar of ahoffmann
ahoffmann
Flag of Germany image

depends on your OS.
Either you need to make special swap partitions, and/or use the swap command to add prepared files to the swap area (man swap)
Avatar of sganta
sganta

ASKER

Hi,

I am working on Solaris OS 2.x (UNIX)
I would like to make parititions across the different disks.

I have Swap memory about 500MB in one disk.
I would like to distribute this swap across 5 disks.

Could you please tell me which is the best way ?

Thanks & Regards
sganta
ASKER CERTIFIED SOLUTION
Avatar of ahoffmann
ahoffmann
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of sganta

ASKER

Hi,

Thanks for your prompt answer.

I am new to the Sysadmin tools. Could you please
give me the syntax  to do the partition.
Avatar of sganta

ASKER

Hi,

Thanks for your prompt answer.

I am new to the Sysadmin tools. Could you please
give me the syntax  to do the partition.
man format
man swap      # or see my comment
What ahoffmann told is correct.
Pls look into this.

1. Create a file in each disk using mkfile command
eg:  # mkfile 100 m  /opt/addlswap
 Where  100 m is the file size ie. 100 MB
2.  Add this file to swap
eg:  #/usr/sbin/swap -a   /opt/addlswap
 3. Now this is added to swap space. But this is only temporary.
 After rebooting this will not be available. So make an entry in
/etc/vfstab
 eg:   add the following entry in /etc/vfstab
  /opt/addlswap  -   -   swap  -  no  -
4. The modified swap size can be viewed by  swap -l command
     This will be in 512 K block size
    Use swap -s to view in 1024 k block size


JP
Avatar of sganta

ASKER

Thanks to all of you for your favours towards me !

Best Regards
sganta