Sets the log full policy of a trace stream.
Posix Trace Library (libposixtrace.a)
The posix_trace_attr_setlogfullpolicy subroutine sets the trace log full policy stored in log-full-policy attribute of the attr object. The attr parameter points to the attribute object to get log full policy.
Item | Description |
---|---|
POSIX_TRACE_LOOP | The trace log loops until the associated trace stream is stopped. When the trace log gets full, the file system reuses the resources allocated to the oldest trace events that were recorded. In this way, the trace log always contains the most recent trace events that are flushed. |
POSIX_TRACE_UNTIL_FULL | The trace stream is flushed to the trace log until the trace log is full. This condition can be deduced from the posix_log_full_status member status (see the posix_trace_status_info structure defined in the trace.h header file). The last recorded trace event is the POSIX_TRACE_STOP trace event. |
POSIX_TRACE_APPEND | The associated trace stream is flushed to the trace log without log size limitation. If the application specifies the POSIX_TRACE_APPEND value, the log-max-size attribute is ignored. |
The default value for the log-full-policy attribute is POSIX_TRACE_LOOP.
If the subroutine is called with a non-initialized attributes object as parameter, the result is not specified.
Item | Description |
---|---|
attr | Specifies the trace attributes object. |
logpolicy | Specifies where the log-full-policy attribute of the attr parameter is attained. |
Upon successful completion, the subroutine returns a value of zero. Otherwise, it returns the corresponding error number.
Item | Description |
---|---|
EINVAL | The attr parameter is null or the other parameter is not valid. |
The trace.h file in AIX® Version 7.1 Files Reference