Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Solaris Containers: Resource Management and Solaris Zones Developer's Guide
Previous Next

Programming Issues With exacct Files

  • Memory management

    • Use the same allocation flags for ea_free_object() and ea_unpack_object().

    • For string objects, an ea_set_item() results in allocation, and should be followed by ea_free_item(obj, EUP_ALLOC) to free internal storage.

    • ea_pack_object() and getacct() use zero size. To get size. getacct() should be called twice: first time with NULL buffer to size buffer to be passed in the second call. See Example 3-1 in C Code Examples for Accessing exacct Files.

  • Applications should skip unknown exacct records in exacct files produced by the system, to be robust in the face of changes to exacct file content.

  • Use EXC_LOCAL for customized accounting. Application-specific records can be created using EXC_LOCAL. Use libexacct as general tracing or debugging facility.

    • See <sys/exacct_catalog.h>.

    • Data id field of ea_catalog_t can be customized.

Previous Next

 
 
  Published under the terms fo the Public Documentation License Version 1.01. Design by Interspire