Skip to content

[Solaris] Swap output wrong on some OS versions #1874

Closed
@jomann09

Description

Platform

  • Solaris 11.4
  • psutil 5.7.3
  • Any version

Bug description
It looks like on Solaris 11.4 the output of the swap command can have an "encrypted" column.

$ /usr/sbin/swap -l
swapfile                 dev            swaplo      blocks        free encrypted
/dev/zvol/dsk/rpool/swap 303,5               0     8388608     7072944      yes

which is likely causing an issue with this line here: https://github.com/giampaolo/psutil/blob/master/psutil/_pssunos.py#L158 and may be able to be remedied by using line[3:4] instead of line[-2:]

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions