The -A has been originally used for --activate, since v2.26 it's used
for --append. This is stupid mistake. This patch reverts the change to:
-A, --activate
-a, --append
Note that --append is a new command line option in v2.26.
Addresses: https://bugs.archlinux.org/task/44349
Signed-off-by: Karel Zak <kzak@redhat.com>
Really stupid copy & past mistake. The libfdisk symbols should not be
prefixed by MOUNT_ suffix.
This change makes binaries linked with libfdisk 2.26 incompatible with
new libfdisk. Fortunately, 2.26 has been the first release and very
probably the library has been used for util-linux fdisks only.
Signed-off-by: Karel Zak <kzak@redhat.com>
Both fsck(8) and fsck --help documents progress bar redirection as
-C {fd}
This did not work, and only -C{fd} and "-C {fd}" worked.
Signed-off-by: Karel Zak <kzak@redhat.com>
sys-utils/dmesg.c:650:9: warning: declaration of 's' shadows a previous local [-Wshadow]
sys-utils/dmesg.c:619:12: warning: shadowed declaration is here [-Wshadow]
And since the code had to be touched deprecate loop printing one character
at a time, in favour of printf and instruction to repeat spaces the number
required.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
After "unshare --mount" users assume that mount operations within the
new namespaces are unshared (invisible for the rest of the system).
Unfortunately, this is not true and the behavior depends on the
current mount propagation setting. The kernel default is "private",
but for example systemd based distros use "shared". The solution is to
use (for example) "mount --make-private" after unshare(1).
I have been requested many times to provide less fragile and more
unified unshared mount setting *by default* to make things user
friendly.
The patch forces unshare(1) to explicitly use MS_REC|MS_PRIVATE for all
tree by default.
We can use something less (e.g MS_SLAVE), but "private" is the kernel
default, so for many users this change (feature) will be invisible.
This feature is possible to disable by "--propagation unchanged" or it's
possible to specify another propagation flag, supported are:
<slave|shared|private|unchanged>
Acked-by: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
The new context is copied from --target <PID>. This solution allows to
keep SELinux happy when you enter container by nsenter(1).
Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1116100
Signed-off-by: Karel Zak <kzak@redhat.com>
mount(8) tries to mount read-only when the previous attempt ends with
EROFS or EACCES. This is bad idea for bind mounts as "ro,bind" has
a special semantic.
Signed-off-by: Karel Zak <kzak@redhat.com>
The directory is unnecessary, all we need is to create from "private"
directory a mount point (so "--bind $DIR_PRIVATE $DIR_PRIVATE").
Signed-off-by: Karel Zak <kzak@redhat.com>
The current --target <path> implementation check the <path> elements in
reverse order to get the mountpoint. The feature may be inwanted in
some cases when we really want to check for mountpoint specified by
the <path>. The new option "--mountpoint <path>" allows to be strict.
Signed-off-by: Karel Zak <kzak@redhat.com>
Increased the precision in debug output showing
the clock drift and the time lapsed.
Showing a clock drift of 0.0 while giving a value that the
drift factor was adjusted by makes no sense.
Signed-off-by: J William Piggott <elseifthen@gmx.com>
sector from the /sys/block/.../start file. The file exists only for
partitions, for wholedisk is the start of the device always zero.
References: https://bugzilla.redhat.com/show_bug.cgi?id=1202443
Signed-off-by: Karel Zak <kzak@redhat.com>
warning: extra ';' outside of a function [-Wextra-semi]
warning: embedding a directive within macro arguments has undefined
behavior [-Wembedded-directive]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>