Removing swap and other filesystems


 
Thread Tools Search this Thread
Operating Systems Solaris Removing swap and other filesystems
# 1  
Old 06-02-2017
Removing swap and other filesystems

These are the filesystems listed using df :

Code:
# df -k
Filesystem            kbytes    used   avail capacity  Mounted on
/dev/dsk/c0t0d0s0    237770199 138839515 96552983    59%    /
/devices                   0       0       0     0%    /devices
ctfs                       0       0       0     0%    /system/contract
proc                       0       0       0     0%    /proc
mnttab                     0       0       0     0%    /etc/mnttab
swap                 28019728    1208 28018520     1%    /etc/svc/volatile
objfs                      0       0       0     0%    /system/object
sharefs                    0       0       0     0%    /etc/dfs/sharetab
/usr/lib/libc/libc_hwcap1.so.1
                     237770199 138839515 96552983    59%    /lib/libc.so.1
fd                         0       0       0     0%    /dev/fd
swap                 30710920 2692400 28018520     9%    /tmp
swap                 28018552      32 28018520     1%    /var/run
swap                 28018520       0 28018520     0%    /dev/vx/dmp
swap                 28018520       0 28018520     0%    /dev/vx/rdmp
/dev/odm                   0       0       0     0%    /dev/odm
/dev/vx/dsk/bgw1dg/vol01
                     1394485248 1238489538 146614026    90%    /var/opt/BGw/Serv                                                                                        erGroup1
/dev/vx/dsk/soa1dg/vol09
                     20971520 10677761 9650500    53%    /u09


This is the vfstab :

Code:
# cat /etc/vfstab
#device         device          mount           FS      fsck    mount   mount
#to mount       to fsck         point           type    pass    at boot options
#
fd      -       /dev/fd fd      -       no      -
/proc   -       /proc   proc    -       no      -
#/dev/dsk/c0t0d0s1      -       -       swap    -       no      -
/dev/dsk/c0t0d0s0       /dev/rdsk/c0t0d0s0      /       ufs     1       no      -
/devices        -       /devices        devfs   -       no      -
sharefs -       /etc/dfs/sharetab       sharefs -       no      -
ctfs    -       /system/contract        ctfs    -       no      -
objfs   -       /system/object  objfs   -       no      -
swap    -       /tmp    tmpfs   -       yes     -
/dev/vx/dsk/soa1dg/vol09 /dev/vx/rdsk/soa1dg/vol09 /u09  vxfs  0  yes  -
L28bi02:/MP_UDR/MP/EMMUDR       -       /var/opt/BGw/ServerGroup1/CBiO/BSCS     nfs     -       yes     rw
#

This is mnttab :

Code:
# cat /etc/mnttab
/dev/dsk/c0t0d0s0       /       ufs     rw,intr,largefiles,logging,xattr,onerror=panic,dev=780040       1398071817
/devices        /devices        devfs   dev=4cc0000     1398071772
ctfs    /system/contract        ctfs    dev=4d40001     1398071772
proc    /proc   proc    dev=4d00000     1398071772
mnttab  /etc/mnttab     mntfs   dev=4d80001     1398071772
swap    /etc/svc/volatile       tmpfs   xattr,dev=4dc0001       1398071772
objfs   /system/object  objfs   dev=4e00001     1398071772
sharefs /etc/dfs/sharetab       sharefs dev=4e40001     1398071772
/usr/lib/libc/libc_hwcap1.so.1  /lib/libc.so.1  lofs    dev=780040      1398071816
fd      /dev/fd fd      rw,dev=4fc0001  1398071817
swap    /tmp    tmpfs   xattr,dev=4dc0002       1398071818
swap    /var/run        tmpfs   xattr,dev=4dc0003       1398071818
swap    /dev/vx/dmp     tmpfs   xattr,dev=4dc0004       1398071825
swap    /dev/vx/rdmp    tmpfs   xattr,dev=4dc0005       1398071825
/dev/odm        /dev/odm        odm     smartsync,dev=50c0000   1398071888
/dev/vx/dsk/bgw1dg/vol01        /var/opt/BGw/ServerGroup1       vxfs    rw,suid,delaylog,largefiles,qio,cluster,ioerror=mdisable,crw,mntlock=VCS,dev=4254050    1412612652
-hosts  /net    autofs  nosuid,indirect,ignore,nobrowse,dev=5080002     1491552593
L28emmfe1:vold(pid8624) /vol    nfs     ignore,noquota,dev=5040005      1491552604
/dev/vx/dsk/soa1dg/vol09        /u09    vxfs    rw,suid,delaylog,largefiles,qio,ioerror=mwdisable,dev=4246d60   1491831682
#

I need to clear up some space in this server to create a different filesystem with the size of 500G.

How do I remove the swap files, and also /lib/libc.so.1?
Also is it possible to shrink the size of / ? How do I do this?

These are the steps I have done to remove /lib/libc.so.1 :

Code:
# umount -f /lib/libc.so.1
umount: Operation not supported
umount: cannot unmount /lib/libc.so.1
#

Why do I get this error, and how do I resolve it and of course remove this partition?

These are the steps I have taken to remove swap :

Code:
# swap -d /var/run
/var/run: Is a directory

Please help.
# 2  
Old 06-02-2017
The only real swap space was the
Code:
#/dev/dsk/c0t0d0s1      -       -       swap    -       no      -

where the fstype (column 4) is swap. But now disabled by the leading comment sign.
The current real swap space is shown with swap -l (in blocks = half kilobytes).
The swap in the first column means the filesystem is mapped to the virtual system memory (that consists of RAM + swap and is shown with swap -s).
Likewise the lofs filesystem is mapped to the filesystem it is mounted from.
To find unused disk space you can try Veritas volume manager commands like vxprint or vxdisk list; please consult your Veritas documentation.
# 3  
Old 06-04-2017
Quote:
How do I remove the swap files, and also /lib/libc.so.1?
If you do manage to sucessfully unmount /lib/libc.so.1, you'll likely have to pull the plug to reboot - and hope /lib/libc.so.1 comes back.

See Whats this lofs mount onto /lib/libc.so.1 in Solaris 10 ? | Oracle darren_moffat@blog$ cat /dev/mem | grep /dev/urandom Blog
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Removing PATTERN from txt without removing lines and general text formatting

Hi Everybody! First post! Totally noobie. I'm using the terminal to read a poorly formatted book. The text file contains, in the middle of paragraphs, hyphenation to split words that are supposed to be on multiple pages. It looks ve -- ry much like this. I was hoping to use grep -v " -- "... (5 Replies)
Discussion started by: AxeHandle
5 Replies

2. Solaris

Explain the output of swap -s and swap -l

Hi Solaris Folks :), I need to calculate the swap usage on solaris server, please let me understand the output of below swap -s and swap -l commands. $swap -s total: 1774912k bytes allocated + 240616k reserved = 2015528k used, 14542512k available $swap -l swapfile dev swaplo... (6 Replies)
Discussion started by: seenuvasan1985
6 Replies

3. Shell Programming and Scripting

filesystems > 70%

I need a scrip that will show me the filesystems that are greater than 70%...but not sure how to filter using the df -h | grep Thank you for your help!! (6 Replies)
Discussion started by: eponcedeleonc
6 Replies

4. HP-UX

Swap device file and swap sapce

Hi I have an integrity machine rx7620 and rx8640 running hp-ux 11.31. I'm planning to fine tune the system: - I would like to know when does the memory swap space spill over to the device swap space? - And how much % of memory swap utilization should be specified (swap space device... (6 Replies)
Discussion started by: lamoul
6 Replies

5. Red Hat

swap not defined as swap

free -m : 1023 total swap space created default partition /dev/sdb1 50M using fdisk. i did write the changes. #mkswap /dev/sdb1 #swapon /dev/sdb1 free -m : 1078 total swap space this shows that the swap is on Question : i did not change the type LINUX SWAP (82) in fdisk. so why is... (5 Replies)
Discussion started by: dplinux
5 Replies

6. Solaris

Adding and removing ZFS filesystems in Zones

I have a Solaris 10 container that is running on ZFS filesystems being presented from the Global Zone. I have a filesystem presented to the Local zone and my user wants me to remove it. It there any way I can remove this while the zone is running? I tried unmounting it from the local zone... (0 Replies)
Discussion started by: BG_JrAdmin
0 Replies

7. Solaris

Swap config - Mirror swap or not?

Hello and thanks in advance. I have a Sun box with raid 1 on the O/S disks using solaris svm. I want to unmirror my swap partition, and add the slice on the second disk as an additional swap device. This would give me twice as much swap space. I have been warned not to do this by some... (3 Replies)
Discussion started by: BG_JrAdmin
3 Replies

8. Shell Programming and Scripting

Filesystems GT 95%

Hi How can I only print the file systems that are more than 95% full. I used the df -k output and tried to check for each file system and then print only the ones that meet the criteria... But my solution seems cloodgie ... (3 Replies)
Discussion started by: YS2002
3 Replies

9. UNIX for Advanced & Expert Users

Filesystems

my partner change the server's ip address and now i can't to mount the oracle's filesystem, what i do? i don't want to reinstall Unix. My unix is SCO UNIX 5.0.5 (9 Replies)
Discussion started by: marun
9 Replies
Login or Register to Ask a Question