Date: Mon, 29 Mar 2021 01:17:37 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 254635] vmstat libxo output malformed Message-ID: <bug-254635-227@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D254635 Bug ID: 254635 Summary: vmstat libxo output malformed Product: Base System Version: 12.2-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: bin Assignee: bugs@FreeBSD.org Reporter: nijave@gmail.com JSON when used with `-w` flag ``` # vmstat --libxo json -w 5 {"__version": "1", "processes": {"runnable":63,"waiting":9,"swapped-out":2} , "memory": {"available-memory":" 36G","free-memory":" 1.2G","total-page-faults":4593} , "paging-rates": {"page-reactivated":5,"paged-in":0,"paged-out":22,"freed":6717,"scanned":72= 2} , "device": [{"name":"da0","transfers":"0"}, {"name":"da1","transfers":"0"}= ], "fault-rates": {"interrupts":1169,"system-calls":68996,"context-switches":39163} , "cpu-statistics": {"user":" 8","system":"21","idle":"71"} , "processes": {"runnable":51,"waiting":9,"swapped-out":2} , "memory": {"available-memory":" 37G","free-memory":" 1.2G","total-page-faults":4576} , "paging-rates": {"page-reactivated":0,"paged-in":0,"paged-out":47,"freed":3771,"scanned":38= 34} , "device": [{"name":"da0","transfers":"0"}, {"name":"da1","transfers":"17"= }], "fault-rates": {"interrupts":421,"system-calls":106121,"context-switches":19317} , "cpu-statistics": {"user":"87","system":"13","idle":" 0"} ``` (space added between successive outputs). I'd expect either json lines or back-to-back complete json objects but the second iteration returns a parti= al blob ``` # vmstat --libxo xml <processes version=3D"1"><runnable>30</runnable><waiting>9</waiting><swapped-out>2</sw= apped-out></processes><memory><available-memory value=3D"39004778496"> 36G</available-memory><free-memory value=3D"1409699= 840"> 1.3G</free-memory><total-page-faults>4592</total-page-faults></memory><pagi= ng-rates><page-reactivated>5</page-reactivated><paged-in>0</paged-in><paged= -out>22</paged-out><freed>6713</freed><scanned>728</scanned></paging-rates>= <device><name>da0</name><transfers>0</transfers></device><device><name>da1<= /name><transfers>0</transfers></device><fault-rates><interrupts>1168</inter= rupts><system-calls>69080</system-calls><context-switches>39135</context-sw= itches></fault-rates><cpu-statistics><user> 8</user><system>21</system><idle>71</idle></cpu-statistics> ``` XML is missing root element. Using `-w` prints successive like the above example Not sure if these issues are related but in both cases there are issues with the libxo output --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-254635-227>