]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
man: document the new by-fd journal calls
authorLennart Poettering <lennart@poettering.net>
Mon, 25 Apr 2016 09:39:38 +0000 (11:39 +0200)
committerLennart Poettering <lennart@poettering.net>
Mon, 25 Apr 2016 17:29:01 +0000 (19:29 +0200)
Also, remove documentation for sd_journal_open_container() as we consider it
deprecated now.

Makefile-man.am
man/sd_journal_open.xml

index 7514e6a24fabb7f80aa64272ce078f41d196aff5..d5b328d267145557192e9dd43b9da4c45896393c 100644 (file)
@@ -242,6 +242,7 @@ MANPAGES_ALIAS += \
        man/SD_JOURNAL_INVALIDATE.3 \
        man/SD_JOURNAL_LOCAL_ONLY.3 \
        man/SD_JOURNAL_NOP.3 \
+       man/SD_JOURNAL_OS_ROOT.3 \
        man/SD_JOURNAL_RUNTIME_ONLY.3 \
        man/SD_JOURNAL_SUPPRESS_LOCATION.3 \
        man/SD_JOURNAL_SYSTEM.3 \
@@ -388,9 +389,10 @@ MANPAGES_ALIAS += \
        man/sd_journal_get_timeout.3 \
        man/sd_journal_has_persistent_files.3 \
        man/sd_journal_next_skip.3 \
-       man/sd_journal_open_container.3 \
        man/sd_journal_open_directory.3 \
+       man/sd_journal_open_directory_fd.3 \
        man/sd_journal_open_files.3 \
+       man/sd_journal_open_files_fd.3 \
        man/sd_journal_perror.3 \
        man/sd_journal_previous.3 \
        man/sd_journal_previous_skip.3 \
@@ -571,6 +573,7 @@ man/SD_JOURNAL_FOREACH_UNIQUE.3: man/sd_journal_query_unique.3
 man/SD_JOURNAL_INVALIDATE.3: man/sd_journal_get_fd.3
 man/SD_JOURNAL_LOCAL_ONLY.3: man/sd_journal_open.3
 man/SD_JOURNAL_NOP.3: man/sd_journal_get_fd.3
+man/SD_JOURNAL_OS_ROOT.3: man/sd_journal_open.3
 man/SD_JOURNAL_RUNTIME_ONLY.3: man/sd_journal_open.3
 man/SD_JOURNAL_SUPPRESS_LOCATION.3: man/sd_journal_print.3
 man/SD_JOURNAL_SYSTEM.3: man/sd_journal_open.3
@@ -717,9 +720,10 @@ man/sd_journal_get_monotonic_usec.3: man/sd_journal_get_realtime_usec.3
 man/sd_journal_get_timeout.3: man/sd_journal_get_fd.3
 man/sd_journal_has_persistent_files.3: man/sd_journal_has_runtime_files.3
 man/sd_journal_next_skip.3: man/sd_journal_next.3
-man/sd_journal_open_container.3: man/sd_journal_open.3
 man/sd_journal_open_directory.3: man/sd_journal_open.3
+man/sd_journal_open_directory_fd.3: man/sd_journal_open.3
 man/sd_journal_open_files.3: man/sd_journal_open.3
+man/sd_journal_open_files_fd.3: man/sd_journal_open.3
 man/sd_journal_perror.3: man/sd_journal_print.3
 man/sd_journal_previous.3: man/sd_journal_next.3
 man/sd_journal_previous_skip.3: man/sd_journal_next.3
@@ -1034,6 +1038,9 @@ man/SD_JOURNAL_LOCAL_ONLY.html: man/sd_journal_open.html
 man/SD_JOURNAL_NOP.html: man/sd_journal_get_fd.html
        $(html-alias)
 
+man/SD_JOURNAL_OS_ROOT.html: man/sd_journal_open.html
+       $(html-alias)
+
 man/SD_JOURNAL_RUNTIME_ONLY.html: man/sd_journal_open.html
        $(html-alias)
 
@@ -1472,15 +1479,18 @@ man/sd_journal_has_persistent_files.html: man/sd_journal_has_runtime_files.html
 man/sd_journal_next_skip.html: man/sd_journal_next.html
        $(html-alias)
 
-man/sd_journal_open_container.html: man/sd_journal_open.html
+man/sd_journal_open_directory.html: man/sd_journal_open.html
        $(html-alias)
 
-man/sd_journal_open_directory.html: man/sd_journal_open.html
+man/sd_journal_open_directory_fd.html: man/sd_journal_open.html
        $(html-alias)
 
 man/sd_journal_open_files.html: man/sd_journal_open.html
        $(html-alias)
 
+man/sd_journal_open_files_fd.html: man/sd_journal_open.html
+       $(html-alias)
+
 man/sd_journal_perror.html: man/sd_journal_print.html
        $(html-alias)
 
index 6c362c2f9159f1ac8565f2cd981b80bd6a3cb1e1..153af2387f5a47d068fa1dcf8da02228b3b479c3 100644 (file)
   <refnamediv>
     <refname>sd_journal_open</refname>
     <refname>sd_journal_open_directory</refname>
+    <refname>sd_journal_open_directory_fd</refname>
     <refname>sd_journal_open_files</refname>
-    <refname>sd_journal_open_container</refname>
+    <refname>sd_journal_open_files_fd</refname>
     <refname>sd_journal_close</refname>
     <refname>sd_journal</refname>
     <refname>SD_JOURNAL_LOCAL_ONLY</refname>
     <refname>SD_JOURNAL_RUNTIME_ONLY</refname>
     <refname>SD_JOURNAL_SYSTEM</refname>
     <refname>SD_JOURNAL_CURRENT_USER</refname>
+    <refname>SD_JOURNAL_OS_ROOT</refname>
     <refpurpose>Open the system journal for reading</refpurpose>
   </refnamediv>
 
         <paramdef>int <parameter>flags</parameter></paramdef>
       </funcprototype>
 
+      <funcprototype>
+        <funcdef>int <function>sd_journal_open_directory_fd</function></funcdef>
+        <paramdef>sd_journal **<parameter>ret</parameter></paramdef>
+        <paramdef>int <parameter>fd</parameter></paramdef>
+        <paramdef>int <parameter>flags</parameter></paramdef>
+      </funcprototype>
+
       <funcprototype>
         <funcdef>int <function>sd_journal_open_files</function></funcdef>
         <paramdef>sd_journal **<parameter>ret</parameter></paramdef>
       </funcprototype>
 
       <funcprototype>
-        <funcdef>int <function>sd_journal_open_container</function></funcdef>
+        <funcdef>int <function>sd_journal_open_files_fd</function></funcdef>
         <paramdef>sd_journal **<parameter>ret</parameter></paramdef>
-        <paramdef>const char *<parameter>machine</parameter></paramdef>
+        <paramdef>int <parameter>fds[]</parameter></paramdef>
+        <paramdef>unsigned <parameter>n_fds</parameter></paramdef>
         <paramdef>int <parameter>flags</parameter></paramdef>
       </funcprototype>
 
     <constant>SD_JOURNAL_CURRENT_USER</constant> are specified, all
     journal file types will be opened.</para>
 
-    <para><function>sd_journal_open_directory()</function> is similar
-    to <function>sd_journal_open()</function> but takes an absolute
-    directory path as argument. All journal files in this directory
-    will be opened and interleaved automatically. This call also takes
-    a flags argument, but it must be passed as 0 as no flags are
-    currently understood for this call.</para>
-
-    <para><function>sd_journal_open_files()</function> is similar to
-    <function>sd_journal_open()</function> but takes a
-    <constant>NULL</constant>-terminated list of file paths to open.
-    All files will be opened and interleaved automatically. This call
-    also takes a flags argument, but it must be passed as 0 as no
-    flags are currently understood for this call. Please note that in
-    the case of a live journal, this function is only useful for
-    debugging, because individual journal files can be rotated at any
-    moment, and the opening of specific files is inherently
-    racy.</para>
-
-    <para><function>sd_journal_open_container()</function> is similar
-    to <function>sd_journal_open()</function> but opens the journal
-    files of a running OS container. The specified machine name refers
-    to a container that is registered with
-    <citerefentry><refentrytitle>systemd-machined</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
+    <para><function>sd_journal_open_directory()</function> is similar to <function>sd_journal_open()</function> but
+    takes an absolute directory path as argument. All journal files in this directory will be opened and interleaved
+    automatically. This call also takes a flags argument. The only flags parameter accepted by this call is
+    <constant>SD_JOURNAL_OS_ROOT</constant>. If specified, the journal files are searched below the usual
+    <filename>/var/log/journal</filename> and <filename>/run/log/journal</filename> relative to the specified path,
+    instead of directly beneath it.</para>
+
+    <para><function>sd_journal_open_directory_fd()</function> is similar to
+    <function>sd_journal_open_directory()</function>, but takes a file descriptor referencing a directory in the file
+    system instead of an absolute file system path.</para>
+
+    <para><function>sd_journal_open_files()</function> is similar to <function>sd_journal_open()</function> but takes a
+    <constant>NULL</constant>-terminated list of file paths to open.  All files will be opened and interleaved
+    automatically. This call also takes a flags argument, but it must be passed as 0 as no flags are currently
+    understood for this call. Please note that in the case of a live journal, this function is only useful for
+    debugging, because individual journal files can be rotated at any moment, and the opening of specific files is
+    inherently racy.</para>
+
+    <para><function>sd_journal_open_files_fd()</function> is similar to <function>sd_journal_open_files()</function>
+    but takes an array of open file descriptors that must reference journal files, instead of an array of file system
+    paths. Pass the array of file descriptors as second argument, and the number of array entries in the third. The
+    flags parameter must be passed as 0.</para>
 
     <para><varname>sd_journal</varname> objects cannot be used in the
     child after a fork. Functions which take a journal object as an