- trixie-backports 4.30.0-1~bpo13+2
| acct(2) | System Calls Manual | acct(2) |
이름¶
acct - 프로세스 계정 작업을 활성화시키거나 비활성화시킨다.
라이브러리¶
표준 C 라이브러리 (libc, -lc)
요약¶
#include <unistd.h>
int acct(const char *_Nullable filename);
acct():
Since glibc 2.21:
_DEFAULT_SOURCE
In glibc 2.19 and 2.20:
_DEFAULT_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE < 500)
Up to and including glibc 2.19:
_BSD_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE < 500)
설명¶
The acct() system call enables or disables process accounting. If called with the name of an existing file as its argument, accounting is turned on, and records for each terminating process are appended to filename as it terminates. An argument of NULL causes accounting to be turned off.
반환값¶
On success, zero is returned. On error, -1 is returned, and errno is set to indicate the error.
에러¶
- EACCES
- Write permission is denied for the specified file, or search permission is denied for one of the directories in the path prefix of filename (see also path_resolution(7)), or filename is not a regular file.
- EFAULT
- filename 가 접근할수 있는 주소 공간외를 가리키고 있다.
- EIO
- filename 파일에 쓰기 오류.
- EISDIR
- filename is a directory.
- ELOOP
- filename 의 링크가 너무 많다.
- ENAMETOOLONG
- filename이 너무 길다.
- ENFILE
- The system-wide limit on the total number of open files has been reached.
- ENOENT
- 지정된 파일이 존재하지 않는다.
- ENOMEM
- 메모리가 부족하다.
- ENOSYS
- BSD 프로세스 어카운팅 커널 옵션이 활성화되지 않았다. 이 기능을 제어하는 커널 옵션은 CONFIG_BSD_PROCESS_ACCT 이다.
- ENOTDIR
- filename 에서 디렉토리로써 사용된 요소가 사실은 디렉토리가 아니다.
- EPERM
- The calling process has insufficient privilege to enable process accounting. On Linux, the CAP_SYS_PACCT capability is required.
- EROFS
- filename 가 읽기-전용 파일 시스템에 있는 파일을 가리킨다.
- EUSERS
- 여분의 공간이나 메모리가 부족하다.
표준¶
None.
이력¶
SVr4, 4.3BSD.
주의¶
No accounting is produced for programs running when a system crash occurs. In particular, nonterminating processes are never accounted for.
The structure of the records written to the accounting file is described in acct(5).
추가 참조¶
번역¶
이 매뉴얼 페이지의 한국어 번역은 다음에 의해 편집되었습니다: ASPLINUX <man@asp-linux.co.kr>
이 번역은 무료 문서입니다. 저작권 조건에 대해서는 GNU General Public License 버전 3 이상을 읽으십시오. 책임이 없습니다.
이 매뉴얼 페이지의 번역에서 오류를 발견하면 translation-team-ko@googlegroups.com 로 이메일을 보내주십시오.
| 2024년 5월 2일 | Linux man-pages 6.9.1 |