Possible to increase swap size for existing UFS-based drive slice?


 
Thread Tools Search this Thread
Operating Systems Solaris Possible to increase swap size for existing UFS-based drive slice?
# 1  
Old 04-23-2013
Possible to increase swap size for existing UFS-based drive slice?

I like to increase swap size for my current server running solaris 10.
Seems like the system is not using it's full 16G of physical memory.

Code:
#swap -l
swapfile             dev  swaplo blocks   free
/dev/dsk/c0t0d0s1   32,1      16 1058288 1058288

Code:
# swap -s
total: 4125120k bytes allocated + 178808k reserved = 4303928k used, 595088k available

Code:
# format
Searching for disks...done


AVAILABLE DISK SELECTIONS:
       0. c0t0d0 <SUN72G cyl 14087 alt 2 hd 24 sec 424>
          /pci@780/pci@0/pci@9/scsi@0/sd@0,0
       1. c0t1d0 <HITACHI-H101473SCSUN72G-SA23-68.37GB>
          /pci@780/pci@0/pci@9/scsi@0/sd@1,0
       2. c2t0d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@0,0
       3. c2t1d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@1,0
       4. c2t2d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@2,0
       5. c2t3d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@3,0
       6. c2t4d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@4,0
       7. c2t5d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@5,0
       8. c2t6d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@6,0
       9. c2t7d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@7,0
      10. c2t8d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@8,0
      11. c2t9d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@9,0
      12. c2t10d0 <SEAGATE-ST314655SSUN146G-0B92-136.73GB>
          /pci@7c0/pci@0/pci@1/pci@0,2/LSILogic,sas@2/sd@a,0
Specify disk (enter its number): 0
selecting c0t0d0
[disk formatted]
Warning: Current Disk has mounted partitions.
/dev/dsk/c0t0d0s0 is currently mounted on /. Please see umount(1M).
/dev/dsk/c0t0d0s1 is currently used by swap. Please see swap(1M).
/dev/dsk/c0t0d0s7 is currently mounted on /export/home. Please see umount(1M).

partition> print
Current partition table (original):
Total disk cylinders available: 14087 + 2 (reserved cylinders)

Part      Tag    Flag     Cylinders         Size            Blocks
  0       root    wm     104 -  1224        5.44GB    (1121/0/0)   11407296
  1       swap    wu       0 -   103      516.75MB    (104/0/0)     1058304
  2     backup    wm       0 - 14086       68.35GB    (14087/0/0) 143349312
  3 unassigned    wm       0                0         (0/0/0)             0
  4 unassigned    wm       0                0         (0/0/0)             0
  5 unassigned    wm       0                0         (0/0/0)             0
  6 unassigned    wm       0                0         (0/0/0)             0
  7       home    wm    1225 - 14086       62.41GB    (12862/0/0) 130883712

Looks like only 516.75MB allocated for swap?

Code:
# zpool status
  pool: adpool03
 state: ONLINE
 scrub: none requested
config:

        NAME        STATE     READ WRITE CKSUM
        adpool03    ONLINE       0     0     0
          c0t1d0    ONLINE       0     0     0

errors: No known data errors

  pool: rz2pool
 state: ONLINE
 scrub: none requested
config:

        NAME         STATE     READ WRITE CKSUM
        rz2pool      ONLINE       0     0     0
          raidz2     ONLINE       0     0     0
            c2t0d0   ONLINE       0     0     0
            c2t1d0   ONLINE       0     0     0
            c2t2d0   ONLINE       0     0     0
            c2t3d0   ONLINE       0     0     0
            c2t4d0   ONLINE       0     0     0
            c2t5d0   ONLINE       0     0     0
            c2t6d0   ONLINE       0     0     0
            c2t7d0   ONLINE       0     0     0
            c2t8d0   ONLINE       0     0     0
            c2t9d0   ONLINE       0     0     0
            c2t10d0  ONLINE       0     0     0

errors: No known data errors

Strange part is.... c2t0d0 is also part of a ZFS??

Can someone help me decode this? I inherited this system.
Is the only way to increase swap is to create another swap file (say in /home)?

Any help much appreciated!
# 2  
Old 04-24-2013
Quote:
Originally Posted by JT-KGY
I like to increase swap size for my current server running solaris 10.
Seems like the system is not using it's full 16G of physical memory.
Are you running a 32 bit kernel isainfo -kv ?
Can you post echo ::memstat | mdb -k output ?
Quote:
Strange part is.... c2t0d0 is also part of a ZFS??
What do you mean "also" ? c2t0d0 looks like only to be used by the ZFS pool.
Quote:
Is the only way to increase swap is to create another swap file (say in /home)?
With your layout, yes (but not in /home which is designed for a different purpose and is usually managed by the automounter). You also need a 64 bit kernel.

Last edited by jlliagre; 04-24-2013 at 04:37 PM..
# 3  
Old 04-24-2013
The system appears to have only 4 GB RAM, check with
prtconf and
prtdiag
Adding 1 or 2 GB swap makes sense here.
The disk c0t0d0 appears to be fully used, by UFS filesystems. So it's some expert effort to deduct another swap slice from it. Adding a swap file is easier.
# 4  
Old 04-24-2013
Thanks guys for replying!!!! Much appreciated!

Code:
(in both global and zone)
# isainfo -kv
64-bit sparcv9 kernel modules

Code:
# prtconf | grep -i memory
Memory size: 16376 Megabytes


And jlliagre, you're right about c2t0d0 only in ZFS... I read that wrong.
Also... memstat is not installed on the box.....

MadeInGermany, how do you make that it only has 4GB of RAM?


Additional Info: One of the container is running Oracle 8i.... and it always show that it's using about 2200MB of RAM....
I know that system has 16G and I would like oracle to use more of the RAM.
# 5  
Old 04-24-2013
Quote:
Originally Posted by JT-KGY
Also... memstat is not installed on the box.....
Sorry, my mistake. Please post echo ::memstat | mdb -k output (I missed to write the "echo" command).
Quote:
Additional Info: One of the container is running Oracle 8i.... and it always show that it's using about 2200MB of RAM....
How do you measure this usage ?
Are you running the swap command inside a non-global-zone ?
Is there some capping in place ?
# 6  
Old 04-24-2013
Quote:
Originally Posted by jlliagre
Sorry, my mistake. Please post echo ::memstat | mdb -k output (I missed to write the "echo" command).

How do you measure this usage ?
Are you running the swap command inside a non-global-zone ?
Is there some capping in place ?
Nothing happens when I run
Code:
echo ::memstat | mdb -k

Does it take a long time to run?


I ran prstat -Z on the global
Code:
ZONEID    NPROC  SWAP   RSS MEMORY      TIME  CPU ZONE
     2      122 2427M 2432M    15%  20:28:31 9.4% zone3
     4       64  309M  306M   1.9%   6:29:03 0.2% zone3c
     0       48  187M  185M   1.1%   7:01:24 0.1% global
     3       62  406M  409M   2.5%   7:18:24 0.0% zone3b
     1       42 1414M 1417M   8.7%   6:09:35 0.0% zone3a

Looks like it's using 2432M of memory now.....

No capping, I believe
Code:
# zonecfg -z zone3 info
zonename: zone3
zonepath: /zones2/zone3
brand: native
autoboot: true
bootargs:
pool:
limitpriv:
scheduling-class:
ip-type: shared
net:
        address: 192.168.125.24
        physical: e1000g0
dataset:
        name: rz2pool/database

# 7  
Old 04-24-2013
Quote:
Originally Posted by JT-KGY
Nothing happens when I run
Code:
echo ::memstat | mdb -k

Does it take a long time to run?
It should take seconds if you have Solaris 10 update 8 or newer. Might take minutes or even an hour if you have an older Solaris release (see https://blogs.oracle.com/sistare/ent...d_fast_memstat )
Quote:
I ran prstat -Z on the global
Code:
ZONEID    NPROC  SWAP   RSS MEMORY      TIME  CPU ZONE
     2      122 2427M 2432M    15%  20:28:31 9.4% zone3
     4       64  309M  306M   1.9%   6:29:03 0.2% zone3c
     0       48  187M  185M   1.1%   7:01:24 0.1% global
     3       62  406M  409M   2.5%   7:18:24 0.0% zone3b
     1       42 1414M 1417M   8.7%   6:09:35 0.0% zone3a

Looks like it's using 2432M of memory now.....
So according to prstat, you have 16 GB of memory. Do you feel there is still a problem to solve ?
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Solaris

How to increase the /var (UFS) filesystem and root disk under veritas control?

I need to increase the /var (UFS) filesystem and root disk under veritas control or root disk is encapsulated # df -k /var Filesystem kbytes used avail capacity Mounted on /dev/vx/dsk/var 13241195 12475897 674524 96% /var # fstyp /dev/vx/dsk/var ufs # pkginfo... (1 Reply)
Discussion started by: amity
1 Replies

2. Solaris

Need to attach one slice with existing concatenated volume

Hi I need to add new slice to existing concatenated volume. Please let me know the process to do the same I have d0 concatenated volume which consist of c1t0d0s7 & c1t2d0s0 bash-3.00# df -h /export/home Filesystem size used avail capacity Mounted on /dev/md/dsk/d0 ... (3 Replies)
Discussion started by: sb200
3 Replies

3. Solaris

Swap size increase

Dear All, How to increase the swap size when physicall memory reaches 60 %. OR it can be only done after the physicall memory is full. Rgds Rj (8 Replies)
Discussion started by: jegaraman
8 Replies

4. Solaris

clear swap slice

is there a command that would zero swap slice? I found these instructions: but hoping there is some swap-specific command (3 Replies)
Discussion started by: orange47
3 Replies

5. Solaris

Installing ZFS on an existing Solaris 10 install (UFS)

Hello, I am new to Solaris so i apologize upfront if my questions seem trivial. I am trying to install a ZFS file system on a Solaris 10 machine with UFS already installed on it. I want to run: # zpool create pool_zfs c0t0d0 then: # zfs create pool_zfs/fs My question is more to... (3 Replies)
Discussion started by: mcdef
3 Replies

6. Solaris

How to increase or decrease inode number of the particular UFS filesystem

Hi Gurus I want to know the command & tips regarding, how to increase or decrease inode number of the particular ufs filesystem. Is it possible to do it in a live/production environment. Regards (3 Replies)
Discussion started by: girish.batra
3 Replies

7. Solaris

Increase size of /tmp swap File

Hi Guys I need to increase the size of my /tmp swap file. What is the easiest way to do this. Thanks Carson (2 Replies)
Discussion started by: cmackin
2 Replies

8. UNIX for Dummies Questions & Answers

Add SWAP to free slice

I'm interested in adding more swap space to my current workstation (Solaris 10). I currently have 2 hard drives installed, however the system was only created with 512MB for swap that resides on drive 1. This drive is already sliced up and all slices are being used. The second drive has two... (3 Replies)
Discussion started by: here2learn
3 Replies

9. UNIX for Dummies Questions & Answers

run fsck on swap slice?

Hi.. i am using sun solaris...and this is the filesystem information... you can see th slice(swap) c0t0d0s1 is giving some absord information......and during rebooting it is asking to run fsck mnually..when i run fsck manually it is giving error incorrect starting and end header...smthing like... (1 Reply)
Discussion started by: Prafulla
1 Replies
Login or Register to Ask a Question