]> git.ipfire.org Git - thirdparty/util-linux.git/log
thirdparty/util-linux.git
3 years agolib/path: fstat dir itself
Karel Zak [Mon, 6 Sep 2021 09:52:09 +0000 (11:52 +0200)] 
lib/path: fstat dir itself

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: revert include/path.h use
Karel Zak [Thu, 2 Sep 2021 14:32:33 +0000 (16:32 +0200)] 
lsfd: revert include/path.h use

We need something better to handle work with processes.

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: add reference to proc from file
Karel Zak [Thu, 2 Sep 2021 12:30:58 +0000 (14:30 +0200)] 
lsfd: add reference to proc from file

* add to file struct reference to process
* add file to the list of the process' files in new_file()

This makes things more straightforward.

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: move list_free() to list.h
Karel Zak [Thu, 2 Sep 2021 12:13:49 +0000 (14:13 +0200)] 
lsfd: move list_free() to list.h

3 years agolsfd: reorder function
Karel Zak [Thu, 2 Sep 2021 12:00:44 +0000 (14:00 +0200)] 
lsfd: reorder function

Keep free_() after new_().

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: remove collect_file()
Karel Zak [Thu, 2 Sep 2021 11:58:49 +0000 (13:58 +0200)] 
lsfd: remove collect_file()

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: cleanup new file initialization
Karel Zak [Wed, 1 Sep 2021 17:10:20 +0000 (19:10 +0200)] 
lsfd: cleanup new file initialization

Don't use new_<class>() functions if we have already have
file_class callbacks.

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: keep main() at the end of the code
Karel Zak [Wed, 1 Sep 2021 16:12:09 +0000 (18:12 +0200)] 
lsfd: keep main() at the end of the code

and usage() before main().

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: use 'new_' prefix when we allocate something
Karel Zak [Wed, 1 Sep 2021 15:50:51 +0000 (17:50 +0200)] 
lsfd: use 'new_' prefix when we allocate something

It's more readable than rather than 'make_'.

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: add --sysroot, use lib/path.c
Karel Zak [Wed, 1 Sep 2021 15:36:29 +0000 (17:36 +0200)] 
lsfd: add --sysroot, use lib/path.c

* use struct path_cxt to read from /procfs

* add --sysroot to redirect lsfd to alternative location (necessary
  for regression tests)

* merge collect_procs() into collect()

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: add --notruncate
Karel Zak [Wed, 1 Sep 2021 14:50:04 +0000 (16:50 +0200)] 
lsfd: add --notruncate

* make COMMAND and NAME truncated by default (to keep output on terminal readable)
* add --notruncate to disable the default behaviour

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: tiny change to default colummns initialization
Karel Zak [Wed, 1 Sep 2021 14:35:42 +0000 (16:35 +0200)] 
lsfd: tiny change to default colummns initialization

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolsfd: unify nodev lists into global one
Masatake YAMATO [Thu, 13 May 2021 20:24:21 +0000 (05:24 +0900)] 
lsfd: unify nodev lists into global one

3 years agolsfd: don't use threads
Masatake YAMATO [Thu, 13 May 2021 19:23:19 +0000 (04:23 +0900)] 
lsfd: don't use threads

3 years agolsfd: fill PROTONAME field of file for mmap'ed socket
Masatake YAMATO [Mon, 10 May 2021 03:56:56 +0000 (12:56 +0900)] 
lsfd: fill PROTONAME field of file for mmap'ed socket

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add MAPLEN column
Masatake YAMATO [Mon, 10 May 2021 03:54:55 +0000 (12:54 +0900)] 
lsfd: add MAPLEN column

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: introduce a data structure for storing common fdinfo data
Masatake YAMATO [Mon, 10 May 2021 02:07:23 +0000 (11:07 +0900)] 
lsfd: introduce a data structure for storing common fdinfo data

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: increase the threads to collect information
Masatake YAMATO [Tue, 4 May 2021 17:50:14 +0000 (02:50 +0900)] 
lsfd: increase the threads to collect information

$ sudo ./lsfd -l | wc -l
75837

[NUM_COLLECTORS 1]
sudo ./lsfd -l > /dev/null  1.16s user 0.62s system 98% cpu 1.805 total
sudo ./lsfd -l > /dev/null  1.12s user 0.50s system 99% cpu 1.630 total
sudo ./lsfd -l > /dev/null  1.14s user 0.49s system 99% cpu 1.642 total

[NUM_COLLECTORS 2]
sudo ./lsfd -l > /dev/null  1.18s user 0.53s system 127% cpu 1.343 total
sudo ./lsfd -l > /dev/null  1.21s user 0.50s system 126% cpu 1.350 total
sudo ./lsfd -l > /dev/null  1.14s user 0.51s system 128% cpu 1.291 total

[NUM_COLLECTORS 3]
sudo ./lsfd -l > /dev/null  1.21s user 0.55s system 138% cpu 1.278 total
sudo ./lsfd -l > /dev/null  1.15s user 0.51s system 139% cpu 1.187 total
sudo ./lsfd -l > /dev/null  1.15s user 0.51s system 140% cpu 1.180 total

[NUM_COLLECTORS 4]
sudo ./lsfd -l > /dev/null  1.23s user 0.66s system 154% cpu 1.218 total
sudo ./lsfd -l > /dev/null  1.22s user 0.54s system 154% cpu 1.137 total
sudo ./lsfd -l > /dev/null  1.14s user 0.64s system 158% cpu 1.123 total

[NUM_COLLECTORS 5]
sudo ./lsfd -l > /dev/null  1.19s user 0.72s system 171% cpu 1.118 total
sudo ./lsfd -l > /dev/null  1.14s user 0.62s system 165% cpu 1.063 total
sudo ./lsfd -l > /dev/null  1.15s user 0.73s system 176% cpu 1.063 total

[NUM_COLLECTORS 6]
sudo ./lsfd -l > /dev/null  1.23s user 0.70s system 173% cpu 1.115 total
sudo ./lsfd -l > /dev/null  1.29s user 0.67s system 169% cpu 1.157 total
sudo ./lsfd -l > /dev/null  1.24s user 0.75s system 185% cpu 1.070 total

[NUM_COLLECTORS 7]
sudo ./lsfd -l > /dev/null  1.32s user 0.74s system 182% cpu 1.130 total
sudo ./lsfd -l > /dev/null  1.25s user 0.82s system 195% cpu 1.058 total
sudo ./lsfd -l > /dev/null  1.22s user 0.74s system 188% cpu 1.041 total

[NUM_COLLECTORS 8]
sudo ./lsfd -l > /dev/null  1.30s user 0.92s system 194% cpu 1.141 total
sudo ./lsfd -l > /dev/null  1.21s user 0.81s system 197% cpu 1.027 total
sudo ./lsfd -l > /dev/null  1.22s user 0.79s system 199% cpu 1.005 total

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: introduce DEVNAME column and use it as default
Masatake YAMATO [Sun, 9 May 2021 03:16:43 +0000 (12:16 +0900)] 
lsfd: introduce DEVNAME column and use it as default

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add a function to get the name of filesystem from a given minor number
Masatake YAMATO [Sun, 9 May 2021 01:41:34 +0000 (10:41 +0900)] 
lsfd: add a function to get the name of filesystem from a given minor number

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add a stub for fifo type
Masatake YAMATO [Sun, 9 May 2021 02:36:07 +0000 (11:36 +0900)] 
lsfd: add a stub for fifo type

3 years agolsfd: add MISCDEV column
Masatake YAMATO [Fri, 7 May 2021 19:47:23 +0000 (04:47 +0900)] 
lsfd: add MISCDEV column

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: read misc character device names from /proc/misc
Masatake YAMATO [Fri, 7 May 2021 19:46:11 +0000 (04:46 +0900)] 
lsfd: read misc character device names from /proc/misc

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add CHRDRV column
Masatake YAMATO [Fri, 7 May 2021 18:51:25 +0000 (03:51 +0900)] 
lsfd: add CHRDRV column

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: read character driver names from /proc/devices
Masatake YAMATO [Fri, 7 May 2021 18:50:16 +0000 (03:50 +0900)] 
lsfd: read character driver names from /proc/devices

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add PARTITION column
Masatake YAMATO [Fri, 7 May 2021 18:28:46 +0000 (03:28 +0900)] 
lsfd: add PARTITION column

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: read /proc/partitions
Masatake YAMATO [Fri, 7 May 2021 18:25:30 +0000 (03:25 +0900)] 
lsfd: read /proc/partitions

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: introduce name_manager
Masatake YAMATO [Fri, 7 May 2021 16:50:20 +0000 (01:50 +0900)] 
lsfd: introduce name_manager

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: replace "socket:" in NAME of SOCKET with its protoname
Masatake YAMATO [Sun, 9 May 2021 01:49:25 +0000 (10:49 +0900)] 
lsfd: replace "socket:" in NAME of SOCKET with its protoname

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add PROTONAME column
Masatake YAMATO [Thu, 6 May 2021 18:57:45 +0000 (03:57 +0900)] 
lsfd: add PROTONAME column

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: allow passing a proc object to the constructors of the file classes
Masatake YAMATO [Thu, 6 May 2021 18:57:03 +0000 (03:57 +0900)] 
lsfd: allow passing a proc object to the constructors of the file classes

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: make username_cache lsfd-file privaite
Masatake YAMATO [Thu, 6 May 2021 15:00:05 +0000 (00:00 +0900)] 
lsfd: make username_cache lsfd-file privaite

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add the way to initialize and finalize classes
Masatake YAMATO [Thu, 6 May 2021 14:51:00 +0000 (23:51 +0900)] 
lsfd: add the way to initialize and finalize classes

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: move file_class variants after their constructors
Masatake YAMATO [Thu, 6 May 2021 14:34:51 +0000 (23:34 +0900)] 
lsfd: move file_class variants after their constructors

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: fill POS and MODE columns for SHM and MEM associated files
Masatake YAMATO [Thu, 6 May 2021 13:26:48 +0000 (22:26 +0900)] 
lsfd: fill POS and MODE columns for SHM and MEM associated files

/proc/$pid/maps files are used as the data sourecs.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: introduce new association SHM representing shared file mapping
Masatake YAMATO [Thu, 6 May 2021 13:19:11 +0000 (22:19 +0900)] 
lsfd: introduce new association SHM representing shared file mapping

MEM is kept for representing private file mapping.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add code for reading /proc/$pid/maps
Masatake YAMATO [Thu, 6 May 2021 13:15:24 +0000 (22:15 +0900)] 
lsfd: add code for reading /proc/$pid/maps

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: introduce fopenf helper function
Masatake YAMATO [Sun, 9 May 2021 17:29:31 +0000 (02:29 +0900)] 
lsfd: introduce fopenf helper function

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add stubs for sockets and files of unknown type
Masatake YAMATO [Thu, 6 May 2021 06:10:49 +0000 (15:10 +0900)] 
lsfd: add stubs for sockets and files of unknown type

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: simplify class hierarchy
Masatake YAMATO [Thu, 6 May 2021 05:54:27 +0000 (14:54 +0900)] 
lsfd: simplify class hierarchy

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: replace POS with MNT_ID in default column set
Masatake YAMATO [Thu, 6 May 2021 05:45:11 +0000 (14:45 +0900)] 
lsfd: replace POS with MNT_ID in default column set

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add MODE column
Masatake YAMATO [Thu, 6 May 2021 05:29:43 +0000 (14:29 +0900)] 
lsfd: add MODE column

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add FLAGS, MNTID, and POS columns
Masatake YAMATO [Thu, 6 May 2021 05:28:58 +0000 (14:28 +0900)] 
lsfd: add FLAGS, MNTID, and POS columns

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add infrstructure code for reading fdinfo files
Masatake YAMATO [Thu, 6 May 2021 05:25:56 +0000 (14:25 +0900)] 
lsfd: add infrstructure code for reading fdinfo files

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: don't collect and print redundant information about threads
Masatake YAMATO [Tue, 4 May 2021 18:37:57 +0000 (03:37 +0900)] 
lsfd: don't collect and print redundant information about threads

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: support threads with -l option
Masatake YAMATO [Tue, 4 May 2021 16:47:49 +0000 (01:47 +0900)] 
lsfd: support threads with -l option

-t and -T are reserved for ffiltering feature.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: print the owner of process as USER
Masatake YAMATO [Tue, 4 May 2021 18:36:09 +0000 (03:36 +0900)] 
lsfd: print the owner of process as USER

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: adjust column width for COMMAND
Masatake YAMATO [Tue, 4 May 2021 17:50:51 +0000 (02:50 +0900)] 
lsfd: adjust column width for COMMAND

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add NLINK and DELETED columns
Masatake YAMATO [Mon, 3 May 2021 07:22:29 +0000 (16:22 +0900)] 
lsfd: add NLINK and DELETED columns

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add columns for SIZE
Masatake YAMATO [Mon, 3 May 2021 06:59:26 +0000 (15:59 +0900)] 
lsfd: add columns for SIZE

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: give column widths
Masatake YAMATO [Mon, 3 May 2021 06:47:02 +0000 (15:47 +0900)] 
lsfd: give column widths

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: specify column more declarative way
Masatake YAMATO [Mon, 3 May 2021 06:45:47 +0000 (15:45 +0900)] 
lsfd: specify column more declarative way

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: declare JSON type in colinfo entries
Masatake YAMATO [Mon, 3 May 2021 06:33:56 +0000 (15:33 +0900)] 
lsfd: declare JSON type in colinfo entries

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add columns for DEV and RDEV
Masatake YAMATO [Sat, 1 May 2021 11:59:51 +0000 (20:59 +0900)] 
lsfd: add columns for DEV and RDEV

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: refactor code calling collect_outofbox_files
Masatake YAMATO [Fri, 16 Apr 2021 22:38:48 +0000 (07:38 +0900)] 
lsfd: refactor code calling collect_outofbox_files

3 years agolsfd: add mem associations
Masatake YAMATO [Fri, 16 Apr 2021 22:33:07 +0000 (07:33 +0900)] 
lsfd: add mem associations

3 years agolsfd: add namespace related associations
Masatake YAMATO [Fri, 16 Apr 2021 22:15:50 +0000 (07:15 +0900)] 
lsfd: add namespace related associations

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: add cwd, exe, and root associations
Masatake YAMATO [Fri, 16 Apr 2021 21:50:00 +0000 (06:50 +0900)] 
lsfd: add cwd, exe, and root associations

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 years agolsfd: purge fd layer
Masatake YAMATO [Fri, 16 Apr 2021 20:49:58 +0000 (05:49 +0900)] 
lsfd: purge fd layer

3 years agolsfd: fill ASSOC field
Masatake YAMATO [Sat, 27 Mar 2021 21:23:24 +0000 (06:23 +0900)] 
lsfd: fill ASSOC field

3 years agolsfd: fill DEVICE field
Masatake YAMATO [Sat, 27 Mar 2021 21:22:50 +0000 (06:22 +0900)] 
lsfd: fill DEVICE field

3 years agolsfd: fill INODE field
Masatake YAMATO [Fri, 26 Mar 2021 08:26:18 +0000 (17:26 +0900)] 
lsfd: fill INODE field

3 years agolsfd: fill USER field
Masatake YAMATO [Fri, 26 Mar 2021 07:55:57 +0000 (16:55 +0900)] 
lsfd: fill USER field

3 years agolsfd: refactor
Masatake YAMATO [Fri, 26 Mar 2021 07:31:31 +0000 (16:31 +0900)] 
lsfd: refactor

3 years agolsfd: fill UID field
Masatake YAMATO [Thu, 25 Mar 2021 17:56:28 +0000 (02:56 +0900)] 
lsfd: fill UID field

3 years agolsfd: fill TYPE field
Masatake YAMATO [Wed, 24 Mar 2021 22:42:15 +0000 (07:42 +0900)] 
lsfd: fill TYPE field

3 years agolsfd: initial commit
Masatake YAMATO [Tue, 23 Mar 2021 18:43:51 +0000 (03:43 +0900)] 
lsfd: initial commit

3 years agomore: fix -e in non-interactive mode
Karel Zak [Tue, 5 Oct 2021 08:53:13 +0000 (10:53 +0200)] 
more: fix -e in non-interactive mode

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agosu: reset also RLIMIT_FSIZE and RLIMIT_NOFILE
Karel Zak [Mon, 4 Oct 2021 13:39:40 +0000 (15:39 +0200)] 
su: reset also RLIMIT_FSIZE and RLIMIT_NOFILE

Addresses: https://github.com/linux-pam/linux-pam/issues/85
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agomount.8.adoc: note that mandatory locking is fully deprecated in Linux 5.15
Jeff Layton [Fri, 1 Oct 2021 12:25:53 +0000 (08:25 -0400)] 
mount.8.adoc: note that mandatory locking is fully deprecated in Linux 5.15

Cc: Jan Kara <jack@suse.cz>
Signed-off-by: Jeff Layton <jlayton@kernel.org>
3 years agofstrim: fix typo
Karel Zak [Mon, 4 Oct 2021 09:14:01 +0000 (11:14 +0200)] 
fstrim: fix typo

Addresses: https://github.com/karelzak/util-linux/issues/1463
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agofstrim: don't trigger autofs
Karel Zak [Mon, 4 Oct 2021 09:14:01 +0000 (11:14 +0200)] 
fstrim: don't trigger autofs

- ignore read-only entries
- ignore autofs entries (for example from /proc/self/mountinfo)
- ignore autofs mountpoints where automounter has not been triggered yet

Fixes: https://github.com/karelzak/util-linux/issues/1463
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agosu: reset RLIMIT_{NICE,RTPRIO} to zero
Karel Zak [Fri, 1 Oct 2021 12:59:50 +0000 (14:59 +0200)] 
su: reset RLIMIT_{NICE,RTPRIO} to zero

Addresses: https://github.com/linux-pam/linux-pam/issues/85
Reported-by: Lennart Poettering <lennart@poettering.net>
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agoprlimit: improve --help output
Karel Zak [Fri, 1 Oct 2021 12:47:04 +0000 (14:47 +0200)] 
prlimit: improve --help output

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agomore: POSIX compliance patch preventing exit on EOF without -e
Ian Jones [Wed, 29 Sep 2021 12:50:14 +0000 (14:50 +0200)] 
more: POSIX compliance patch preventing exit on EOF without -e

[kzak@redhat.com: - merge all patches to one commit,
                  - improve prompt for non-tty stdin]

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agofallocate: add verbose messages
Karel Zak [Mon, 27 Sep 2021 13:40:11 +0000 (15:40 +0200)] 
fallocate: add verbose messages

Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2003927
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agohardlink: use more passive wording in hardlink.1
Eduard Bloch [Mon, 27 Sep 2021 07:08:12 +0000 (09:08 +0200)] 
hardlink: use more passive wording in hardlink.1

And fix "same (basename)".

Signed-off-by: Eduard Bloch <blade@debian.org>
3 years agoLet user choose larger buffers for IO reading
Eduard Bloch [Mon, 27 Sep 2021 07:07:23 +0000 (09:07 +0200)] 
Let user choose larger buffers for IO reading

Simultaneous reading of multiple files through a small one-page buffer
is slow with classic HDDs. Let the user improve it by chosing buffers of
several mebibytes if needed.

[kzak@redhat.com: - tiny changes to coding style
                  - mark buffers static
                  - use xalloc.h]

Signed-off-by: Eduard Bloch <blade@debian.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agosetterm: (man) improve dosc about optional arguments
Karel Zak [Mon, 27 Sep 2021 10:49:01 +0000 (12:49 +0200)] 
setterm: (man) improve dosc about optional arguments

Fixes: https://github.com/karelzak/util-linux/issues/1457
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agomeson: fix typo
Karel Zak [Fri, 24 Sep 2021 13:52:07 +0000 (15:52 +0200)] 
meson: fix typo

Addresses: https://github.com/karelzak/util-linux/issues/1442
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agomeson: make raw(7) optional
Karel Zak [Thu, 23 Sep 2021 12:09:35 +0000 (14:09 +0200)] 
meson: make raw(7) optional

Fixes: https://github.com/karelzak/util-linux/issues/1442
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agotest_mount_optstr: use xstrdup()
Karel Zak [Thu, 23 Sep 2021 11:11:16 +0000 (13:11 +0200)] 
test_mount_optstr: use xstrdup()

Fixes: https://github.com/karelzak/util-linux/issues/1434
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agolib/env: don't ignore failed malloc
Karel Zak [Thu, 23 Sep 2021 11:08:32 +0000 (13:08 +0200)] 
lib/env: don't ignore failed malloc

Fixes: https://github.com/karelzak/util-linux/issues/1434
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agomkswap: support -U {clear,random,time,uuid}
Karel Zak [Thu, 23 Sep 2021 09:53:26 +0000 (11:53 +0200)] 
mkswap: support -U {clear,random,time,uuid}

Let's follow -U from mkfs.ext4 and make it easy to fully control
UUIDs for the swap area.

Fixes: https://github.com/karelzak/util-linux/issues/1453
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agoMerge branch 'int/alex/hifive_uuid' of https://github.com/AlexGhiti/util-linux
Karel Zak [Thu, 23 Sep 2021 09:15:31 +0000 (11:15 +0200)] 
Merge branch 'int/alex/hifive_uuid' of https://github.com/AlexGhiti/util-linux

* 'int/alex/hifive_uuid' of https://github.com/AlexGhiti/util-linux:
  include: Rename HiFive partition UUIDs

3 years agoMerge branch 'master' of https://github.com/mariobl/util-linux
Karel Zak [Thu, 23 Sep 2021 09:12:10 +0000 (11:12 +0200)] 
Merge branch 'master' of https://github.com/mariobl/util-linux

* 'master' of https://github.com/mariobl/util-linux:
  Man pages: Fix end extend formatting

3 years agomount: add hint about dmesg(8) to error messages
Karel Zak [Thu, 23 Sep 2021 09:07:55 +0000 (11:07 +0200)] 
mount: add hint about dmesg(8) to error messages

Fixes: https://github.com/karelzak/util-linux/pull/1444
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agoinclude: Rename HiFive partition UUIDs
Alexandre Ghiti [Wed, 22 Sep 2021 04:38:14 +0000 (06:38 +0200)] 
include: Rename HiFive partition UUIDs

Both HiFive Unleashed and HiFive Unmatched bootloaders seek for the same
UUIDs to load the next stage bootloader: the current name makes partitions
on Unmatched board appear as 'Unleashed'.

Fix that by removing the 'Unleashed' part of the current naming so it
fits both.

Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
3 years agoMan pages: Fix end extend formatting
Mario Blättermann [Tue, 21 Sep 2021 18:48:11 +0000 (20:48 +0200)] 
Man pages: Fix end extend formatting

3 years agomount.8.adoc: fix misformatting
Mario Blättermann [Tue, 21 Sep 2021 08:48:37 +0000 (10:48 +0200)] 
mount.8.adoc: fix misformatting

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agounshare.1.adoc: Improve wording re creation of bind mounts
Michael Kerrisk [Thu, 9 Sep 2021 00:08:28 +0000 (02:08 +0200)] 
unshare.1.adoc: Improve wording re creation of bind mounts

Use consistent wording for the options that create
bind mounts, and improve the wording.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
3 years agounshare.1.adoc: Improve wording re namespace creation
Michael Kerrisk [Thu, 9 Sep 2021 00:08:27 +0000 (02:08 +0200)] 
unshare.1.adoc: Improve wording re namespace creation

The terminonoly "unshare the namespace" is not very helpful.
Instead, use wording that explains what these options actually
fo: "create a new namespace".

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
3 years agogithub: add meson build target
Karel Zak [Thu, 16 Sep 2021 11:25:07 +0000 (13:25 +0200)] 
github: add meson build target

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agoMerge branch 'meson-fixes' of https://github.com/Hello71/util-linux
Karel Zak [Thu, 16 Sep 2021 11:07:05 +0000 (13:07 +0200)] 
Merge branch 'meson-fixes' of https://github.com/Hello71/util-linux

* 'meson-fixes' of https://github.com/Hello71/util-linux:
  meson: make asciidoc optional
  meson: fix building libsmartcols
  meson: fix building logger

3 years agodmesg: translate ctime strings
Karel Zak [Thu, 16 Sep 2021 10:50:01 +0000 (12:50 +0200)] 
dmesg: translate ctime strings

Let's make the date-time strings accessible for translators.

Fixes: https://github.com/karelzak/util-linux/issues/1451
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agologger: fix --prio-prefix doesn't use --priority default
Karel Zak [Thu, 16 Sep 2021 10:20:25 +0000 (12:20 +0200)] 
logger: fix --prio-prefix doesn't use --priority default

The commit b9ef27f have added priority check, but it introduced
regression as the default priority (as specified by --priority) is
ignored.

This patch fixes this problem, but it also removes extra check for
"kern facility", it's unnecessary and inconsistent with the rest of
logger.

Fixes: https://github.com/karelzak/util-linux/issues/1450
Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agologger: dealloc login name
Karel Zak [Thu, 16 Sep 2021 10:15:56 +0000 (12:15 +0200)] 
logger: dealloc login name

Signed-off-by: Karel Zak <kzak@redhat.com>
3 years agoMerge branch 'losetup-direct-dio' of https://github.com/Hello71/util-linux
Karel Zak [Thu, 16 Sep 2021 09:32:57 +0000 (11:32 +0200)] 
Merge branch 'losetup-direct-dio' of https://github.com/Hello71/util-linux

* 'losetup-direct-dio' of https://github.com/Hello71/util-linux:
  losetup: directly set dio instead of afterwards

3 years agoMerge branch 'more-shell-execution' of https://github.com/ritikrajdev/util-linux
Karel Zak [Thu, 16 Sep 2021 09:00:33 +0000 (11:00 +0200)] 
Merge branch 'more-shell-execution' of https://github.com/ritikrajdev/util-linux

* 'more-shell-execution' of https://github.com/ritikrajdev/util-linux:
  more - Bug Resolve - new line separated command execution

3 years agoMerge branch 'refactor-tests' of https://github.com/Ajchler/util-linux
Karel Zak [Thu, 16 Sep 2021 08:51:27 +0000 (10:51 +0200)] 
Merge branch 'refactor-tests' of https://github.com/Ajchler/util-linux

* 'refactor-tests' of https://github.com/Ajchler/util-linux:
  tests: use subtests
  tests: make use of subtests