summaryrefslogtreecommitdiffstats
path: root/misc-utils
Commit message (Collapse)AuthorAgeFilesLines
...
| * hardlink: fix compiler warningsRuediger Meier2018-11-141-12/+11Star
| | | | | | | | Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
| * hardlink: style indentations and license headerRuediger Meier2018-11-121-356/+413
| | | | | | | | Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
| * hardlink: enable build with and without pcre2Ruediger Meier2018-11-122-2/+29
| | | | | | | | Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
| * Merge branch 'hardlink-import' into hardlinkRuediger Meier2018-06-122-0/+494
| |\ | | | | | | | | | | | | | | | Import hardlink source and manpage version 1.3 from https://pagure.io/hardlink.git revision 24da8615f7a9c67648bfe9b6709ba7786d61b89a
| | * fixes for the fixesKevin Fenzi2018-06-121-1/+1
| | | | | | | | | | | | Signed-off-by: Francisco Javier Tsao Santín <tsao@gpul.org>
| | * temporal fix before re-patch (updates from Fedora repo)Francisco Javier Tsao Santín2018-06-121-1/+1
| | |
| | * Update hardlink.1utoddl2018-06-121-1/+1
| | | | | | | | | The example regex in the BUGS section needs its backslashes backslashed.
| | * Fixed version number, added changelog about Todd Lewis' patchFrancisco Javier Tsao Santín2018-06-121-0/+1
| | |
| | * exclude files via pcreTodd Lewis2018-06-122-10/+57
| | |
| | * Fixed 32 bit build with gcc7 (RH Bugzilla ID 1422989)Francisco Javier Tsao Santín2018-06-121-4/+4
| | |
| | * spec file reflects the atomic hardlinking patch; removed cleaning buildroot ↵Francisco Javier Tsao Santín2018-06-121-4/+4
| | | | | | | | | | | | (redundant); update FSF address at .c source file
| | * Revert "spec file reflects the atomic hardlinking patch; removed cleaning ↵Francisco Javier Tsao Santín2018-06-121-12/+15
| | | | | | | | | | | | | | | | | | buildroot (redundant); current FSF address at .c source file" This reverts commit bb9e76ae339794c2243ae294207942b7ea278364.
| | * spec file reflects the atomic hardlinking patch; removed cleaning buildroot ↵Francisco Javier Tsao Santín2018-06-121-4/+3Star
| | | | | | | | | | | | (redundant); current FSF address at .c source file
| | * Mention -f option in the man pageJan Zeleny2018-06-121-0/+2
| | |
| | * do not allow to hardlink files across filesystems by default (#786719)Jindrich Novy2018-06-121-4/+16
| | | | | | | | | | | | (use -f option to override)
| | * fix possible buffer overflows, integer overflows, update man pageJindrich Novy2018-06-122-43/+95
| | |
| | * fix URL and remove mmap() (#676962, #672917)Jindrich Novy2018-06-121-33/+19Star
| | |
| | * - update docs to describe highest verbosity -vv option (#210816)Jindrich Novy2018-06-122-3/+6
| | | | | | | | | | | | - use dist Resolves: 210816
| | * mostly spec cleanupJindrich Novy2018-06-121-1/+2
| | |
| | * add -h optionJindrich Novy2018-06-122-3/+44
| | |
| | * Document hardlink command line options. (Ville Skytta) (#161738)Dave Jones2018-06-121-0/+3
| | |
| | * - don't try to hardlink 0 byte files (#154404)Jeremy Katz2018-06-121-2/+2
| | |
| | * kill warningDave Jones2018-06-121-1/+1
| | |
| | * auto-import hardlink-1.0-1.1 on branch devel from hardlink-1.0-1.1.src.rpmDave Jones2018-06-121-0/+344
| |
* | cal: use standout mode on monochrome terminalsKarel Zak2019-02-041-3/+15
| | | | | | | | | | | | | | | | | | The function colors_init() checks for colors, it means it fails on monochrome terminals, but cal(1) in this case still need to highlight the current day. Reported-by: Nuno Silva <nunojsilva@ist.utl.pt> Signed-off-by: Karel Zak <kzak@redhat.com>
* | logger: (man) add info about rewrite and authorsKarel Zak2019-01-291-0/+16
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | logger: (man) make more obvious that --server/socket is requiredKarel Zak2019-01-291-0/+4
| | | | | | | | | | | | The options --tcp/udp specify only how, but no where. Signed-off-by: Karel Zak <kzak@redhat.com>
* | logger: concatenate multiple lines of MESSAGE into a single field.Karel Zak2019-01-232-2/+26
| | | | | | | | | | | | | | | | | | | | | | | | this is deemed a useful special case since journalctl will only show either the first or last element of the message array if the field appears multiple times. Based on patch from: Kjetil Torgrim Homme <kjetil.homme@redpill-linpro.com> https://github.com/karelzak/util-linux/pull/743 Addresses: https://github.com/karelzak/util-linux/issues/742 Signed-off-by: Karel Zak <kzak@redhat.com>
* | whereis: search in /(s)bin before /usr/libKarel Zak2019-01-171-2/+2
| | | | | | | | | | Addresses: https://github.com/karelzak/util-linux/issues/741 Signed-off-by: Karel Zak <kzak@redhat.com>
* | libblkid: improve whole-disk detection when read /proc/partitionsKarel Zak2019-01-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | blkid(8) in high-level mode checks partitions and unpartitioned whole-disk devices from the file /proc/partitions. The current heuristic assumes that partition name ends with a digit. Unfortunately, this is not correct -- for example md0 or nvme0n1 are whole-disk devices. This commit uses sysfs_devno_is_wholedisk() to make sure the device is a partition (according to kernel or DM). It's probably more expensive, because this way requires more syscalls (to read stuff from /sys etc.). The patch also adds more information to the blkid(8) man page. Addresses: https://github.com/karelzak/util-linux/issues/728 Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: fix null pointer dereferencesSami Kerola2018-12-102-3/+4
| | | | | | | | | | | | Both catched with -Wnull-dereference compiler option: Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* | lsblk: add --mergeKarel Zak2018-12-074-31/+112
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: make devtree dependences more genericKarel Zak2018-12-072-29/+68
| | | | | | | | | | | | | | We also need reference from child to parent to implement multi-parent view. This change allows to walk on tree in both directions. Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: add --dedup <column>Karel Zak2018-12-074-11/+192
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The target use-case are systems with large number of multi-path devices or systems with duplicate (copied) filesystems. The feature is flexible enough to use arbitrary column (for example WWM or UUID, ...) as de-duplication key. For example tree with multi-path devices sd{c,d,e,f} ./lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 223.6G 0 disk ├─sda1 8:1 0 200M 0 part /boot/efi ├─sda2 8:2 0 200M 0 part /boot ├─sda3 8:3 0 130.3G 0 part ├─sda4 8:4 0 50G 0 part / └─sda5 8:5 0 42.9G 0 part sdb 8:16 0 74.5G 0 disk └─sdb1 8:17 0 74.5G 0 part /home/archive sdc 8:32 0 100M 0 disk └─mpatha 253:0 0 100M 0 mpath ├─mpatha1 253:1 0 50M 0 part └─mpatha2 253:2 0 49M 0 part sdd 8:48 0 100M 0 disk └─mpatha 253:0 0 100M 0 mpath ├─mpatha1 253:1 0 50M 0 part └─mpatha2 253:2 0 49M 0 part sde 8:64 0 100M 0 disk └─mpatha 253:0 0 100M 0 mpath ├─mpatha1 253:1 0 50M 0 part └─mpatha2 253:2 0 49M 0 part sdf 8:80 0 100M 0 disk └─mpatha 253:0 0 100M 0 mpath ├─mpatha1 253:1 0 50M 0 part └─mpatha2 253:2 0 49M 0 part De-duplicate by WWN: ./lsblk -M WWN NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 223.6G 0 disk ├─sda1 8:1 0 200M 0 part /boot/efi ├─sda2 8:2 0 200M 0 part /boot ├─sda3 8:3 0 130.3G 0 part ├─sda4 8:4 0 50G 0 part / └─sda5 8:5 0 42.9G 0 part sdb 8:16 0 74.5G 0 disk └─sdb1 8:17 0 74.5G 0 part /home/archive sdc 8:32 0 100M 0 disk └─mpatha 253:0 0 100M 0 mpath ├─mpatha1 253:1 0 50M 0 part └─mpatha2 253:2 0 49M 0 part Addresses: https://github.com/karelzak/util-linux/issues/616 Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: remember whole-disk, remove unused struct memberKarel Zak2018-12-073-14/+18
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: make device_get_data() more genericKarel Zak2018-12-072-58/+78
| | | | | | | | | | | | | | * independent on smartcols line * keep sort data optional Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: apply --nodeps to partitions tooKarel Zak2018-12-071-3/+3
| | | | | | | | | | | | | | The new implementation differentiates between partitions and another dependences -- this is regression, we need root devices only. Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: read queue/discard_granularity only when necessaryKarel Zak2018-12-073-13/+20
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: reuse 'removable' flag from parentKarel Zak2018-12-073-6/+31
| | | | | | | | | | | | | | It's used in the default output, let's make it a little bit more effective. Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: don't keep sysfs dirs openKarel Zak2018-12-071-16/+46
| | | | | | | | | | | | | | Don't keep open sysfs file descriptors for all time to avoid problems on systems with huge number of block devices. Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: rename set_device()Karel Zak2018-12-071-6/+6
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: add commentsKarel Zak2018-12-071-12/+46
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: add process_all_devices_inverse()Karel Zak2018-12-071-35/+90
| | | | | | | | | | | | | | | | | | | | | | This is necessary to implement --inverse. Note that this new implementation scans /sys/dev/block/ to get top-level devices and than it calls process_one_device(). Note that standard non-inverse tree does not use process_one_device() as it's more effective to scan /sys/block where are no partitions. Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: reorder functionsKarel Zak2018-12-071-56/+57
| | | | | | | | | | | | | | The goal is to call process_one_device() from process_all_devices(), so let's it keep in code in the right order. Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: make process_partitions() more readableKarel Zak2018-12-071-11/+11
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: remove unncessary parent pointerKarel Zak2018-12-072-33/+18Star
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: use real rather than hardcoded parentKarel Zak2018-12-071-4/+9
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: use devtree functionsKarel Zak2018-12-071-92/+104
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: add lsblk_device_has_dependence()Karel Zak2018-12-072-11/+29
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* | lsblk: process_one_device() refactoringKarel Zak2018-12-071-11/+24
| | | | | | | | Signed-off-by: Karel Zak <kzak@redhat.com>