Multiple swap spaces after refresh Solaris 11.3 install on Sparc T5-2

Hi
The following is the output of "df -h" and "zfs list" right after fresh installation of Solaris 11.3 on Sparc T5-2 with 256GB memory. Because the server has 256GB of memory, I think Solaris created swap file system mounted on /system/volatile and /tmp, but my question is, zfs also has zpool/swap with 4G which is not much compared to the memory, do I really need this 4G swap space under zpool?
Thanks

root@solaris:/#  df -h

Filesystem                           Size   Used  Available Capacity  Mounted on
rpool/ROOT/solaris          547G   2.9G       409G     1%    /
/devices                                 0K     0K         0K     0%    /devices
/dev                                        0K     0K         0K     0%    /dev
ctfs                                         0K     0K         0K     0%    /system/contract
proc                                        0K     0K         0K     0%    /proc
mnttab                                    0K     0K         0K     0%    /etc/mnttab
swap                                   243G   2.7M       243G     1%    /system/volatile
objfs                                        0K     0K         0K     0%    /system/object
sharefs                                    0K     0K         0K     0%    /etc/dfs/sharetab
fd                                            0K     0K         0K     0%    /dev/fd
rpool/ROOT/solaris/var     547G   237M       409G     1%    /var
swap                                   243G     8K       243G     1%    /tmp
rpool/VARSHARE             547G   2.4M       409G     1%    /var/share
rpool/VARSHARE/zones   547G    31K       409G     1%    /system/zones
rpool/export                        547G    32K       409G     1%    /export
rpool/export/home              547G    32K       409G     1%    /export/home
rpool                                   547G    73K       409G     1%    /rpool

root@solaris:/#  zfs list

NAME                              USED  AVAIL  REFER  MOUNTPOINT
rpool                                  139G   409G  73.5K  /rpool
rpool/ROOT                      3.13G   409G    31K  legacy
rpool/ROOT/solaris          3.13G   409G  2.89G  /
rpool/ROOT/solaris/var     239M   409G   237M  /var
rpool/VARSHARE            2.53M   409G  2.44M  /var/share
rpool/VARSHARE/zones     31K   409G    31K  /system/zones
rpool/dump                         132G   413G   128G  -
rpool/export                        97.5K   409G    32K  /export
rpool/export/home              65.5K   409G    32K  /export/home
rpool/swap                          4.13G   409G  4.00G  -

This explains zfs dump and swap as well as sizing:

Managing Your ZFS Swap and Dump Devices - Oracle Solaris Administration: ZFS File Systems

1 Like

I'm afraid you are misinterpreting the statistics.

Please post "swap -l" and "swap -s" output.

It would also help readability if you fix the initial posting with the correct "df" and "zfs list" outputs. They should be properly aligned.

The below are the output of swap -l and swap -s

root@solaris:/# swap -l -h
swapfile             dev    swaplo   blocks     free
/dev/zvol/dsk/rpool/swap 303,1        8K     4.0G     4.0G

root@solaris:/# swap -s -h
total: 776M allocated + 51M reserved = 824M used, 242G available
  1. There are no "multiple swap spaces", /tmp and /system/volatile are using the same back-end which is your system virtual memory which size is around 243 GB and essentially made of RAM (minus 4GB).
  2. You currently don't need the 4 GB of disk space dedicated to swap, and by far. However, I would recommend not only to keep it as is in the long term, but even to increase its size. Otherwise, there is a risk part of your RAM being wasted should you start to heavily use it.
1 Like

This is also dependent for what you wish to use your server.
Do you plan to use Oracle VM, zones or you plan to run services on bare metal ?

For OVM, hypervisor sizing should be minimal (couple of cores and 4-8 GB of RAM should suffice, depending), ldoms should be sized per resources assigned to them (link below).

Link :
Planning for Swap Space -
Managing File Systems in Oracle(R) Solaris
11.3

Hope that helps
Regards
Peasant.