Commit Graph

8052 Commits

Author SHA1 Message Date
Karel Zak 27e6e446b9 lslogins: fix pretty-print columns
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 15:08:26 +02:00
Karel Zak b3f4f05632 lslogins: cleanup some command line options
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 15:05:10 +02:00
Karel Zak 8b13a4d89d lslogins: cleanup default outputs
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 14:48:45 +02:00
Karel Zak ed374569ae lslogins: cleanup -a output
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 14:17:41 +02:00
Karel Zak d4aa0ff138 lslogins: improve COL_PWD_WARN and COL_NPROCS desc
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 13:37:58 +02:00
Karel Zak 74fddd8623 lslogins: cleanup usage()
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 13:32:03 +02:00
Karel Zak f7aea533f4 lslogins: fix nologins check
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 13:24:35 +02:00
Karel Zak ea24eacc6b lslogins: cleanup time formats
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 13:21:57 +02:00
Karel Zak f47c6d3a59 lslogins: clean up password hash check
* rename to PWD-* column names
 * add PWD-DENY for accounts where is no possible to login by password
 * PWD-LOCK (was LOCKED) checks for valid but locked pawwords
 * LOGIN renamed to USER

Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 12:48:40 +02:00
Karel Zak b5f81ce2f5 build-sys: add sys-utils/uname26.8 to gitignore
Reported-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 11:50:44 +02:00
Karel Zak d8b2ddb7bb lslogins: remove --sort-by-name
If we really need a sort functionality hardcoded into lslogins(1) then we need
a generic sort options (like for lsblk,--sort <column>).

Note that it seems that "lslogins | sort --key <col>" is good enough for now as
lslogins(1) does not convert any data to human readable non-precise format (like
for example lsblk SIZE column etc.).

Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 11:46:56 +02:00
Karel Zak 1624245ffe lslogins: improve nologins and shadow usage
* fix coding style
 * don't require shadow entries
 * check for /var/run/nologin

Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 11:30:26 +02:00
Ruediger Meier ae2c3b5bee setarch: add generic support for setarch $(uname -m) ...
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-29 09:52:26 +02:00
Karel Zak 13985252bb build-sys: fix typo, set HAVE_LIBUUID
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-28 10:05:22 +02:00
Karel Zak 9a4e9c9d54 build-sys: enable chfn and chsh by default
The util-linux version (is the best:-) uses libuser,
so it usable for non-local users (LDAP, etc.).

Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-28 09:57:55 +02:00
Karel Zak 705a823a6e Merge branch 'tests-stuff' of https://github.com/rudimeier/util-linux
* 'tests-stuff' of https://github.com/rudimeier/util-linux:
  tests: split off losetup scsi_debug part
  tests: fix, typo schedutils/cpuset
  tests: run tests in deterministic order
  tests: ts_scsi_debug_init skip instead of die
2014-05-28 09:37:41 +02:00
Stanislav Brabec d6ef7d6c69 losetup: don't ignore EBUSY in losetup when the loop device is given
losetup ignores the EBUSY error.  In the loop fo A_CREATE action, it skips
the error handling when errno = EBUSY.  It's OK for the case where no loop
device is specified, but the error has to be handled when the device is given
explicitly.

Author:  Takashi Iwai <tiwai@suse.de>
Signed-off-by: Stanislav Brabec <sbrabec@suse.cz>
2014-05-28 09:18:40 +02:00
Stanislav Brabec f7e2118508 losetup: don't clear FD at EBUSY error in loopcxt_setup_device()
loopback lib clears the existing FD unconditionally at error in
loopcxt_setup_device().  This is done even after EBUSY, thus the second call
actually clears the previous setup wrongly.

Author:  Takashi Iwai <tiwai@suse.de>
Signed-off-by: Stanislav Brabec <sbrabec@suse.cz>
2014-05-28 09:18:28 +02:00
Karel Zak f37b357b47 lslogins: print systemd journal logs
Co-Author: Ondrej Oprala <ooprala@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 17:34:15 +02:00
Karel Zak 1ad36b5264 build_sys: fix default estate usage
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 17:22:28 +02:00
Ondrej Oprala d3a93df80d lslogins: count per-user processes
[kzak@redhat.com: - rename column, align to right]

Signed-off-by: Ondrej Oprala <ooprala@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 17:01:05 +02:00
Karel Zak 127b33b875 Merge branch 'setterm' of git://github.com/kerolasa/lelux-utiliteetit
* 'setterm' of git://github.com/kerolasa/lelux-utiliteetit:
  docs: setterm.1 clean up manual page groff style
  docs: setterm.1 add options compatibility note
  docs: setterm.1 add missing options to manual page and remove duplicate
  setterm: add usage() descriptions
2014-05-27 16:23:46 +02:00
Karel Zak 8c19519930 Merge branch 'uuid' of git://github.com/kerolasa/lelux-utiliteetit 2014-05-27 16:15:30 +02:00
Ruediger Meier 07ac4aa9d4 cal: all output must use my_putstring
Replace all puts, fputs and printf calls by my_putstring() because
we don't want to mix different output channels (buffers).

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-27 16:12:56 +02:00
Petr Uzel ee6369973e sfdisk: suppress Linux-irrelevant warnings with -L
Sfdisk prints out a warning about extended partition not
starting at a cylinder boundary. Since this is irrelevant
for linux, the -L option should suppress this warning.

Signed-off-by: Petr Uzel <petr.uzel@suse.cz>
2014-05-27 16:12:54 +02:00
Karel Zak 70e2ed25f6 docs: update howto regards to build-system changes
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 15:37:26 +02:00
Ruediger Meier 1ef2d4b4bf tests: split off losetup scsi_debug part
It's a pity that we would skip the whole test if scsi_debug is not
available.

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-27 15:36:15 +02:00
Karel Zak d37172b189 docs: remove obsolete cfdisk.txt
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 15:18:35 +02:00
Karel Zak 7477f356cb build-sys: add missing dependencies to libsmartcols
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 14:58:34 +02:00
Karel Zak b248c9d416 build-sys: fix UL_BUILD_INIT()
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 14:58:14 +02:00
Karel Zak f080cc99c8 build-sys: add disable-all.conf to config-gen
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 11:37:18 +02:00
Karel Zak 08b1c21942 build-sys: add --disable-all-programs
This is necessary to build only explicitly specified program/library,
for example to build only libblkid.so

   ./configure --disable-all-programs --enable-libblkid

or to build only hwclock(8):

   ./configure --disable-all-programs --enable-hwclock

Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 11:34:15 +02:00
Karel Zak 50d096acfd build-sys: add UL_DEFAULT_ENABLE() and $ul_default_estate
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-27 11:33:48 +02:00
Ruediger Meier ef60a02e58 tests: fix, typo schedutils/cpuset
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-27 00:55:54 +02:00
Ruediger Meier 667e473524 tests: run tests in deterministic order
Not really needed but it makes debugging of existing build logs
much more easier.

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-27 00:09:49 +02:00
Ruediger Meier f80c0d38b9 tests: ts_scsi_debug_init skip instead of die
If any of these modprobe commands fails then it's not a broken test.
ALso ts_die often does not work correctly from subtests which should
be fixed someday too.

BTW modprobe dry-run (even the real modprobe) is not reliable.
Moreover now we respect blacklisted modules (-b).

This error handling is not only useful to let the test-suite succeed
on broken systems but also to not fail all "scsi_debug tests" after
just one of them failed to umount something.

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-27 00:06:43 +02:00
Sami Kerola d8bb8a033f uuidd: do not mix signed type and unsigned code
Both the strtou32_or_err() and alarm() expect timeout to be unsigned.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:42:49 +01:00
Sami Kerola 6328799db1 uuidgen: use type definitions from uuid.h
There is no need to re-invent wheel.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:42:49 +01:00
Sami Kerola e4faf64847 uuidd: set options to be mutually exclusive
--pid     || --no-pid
--debug   || --quiet
--random  || --time

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:42:40 +01:00
Sami Kerola caac206429 uuidd: ensure pid file is wrote when it is requested
Earlier for example this 'uuidd --pid /dev/full' worked, now error is
printed about truncating not being possible for character device and
assuming someone would write pid to full disk it should not be go by
unnoticed.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:37:54 +01:00
Sami Kerola 8e3bdb3468 docs: setterm.1 clean up manual page groff style
Underline option arguments, and use bold for options.  Avoid use of \f
font style change in paragraphs, but use them when describing options.

Reviewed-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:35:59 +01:00
Sami Kerola f0dcd918eb docs: setterm.1 add options compatibility note
Both --option and -option formats are accepted.

Reviewed-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:35:59 +01:00
Sami Kerola b5700fe506 docs: setterm.1 add missing options to manual page and remove duplicate
Reviewed-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:35:59 +01:00
Sami Kerola 5edc8dbc33 setterm: add usage() descriptions
Reviewed-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2014-05-26 16:35:59 +01:00
Karel Zak 574528ed40 Merge branch 'fix-build-sys' of https://github.com/rudimeier/util-linux 2014-05-26 12:52:18 +02:00
Karel Zak a37811b51f Merge branch 'setarch' of https://github.com/rudimeier/util-linux
* 'setarch' of https://github.com/rudimeier/util-linux:
  setarch: add shortcut binary uname26
  setarch: flush output streams before exec
2014-05-26 12:48:35 +02:00
Karel Zak cb1caee2ae Merge branch 'master' of https://github.com/rudimeier/util-linux 2014-05-26 12:44:31 +02:00
Karel Zak edecf6376f mount: add note about order for -a to the man page
Reported-by: Phillip Susi <psusi@ubuntu.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-26 12:17:48 +02:00
Ruediger Meier 11402f5e0d libblkid: detect squashfs 3 vs 4
Detect squashfs version <= 3 as squashfs3 and version >= 4 as squashfs.

squashfs kernel module version 4.0 (kernel 2.6.29) is not backward
compatible to open squashfs created with previous versions.

Also fixed version number parsing, see
$  mkdir test
$  mksquashfs test test.sqsh
$  blkid -p test.sqsh
- test.sqsh: VERSION="1024.0" TYPE="squashfs" USAGE="filesystem"
+ test.sqsh: VERSION="4.0" TYPE="squashfs" USAGE="filesystem"

This patch comes from openSUSE / SLE. Original author was probably
Miklos Szeredi.
Internal SUSE references: bnc#666893, sr226509

CC: Stanislav Brabec <sbrabec@suse.cz>
CC: Miklos Szeredi <mszeredi@suse.cz>
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-26 12:00:44 +02:00
Karel Zak 4ea79d9690 tests: skip umount-alltargets on regular mtab
Signed-off-by: Karel Zak <kzak@redhat.com>
2014-05-26 11:43:27 +02:00