From a1a03e3075316e2376176fc54c74e071adc9d71a Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 7 Sep 2012 23:20:28 +0200 Subject: journal: add call to determine current journal file disk usage --- man/journalctl.xml | 8 ++++ man/sd-journal.xml | 4 +- man/sd_journal_get_usage.xml | 104 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 115 insertions(+), 1 deletion(-) create mode 100644 man/sd_journal_get_usage.xml (limited to 'man') diff --git a/man/journalctl.xml b/man/journalctl.xml index 296e3fd2ff..9800cf30ed 100644 --- a/man/journalctl.xml +++ b/man/journalctl.xml @@ -320,6 +320,14 @@ accessed. + + + + Shows the current disk + usage of all + journal files. + + diff --git a/man/sd-journal.xml b/man/sd-journal.xml index b6241a1767..773689c692 100644 --- a/man/sd-journal.xml +++ b/man/sd-journal.xml @@ -78,7 +78,8 @@ sd_journal_add_match3, sd_journal_seek_head3, sd_journal_get_cursor3, - sd_journal_cutoff_realtime_usec3 + sd_journal_cutoff_realtime_usec3, + sd_journal_get_usage3 and sd_journal_get_fd3 for more information about the functions @@ -116,6 +117,7 @@ sd_journal_seek_head3, sd_journal_get_cursor3, sd_journal_cutoff_realtime_usec3, + sd_journal_get_usage3, journalctl1, sd-id1283, pkg-config1 diff --git a/man/sd_journal_get_usage.xml b/man/sd_journal_get_usage.xml new file mode 100644 index 0000000000..14eb1e2b79 --- /dev/null +++ b/man/sd_journal_get_usage.xml @@ -0,0 +1,104 @@ + + + + + + + + + sd_journal_get_usage + systemd + + + + Developer + Lennart + Poettering + lennart@poettering.net + + + + + + sd_journal_get_usage + 3 + + + + sd_journal_get_usage + Journal disk usage + + + + + #include <systemd/sd-journal.h> + + + int sd_journal_get_usage + sd_journal* j + uint64_t* bytes + + + + + + + Description + + sd_journal_get_usage() + determines the total disk space currently used up by + journal files. If + SD_JOURNAL_LOCAL_ONLY has been + passed when opening the journal files this value will + only reflect the size of journal files of the local + host, otherwise of all hosts. + + + + Return Value + + sd_journal_get_usage() + returns 0 on success or a negative errno-style error + code. + + + + Notes + + The sd_journal_get_usage() + interface is available as shared library, which can be + compiled and linked to with the + libsystemd-journal + pkg-config1 + file. + + + + See Also + + + systemd1, + sd-journal3, + sd_journal_open3, + + + + -- cgit v1.2.3-54-g00ecf