Open main menu

OpenVZ Virtuozzo Containers Wiki β

Changes

Ubstat system call

5 bytes added, 14:06, 20 January 2011
no edit summary
The macros and data typed used are declared in <code>include/ub/ub_stat.h</code> file.
=== Arguments description ===
'''<code>func</code>''' is like <code>cmd</code> in the <code>ioctl</code> system call. It can be one of
'''<code>size</code>''' is the <code>buf</code> memory size.
=== The statistics format ===The format of data rerurned returned into the buffer depends on the function requested.
'''1. <code>UBSTAT_READ_ONE</code>''' format is
=== Return value ===
The system call returns -1 in case error has occurred. In case of <code>UBSTAT_UBPARMNUM</code > it returns <code>UB_RESOURCES</code> and in all other cases it returns the amount of bytes written to the <code>buf</code>.
== Demo ==