[systemd-commits] 5 commits - man/hostnamectl.xml man/journalctl.xml man/localectl.xml man/loginctl.xml man/systemctl.xml man/systemd-bootchart.xml man/systemd-coredumpctl.xml man/systemd-delta.xml man/systemd-nspawn.xml man/timedatectl.xml src/shared src/test

Zbigniew Jędrzejewski-Szmek zbyszek at kemper.freedesktop.org
Wed Feb 13 06:01:29 PST 2013


 man/hostnamectl.xml         |    2 
 man/journalctl.xml          |   26 ++++++------
 man/localectl.xml           |    2 
 man/loginctl.xml            |    8 +--
 man/systemctl.xml           |   18 ++++----
 man/systemd-bootchart.xml   |   92 ++++++++++++++++++++++++++++++++++++++++++--
 man/systemd-coredumpctl.xml |    6 +-
 man/systemd-delta.xml       |    2 
 man/systemd-nspawn.xml      |   10 ++--
 man/timedatectl.xml         |    2 
 src/shared/ratelimit.c      |    2 
 src/test/test-udev.c        |    1 
 src/test/test-unit-file.c   |   21 ++++++++++
 13 files changed, 150 insertions(+), 42 deletions(-)

New commits:
commit a7f5bb1eafadbb08c8528baae588bbe773a37e79
Author: William Giokas <1007380 at gmail.com>
Date:   Wed Feb 13 03:39:22 2013 -0600

    man: Make options consistent
    
    Option listings seemed to be pretty much random, some were short opt,
    long opt, others were long opt, short opt. This just makes every option
    with a short and long opt that I could find in the order short opt, long
    opt, for formatting's sake.

diff --git a/man/hostnamectl.xml b/man/hostnamectl.xml
index 07d3634..9efe220 100644
--- a/man/hostnamectl.xml
+++ b/man/hostnamectl.xml
@@ -93,8 +93,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
diff --git a/man/journalctl.xml b/man/journalctl.xml
index d8f8f68..5ed0e1f 100644
--- a/man/journalctl.xml
+++ b/man/journalctl.xml
@@ -114,8 +114,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
@@ -143,8 +143,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--all</option></term>
                                 <term><option>-a</option></term>
+                                <term><option>--all</option></term>
 
                                 <listitem><para>Show all fields in
                                 full, even if they include unprintable
@@ -153,8 +153,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--follow</option></term>
                                 <term><option>-f</option></term>
+                                <term><option>--follow</option></term>
 
                                 <listitem><para>Show only the most recent
                                 journal entries, and continuously print
@@ -163,8 +163,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--lines=</option></term>
                                 <term><option>-n</option></term>
+                                <term><option>--lines=</option></term>
 
                                 <listitem><para>Show the most recent
                                 journal events and limit the number of
@@ -185,8 +185,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--output=</option></term>
                                 <term><option>-o</option></term>
+                                <term><option>--output=</option></term>
 
                                 <listitem><para>Controls the
                                 formatting of the journal entries that
@@ -240,8 +240,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--catalog</option></term>
                                 <term><option>-x</option></term>
+                                <term><option>--catalog</option></term>
 
                                 <listitem><para>Augment log lines with
                                 explanation texts from the message
@@ -264,8 +264,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--quiet</option></term>
                                 <term><option>-q</option></term>
+                                <term><option>--quiet</option></term>
 
                                 <listitem><para>Suppresses any warning
                                 message regarding inaccessible system
@@ -274,8 +274,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--merge</option></term>
                                 <term><option>-m</option></term>
+                                <term><option>--merge</option></term>
 
                                 <listitem><para>Show entries
                                 interleaved from all available
@@ -284,8 +284,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--this-boot</option></term>
                                 <term><option>-b</option></term>
+                                <term><option>--this-boot</option></term>
 
                                 <listitem><para>Show data only from
                                 current boot. This will add a match
@@ -295,8 +295,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--unit=</option></term>
                                 <term><option>-u</option></term>
+                                <term><option>--unit=</option></term>
 
                                 <listitem><para>Show data only of the
                                 specified unit. This will add a match
@@ -341,8 +341,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--cursor=</option></term>
                                 <term><option>-c</option></term>
+                                <term><option>--cursor=</option></term>
 
                                 <listitem><para>Start showing entries
                                 from the location in the journal
@@ -381,8 +381,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--field=</option></term>
                                 <term><option>-F</option></term>
+                                <term><option>--field=</option></term>
 
                                 <listitem><para>Print all possible
                                 data values the specified field can
@@ -391,8 +391,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--directory=</option></term>
                                 <term><option>-D</option></term>
+                                <term><option>--directory=</option></term>
 
                                 <listitem><para>Takes an absolute
                                 directory path as argument. If
diff --git a/man/localectl.xml b/man/localectl.xml
index 3e5b812..5e7886c 100644
--- a/man/localectl.xml
+++ b/man/localectl.xml
@@ -79,8 +79,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
diff --git a/man/loginctl.xml b/man/loginctl.xml
index ba0352c..2c8d982 100644
--- a/man/loginctl.xml
+++ b/man/loginctl.xml
@@ -69,8 +69,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
@@ -84,8 +84,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--property=</option></term>
                                 <term><option>-p</option></term>
+                                <term><option>--property=</option></term>
 
                                 <listitem><para>When showing
                                 session/user properties, limit
@@ -101,8 +101,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--all</option></term>
                                 <term><option>-a</option></term>
+                                <term><option>--all</option></term>
 
                                 <listitem><para>When showing
                                 unit/job/manager properties, show all
@@ -148,8 +148,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--signal=</option></term>
                                 <term><option>-s</option></term>
+                                <term><option>--signal=</option></term>
 
                                 <listitem><para>When used with
                                 <command>kill-session</command> or
diff --git a/man/systemctl.xml b/man/systemctl.xml
index 3842645..bf11cc3 100644
--- a/man/systemctl.xml
+++ b/man/systemctl.xml
@@ -69,8 +69,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
@@ -84,8 +84,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--type=</option></term>
                                 <term><option>-t</option></term>
+                                <term><option>--type=</option></term>
 
                                 <listitem><para>The argument should
                                 be a unit type name such as
@@ -115,8 +115,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--property=</option></term>
                                 <term><option>-p</option></term>
+                                <term><option>--property=</option></term>
 
                                 <listitem><para>When showing
                                 unit/job/manager properties, limit
@@ -132,8 +132,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--all</option></term>
                                 <term><option>-a</option></term>
+                                <term><option>--all</option></term>
 
                                 <listitem><para>When listing units,
                                 show all units, regardless of their
@@ -218,8 +218,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--quiet</option></term>
                                 <term><option>-q</option></term>
+                                <term><option>--quiet</option></term>
 
                                 <listitem><para>Suppress output to
                                 STDOUT in
@@ -370,8 +370,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--signal=</option></term>
                                 <term><option>-s</option></term>
+                                <term><option>--signal=</option></term>
 
                                 <listitem><para>When used with
                                 <command>kill</command>, choose which
@@ -384,8 +384,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--force</option></term>
                                 <term><option>-f</option></term>
+                                <term><option>--force</option></term>
 
                                 <listitem><para>When used with
                                 <command>enable</command>, overwrite any
@@ -463,8 +463,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--lines=</option></term>
                                 <term><option>-n</option></term>
+                                <term><option>--lines=</option></term>
 
                                 <listitem><para>When used with
                                 <command>status</command> controls the
@@ -476,8 +476,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--output=</option></term>
                                 <term><option>-o</option></term>
+                                <term><option>--output=</option></term>
 
                                 <listitem><para>When used with
                                 <command>status</command> controls the
diff --git a/man/systemd-coredumpctl.xml b/man/systemd-coredumpctl.xml
index 87ed6fa..ce40404 100644
--- a/man/systemd-coredumpctl.xml
+++ b/man/systemd-coredumpctl.xml
@@ -71,8 +71,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Print a short help
                                 text and exit.</para></listitem>
@@ -86,8 +86,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--field=</option></term>
                                 <term><option>-F</option></term>
+                                <term><option>--field=</option></term>
 
                                 <listitem><para>Print all possible
                                 data values the specified field
@@ -96,8 +96,8 @@
                         </varlistentry>
 
                         <varlistentry>
+                                <term><option>-o</option></term>
                                 <term><option>--output=FILE</option></term>
-                                <term><option>-o FILE</option></term>
 
                                 <listitem><para>Write the core to
                                 <option>FILE</option>.</para></listitem>
diff --git a/man/systemd-delta.xml b/man/systemd-delta.xml
index 072f55f..9293c9b 100644
--- a/man/systemd-delta.xml
+++ b/man/systemd-delta.xml
@@ -100,8 +100,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--type=</option></term>
                                 <term><option>-t</option></term>
+                                <term><option>--type=</option></term>
 
                                 <listitem><para>When listing the
                                 differences, only list those that are
diff --git a/man/systemd-nspawn.xml b/man/systemd-nspawn.xml
index 554637d..2fa00e8 100644
--- a/man/systemd-nspawn.xml
+++ b/man/systemd-nspawn.xml
@@ -132,8 +132,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
@@ -147,8 +147,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--directory=</option></term>
                                 <term><option>-D</option></term>
+                                <term><option>--directory=</option></term>
 
                                 <listitem><para>Directory to use as
                                 file system root for the namespace
@@ -158,8 +158,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--boot</option></term>
                                 <term><option>-b</option></term>
+                                <term><option>--boot</option></term>
 
                                 <listitem><para>Automatically search
                                 for an init binary and invoke it
@@ -168,8 +168,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--user=</option></term>
                                 <term><option>-u</option></term>
+                                <term><option>--user=</option></term>
 
                                 <listitem><para>Run the command
                                 under specified user, create home
@@ -192,8 +192,8 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term><option>--controllers=</option></term>
                                 <term><option>-C</option></term>
+                                <term><option>--controllers=</option></term>
 
                                 <listitem><para>Makes the container appear in
                                 other hierarchies than the name=systemd:/ one.
diff --git a/man/timedatectl.xml b/man/timedatectl.xml
index a8e78ae..faccc50 100644
--- a/man/timedatectl.xml
+++ b/man/timedatectl.xml
@@ -68,8 +68,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>--help</option></term>
                                 <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>

commit 5797606612b5b37dbba5d90b39665cdf7f7a1b11
Author: William Giokas <1007380 at gmail.com>
Date:   Wed Feb 13 03:38:49 2013 -0600

    man: Write man page for systemd-bootchart(1)
    
    Mostly coppied from bootchart.conf(5)

diff --git a/man/systemd-bootchart.xml b/man/systemd-bootchart.xml
index f31d4a0..7534110 100644
--- a/man/systemd-bootchart.xml
+++ b/man/systemd-bootchart.xml
@@ -10,6 +10,7 @@
 
   Authors:
     Auke Kok <auke-jan.h.kok at intel.com>
+    William Giokas <1007380 at gmail.com>
 
   systemd is free software; you can redistribute it and/or modify it
   under the terms of the GNU Lesser General Public License as published by
@@ -91,9 +92,94 @@
         <refsect1>
                 <title>Options</title>
 
-                <para>Please read systemd-bootchart --help or the bootchart.conf manual
-                page for information about the various options that influence how
-                systemd-bootchart operates.</para>
+                <variablelist class='bootchart-directives'>
+
+                        <varlistentry>
+                                <term><option>-n</option></term>
+                                <term><option>--sample N</option></term>
+                                <listitem><para>Specify the amount of samples to
+                                record total before bootchart exits. Each sample will
+                                record at intervals defined by --freq.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-f</option></term>
+                                <term><option>--freq N</option></term>
+                                <listitem><para>Specify the sample log frequency.
+                                This can be a fractional number, but must be larger than
+                                0.0. Most systems can cope with values under 25-50 without
+                                impacting boot time severely.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-r</option></term>
+                                <term><option>--rel</option></term>
+                                <listitem><para>Use relative times instead of absolute
+                                times. This is useful for using bootchart at post-boot
+                                time to profile an already booted system, otherwise the
+                                graph would become extremely large. If set, the
+                                horizontal axis starts at the first recorded sample
+                                instead of time=0.0.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-F</option></term>
+                                <term><option>--filter</option></term>
+                                <listitem><para>Disable filtering of tasks tasks that
+                                did not contribute significantly to the boot. Processes
+                                that are too short-lived (only seen in one sample) or
+                                that do not consume any significant CPU time (less than
+                                0.001sec) will not be displayed in the output graph.
+                                </para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-o</option></term>
+                                <term><option>--output [path]</option></term>
+                                <listitem><para>Configures the output folder for writing
+                                the graphs. By default, bootchart writes the graphs to
+                                <filename>/var/log</filename>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-i</option></term>
+                                <term><option>--init [path]</option></term>
+                                <listitem><para>Set init binary to run. Defaults to
+                                <filename>/sbin/init</filename>.
+                                </para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-p</option></term>
+                                <term><option>--pss</option></term>
+                                <listitem><para>Enable logging and graphing
+                                of processes PSS memory consumption.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-e</option></term>
+                                <term><option>--entropy</option></term>
+                                <listitem><para>Enable logging and graphing
+                                of the kernel random entropy pool size.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-x</option></term>
+                                <term><option>--scale-x N</option></term>
+                                <listitem><para>Horizontal scaling factor for all variable
+                                graph components.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-y</option></term>
+                                <term><option>--scale-y N</option></term>
+                                <listitem><para>Vertical scaling factor for all variable
+                                graph components.</para></listitem>
+                        </varlistentry>
+
+                </variablelist>
+
+
         </refsect1>
 
         <refsect1>

commit 10efe2cdbe0a5815431217e4b3fd05e5bc65a782
Author: Aleksander Morgado <aleksander at lanedo.com>
Date:   Wed Feb 13 08:50:15 2013 +0100

    test-udev: include missing.h
    
    We need MS_REC and MS_SHARED defined for a proper compilation, so get them from
    'missing.h' if not defined already.

diff --git a/src/test/test-udev.c b/src/test/test-udev.c
index 7cb93ed..aee87f7 100644
--- a/src/test/test-udev.c
+++ b/src/test/test-udev.c
@@ -32,6 +32,7 @@
 #include <sys/mount.h>
 #include <sys/signalfd.h>
 
+#include "missing.h"
 #include "udev.h"
 
 void udev_main_log(struct udev *udev, int priority,

commit 1c00832624a146745c31ce5367330b1d2ca04088
Author: Michael Olbrich <m.olbrich at pengutronix.de>
Date:   Wed Feb 13 08:00:46 2013 +0100

    ratelimit: fix off-by-one
    
    The current code might make sense during startup for service restart
    limiting:
    With burst=1 after starting num is 1, so the next ('first') restart is
    still accepted ( 1 <= 1). However, once interval has expired, num is 1
    after the first restart, so the second restart is also accepted.
    
    This change is also useful in combination with watchdogs:
    With burst=1 and a very large interval the system can be restarted on
    the first failure.

diff --git a/src/shared/ratelimit.c b/src/shared/ratelimit.c
index 1054d52..01b62b7 100644
--- a/src/shared/ratelimit.c
+++ b/src/shared/ratelimit.c
@@ -46,7 +46,7 @@ bool ratelimit_test(RateLimit *r) {
                 goto good;
         }
 
-        if (r->num <= r->burst)
+        if (r->num < r->burst)
                 goto good;
 
         return false;

commit a3aa7ee6ff7b3cc6e473367efd5fecf0f48f9635
Author: Zbigniew Jędrzejewski-Szmek <zbyszek at in.waw.pl>
Date:   Tue Feb 12 23:28:48 2013 -0500

    tests: add test for continuation lines with comments

diff --git a/src/test/test-unit-file.c b/src/test/test-unit-file.c
index 8519131..041daab 100644
--- a/src/test/test-unit-file.c
+++ b/src/test/test-unit-file.c
@@ -193,6 +193,11 @@ static void test_config_parse_exec(void) {
 #define env_file_2 \
         "a\\\n"
 
+#define env_file_3 \
+        "#SPAMD_ARGS=\"-d --socketpath=/var/lib/bulwark/spamd \\\n" \
+        "#--nouser-config                                     \\\n" \
+        "normal=line"
+
 static void test_load_env_file_1(void) {
         char _cleanup_strv_free_ **data = NULL;
         int r;
@@ -230,6 +235,21 @@ static void test_load_env_file_2(void) {
         unlink(name);
 }
 
+static void test_load_env_file_3(void) {
+        char _cleanup_strv_free_ **data = NULL;
+        int r;
+
+        char name[] = "/tmp/test-load-env-file.XXXXXX";
+        int _cleanup_close_ fd = mkstemp(name);
+        assert(fd >= 0);
+        assert_se(write(fd, env_file_3, sizeof(env_file_3)) == sizeof(env_file_3));
+
+        r = load_env_file(name, &data);
+        assert(r == 0);
+        assert(data == NULL);
+        unlink(name);
+}
+
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wnonnull"
 
@@ -305,6 +325,7 @@ int main(int argc, char *argv[]) {
         test_config_parse_exec();
         test_load_env_file_1();
         test_load_env_file_2();
+        test_load_env_file_3();
         test_install_printf();
 
         return 0;



More information about the systemd-commits mailing list