1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-01 00:51:24 +03:00
Commit Graph

20171 Commits

Author SHA1 Message Date
Lennart Poettering
2ab2ab7b19 service: timeout on SIGABRT should also be considered an error to remember 2015-04-21 02:20:15 +02:00
Lennart Poettering
a00973af27 service: make more use of IN_SET() macro 2015-04-21 02:19:58 +02:00
Lennart Poettering
57614eb1a3 service: list states always in the same order 2015-04-21 02:18:31 +02:00
Lennart Poettering
4940c0b0b6 service: make kill operation mapping explicit 2015-04-21 02:17:01 +02:00
Lennart Poettering
98b3255670 networkd: fix confusion between log_netdev_error() but log_warning_netdev()
We should always name the object first, the level second, like
everywhere else in the sources.
2015-04-21 01:26:59 +02:00
Lennart Poettering
aa5f6817bc tmpfiles: consider an argument of "-" as non-specified 2015-04-21 01:10:19 +02:00
Lennart Poettering
0f51442056 sd-bus: when augmenting creds, remember which ones were augmented
Also, when we do permissions checks using creds, verify that we don't do
so based on augmented creds, as extra safety check.
2015-04-21 00:58:56 +02:00
Lennart Poettering
822d9b6e4c sd-bus: augmenting cgroups-based creds when we have the cgroup path already is free 2015-04-21 00:58:56 +02:00
Lennart Poettering
f887fa73ee sd-bus: when augmenting creds, don't override any creds in any case
Let's better be safe than sorry.
2015-04-21 00:58:56 +02:00
Lennart Poettering
da634f97eb sd-bus: when copying creds objects, make sure we copy even the implicit well known names 2015-04-21 00:58:56 +02:00
Lennart Poettering
62e3d1aed5 dhcp6: remove unnecessary if check 2015-04-21 00:58:56 +02:00
Lennart Poettering
17978b17d9 update TODO 2015-04-21 00:58:56 +02:00
Lennart Poettering
ba780c116f CODING_STYLE: document how destructors should work 2015-04-21 00:58:56 +02:00
Susant Sahani
81bd37a85f networkd: Add support for bond option.
This patch adds configurational support for bond option.

Test conf:

bond.netdev

 ---
[NetDev]
Name=bond1
Kind=bond

[Bond]
ArpAllTargets=all
PrimaryReselect=better
ArpIntervalSec=10s
ArpIpTargets= 192.168.8.102 192.168.8.101 192.168.8.102
 ---

$cat /proc/net/bonding/bond1
Ethernet Channel Bonding Driver: v3.7.1 (April 27, 2011)

Bonding Mode: load balancing (round-robin)
MII Status: up
MII Polling Interval (ms): 0
Up Delay (ms): 0
Down Delay (ms): 0
ARP Polling Interval (ms): 10000
ARP IP target/s (n.n.n.n form): 192.168.8.100, 192.168.8.101, 192.168.8.102
2015-04-20 20:14:34 +02:00
Susant Sahani
cffacc741c networkd vxlan: Add support for enabling UDP checksums
Add UDPCheckSum option to enable transmitting UDP checksums when doing
VXLAN/IPv4. Add UDP6ZeroChecksumRx, and UDP6ZeroChecksumTx
options to enable sending zero checksums and receiving zero
checksums in VXLAN/IPv6

[tomegun: rebase manpage due to whitespace changes]
2015-04-20 20:09:32 +02:00
Nir Soffer
bf23b9f86f udev: settle should return immediately when timeout is 0
udevadm manual says:

    A value of 0 will check if the queue is empty and always return
    immediately.

However, currently we ignore the deadline if the value is 0, and wait
without any limit.

Zero timeout behaved according to the documentation until commit
ead7c62ab7 (udevadm: settle - kill alarm()). Looking at this patch, it
seems that the behavior change was unintended.

This patch restores the documented behavior.
2015-04-20 18:48:55 +02:00
Raul Gutierrez S
30a5b7820c util: fix typo 2015-04-20 08:54:01 +02:00
Martin Pitt
9f8f87e375 exit-status: Fix "NOTINSSTALLED" typo 2015-04-18 22:38:13 +01:00
Martin Pitt
4eac277367 cryptsetup: Implement offset and skip options
These are useful for plain devices as they don't have any metadata by
themselves. Instead of using an unreliable hardcoded device name in crypttab
you can then put static metadata at the start of the partition for a stable
UUID or label.

https://bugs.freedesktop.org/show_bug.cgi?id=87717
https://bugs.debian.org/751707
https://launchpad.net/bugs/953875
2015-04-17 10:53:01 -05:00
David Herrmann
18ae3d98d9 sd-device: simplify enumerator hacks
Boolean arithmetic is great, use it!

    if (a && !b)
      return 1;
    if (!a && b)
      return -1,

is equivalent to

    if (a != b)
      return a - b;

Furthermore:

    r = false;
    if (condition)
        r = true;

is equivalent to:

    r = condition;
2015-04-17 15:22:13 +02:00
Tom Gundersen
08232a020b sd-device: uniformly handle missing devices
sd_device_new_from_* now returns -ENODEV when the device does not exist, and the enumerator
silently drops these errors as missing devices is exepected.
2015-04-17 14:55:40 +02:00
Tom Gundersen
dee5e0b6c2 sd-device: enumerator - match only on initialized devices by default
It is still possible to include uninitialized ones, but now that is opt-in. In most
cases people only want initialized devices. Exception is if you want to work without
udev running.

Suggested by David Herrmann.
2015-04-17 14:16:16 +02:00
Tom Gundersen
19c9df4492 sd-device: enumerator - don't expose add_device()
This is rarely, if ever, used. Drop it from the new public API and only keep it for
the legacy API.

Suggested by David Herrmann.
2015-04-17 14:15:47 +02:00
Tom Gundersen
c32eb440ba libudev: make libudev-enumerate a thin wrapper around sd-device 2015-04-16 16:47:23 +01:00
Tom Gundersen
96df036fe3 sd-device: add device-enumerator library 2015-04-16 16:47:23 +01:00
Tom Gundersen
aa02962840 shared: move assert_return_errno() from libudev
This should not be used for any new code, as we don't set errno in new code,
but there are several legacy users, so let's keep it in shared.
2015-04-16 16:47:23 +01:00
Lennart Poettering
2d0c156134 sd-bus: add more comments to the credential decision logic 2015-04-16 17:28:15 +02:00
Zbigniew Jędrzejewski-Szmek
0f90839754 core: fix spurious warning about cpuacct-usage-base deserialization
The key was parsed properly, but the warning was still generated.
2015-04-16 08:12:02 -04:00
Zbigniew Jędrzejewski-Szmek
38b9855bfa udev-builtin-usb_id: fix inverted condition
Fix for 4beac74e69.

Thanks, Ronny!
2015-04-15 08:28:19 -04:00
Zbigniew Jędrzejewski-Szmek
17af49f248 selinux: use different log priorites for log messages
When selinux calls our callback with a log message, it specifies the
type as AVC or INFO/WARNING/ERROR. The question is how to map this to
audit types and/or log priorities. SELINUX_AVC maps to AUDIT_USER_AVC
reasonably, but for the other messages we have no idea, hence we use
AUDIT_USER_AVC for everything. When not using audit logging, we can
map those selinux levels to LOG_INFO/WARNING/ERROR etc.

Also update comment which was not valid anymore in light of journald
sucking in audit logs, and was actually wrong from the beginning —
libselinux uses the callback for everything, not just avcs.

This stemmed out of https://bugzilla.redhat.com/show_bug.cgi?id=1195330,
but does not solve it.
2015-04-14 21:47:20 -04:00
Zbigniew Jędrzejewski-Szmek
40acc203c0 systemctl: avoid bumping NOFILE rlimit unless needed
We actually only use the journal when showing status. Move setrlimit call
so it is only called for status.

https://bugzilla.redhat.com/show_bug.cgi?id=1184712
2015-04-14 21:47:20 -04:00
Zbigniew Jędrzejewski-Szmek
813a71a206 sd-device: fix typo 2015-04-14 20:16:02 -04:00
Zbigniew Jędrzejewski-Szmek
4beac74e69 udev-builtin-usb_id: simplification 2015-04-14 12:39:14 -04:00
Thomas Hindoe Paaboel Andersen
70c79983e1 test-dhcp6-client: don't unref the event twice 2015-04-14 18:33:31 +02:00
Thomas Hindoe Paaboel Andersen
8283c71b71 sd-dhcp6-client: unref lease when freeing the client 2015-04-14 18:32:58 +02:00
Tom Gundersen
5a917c064b sd-devcie: fix typo 2015-04-14 16:55:18 +02:00
Tom Gundersen
85091685af sd-device: fix reading of subsystem 2015-04-14 16:19:37 +02:00
Tom Gundersen
bba061662b sd-device: allow uevent files to be write-only 2015-04-14 16:19:37 +02:00
Lennart Poettering
8d8ce9e2cd udev: downgrade a few warnings to debug messages
https://bugs.freedesktop.org/show_bug.cgi?id=89885
2015-04-14 15:53:33 +02:00
Hans de Goede
37186823f3 input_id: Identify scroll-wheel device on Trust TB7300 tablet as keyboard
The Trust TB7300 (relabelled Waltop?) tablet has a scrollwheel which shows
up as a /dev/input/event# node all by itself. Currently input_id does not
set any ID_INPUT_FOO attr on this causing it it to not be recognized by
Xorg / libinput.

This commit fixes this by marking it with ID_INPUT_KEY.

Reported-by: Sjoerd Timmer <themba@randomdata.nl>
2015-04-14 09:51:41 +10:00
Hans de Goede
941a2aca3d udev: input_id: Make test_pointer / test_keys return if they've found anything
Make test_pointer / test_keys return a boolean indicating whether or not
they've set any properties on the device.
2015-04-14 09:51:07 +10:00
Peter Hutterer
b914418a15 udev: input_id: whitespace fixes
Remove whitespaces before opening parentheses, mostly before test_bit.
2015-04-14 09:40:19 +10:00
Thomas Hindoe Paaboel Andersen
a64edefacb test-ipv4ll: clean up the event
shuts up valgrind/sanitizers
2015-04-13 23:38:02 +02:00
Goffredo Baroncelli
3a92e4ba47 tmpfiles: Add +C attrib to the journal files directories
Add the +C file attribute (NOCOW) to the journal directories, so that
the flag is inherited automatically for new journal files created in
them. The journal write pattern is problematic on btrfs file systems as
it results in badly fragmented files when copy-on-write (COW) is used:
the performances decreases substantially over time.

To avoid this issue, this tmpfile.d snippet sets the NOCOW attribute to
the journal files directories, so newly created journal files inherit
the NCOOW attribute that disables copy-on-write.

Be aware that the NOCOW file attribute also disables btrfs checksumming
for these files, and thus prevents btrfs from rebuilding corrupted files
on a RAID filesystem.

In a single disk filesystems (or filesystems without redundancy) it is
safe to use the NOCOW flags without drawbacks, since the journal files
contain their own checksumming.
2015-04-13 16:37:52 +02:00
Lennart Poettering
48e6d6a6e9 update TODO 2015-04-13 15:23:53 +02:00
Lennart Poettering
1ae705fb3d man: slightly fewer paragraphs can help readability 2015-04-13 15:23:53 +02:00
Lennart Poettering
bd1100898d man: fix examples indentation in tmpfiles.d(5) 2015-04-13 15:23:52 +02:00
Lennart Poettering
0ac0b1e720 man: add information about more lines to explanation of argument field 2015-04-13 15:23:52 +02:00
Lennart Poettering
6a9171d2ec man: document which tmpfiles line types follow symlinks
Generally, we will not follow symlinks, except for "w".

Avoid documentation for now for fifo, device node, directory lines,
which currently follow symlinks but better shouldn't.
2015-04-13 15:23:52 +02:00
Lennart Poettering
48b8aaa827 tmpfiles: don't follow symlinks when adjusting ACLs, fille attributes, access modes or ownership 2015-04-13 15:23:52 +02:00