summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-02-03tty-ask-password: Split out password sendingJan Alexander Steffens (heftig)
This is a piece of refactoring I've done while looking for a solution to bug #2378. It separates the password sending from `parse_password`, which only needs to know about the socket path and the list of passwords to send. As a caveat, the `ask_password_tty` path needs to construct a one-password strv, too.
2016-02-03Merge pull request #2509 from bengal/dhcp-nak-delay-v4Tom Gundersen
dhcp: delay restarts after NAKs (v4)
2016-02-03Merge pull request #2508 from fishilico/selinux-logindLennart Poettering
Load SELinux labelling systemd in systemd-logind
2016-02-03Merge pull request #2512 from 0xAX/mount-setupLennart Poettering
mount-setup: introduce mount_points_setup
2016-02-03Merge pull request #2522 from 0xAX/check-early-mountLennart Poettering
manager: print fatal error if early mount failed
2016-02-03Merge pull request #2519 from msekletar/journalctl-device-log-current-boot-v2Lennart Poettering
journalctl: add match for the current boot when called with devpath (v2)
2016-02-03Merge pull request #2453 from poettering/journalctl-fTom Gundersen
journalctl --fields logic
2016-02-03man: clarify what happens when journalctl is called with devpathMichal Sekletar
2016-02-03journalctl: add match for the current boot when called with devpathMichal Sekletar
2016-02-03Merge pull request #2507 from evverx/fix-q-on-tmpfsLennart Poettering
tmpfiles: don't skip path_set_perms on error
2016-02-03Merge pull request #2518 from msekletar/udev-manpage-fixLennart Poettering
man: document that udev_device_new_* functions set errno on error
2016-02-03man: document that udev_device_new_* functions set errno on errorMichal Sekletar
2016-02-03manager: print fatal error if early mount failedAlexander Kuleshov
The mount_setup_early() can fail and if it will occur, there is no sense to make selinux setup and etc.
2016-02-02logind: load SELinux labelling systemNicolas Iooss
systemd-logind uses mkdir_label and label_fix functions without calling first mac_selinux_init. This makes /run/user/$UID/ directories not labelled correctly on an Arch Linux system using SELinux. Fix this by calling mac_selinux_init("/run") early in systemd-logind. This makes files created in /etc/udev/rules.d and /var/lib/systemd to be labelled through transitions in the SELinux policy instead of using setfscreatecon (with mac_selinux_create_file_prepare).
2016-02-03mount-setup: introduce mount_points_setupAlexander Kuleshov
The mount_setup_early() and mount_setup() contain almost the same pieces of code which calls mount_one() for a certain mount point from the mount_table. This patch introduces mount_points_setup() helper to prevent code duplication.
2016-02-02Merge pull request #2510 from msekletar/journalctl-dev-sda-v4Lennart Poettering
journalctl: make "journalctl /dev/sda" work
2016-02-02Merge pull request #2511 from nnz1024/update_russian_translationLennart Poettering
Update russian translation
2016-02-02catalog: updated Russian translationnnz1024
2016-02-02po: updated Russian translationnnz1024
2016-02-02Merge pull request #2506 from poettering/resolved-and-moreDaniel Mack
pid 1 fixes, resolved fixes, and more
2016-02-02journalctl: make "journalctl /dev/sda" workMichal Sekletar
Currently when journalctl is called with path to block device node we add following match _KERNEL_DEVICE=b$MAJOR:$MINOR. That is not sufficient to actually obtain logs about the disk because dev_printk() kernel helper puts to /dev/kmsg information about the device in following format, +$SUBSYSTEM:$ADDRESS, e.g. "+pci:pci:0000:00:14.0". Now we will walk upward the syspath and add match for every device in format produced by dev_printk() as well as match for its device node if it exists.
2016-02-02dhcp: delay restarts after NAKsBeniamino Galvani
The server might answer to a DHCPREQUEST with a NAK and currently the client restarts the configuration process immediately. It was observed that this can easily generate loops in which the network is flooded with DISCOVER,OFFER,REQUEST,NAK sequences. RFC 2131 only states that "if the client receives a DHCPNAK message, the client restarts the configuration process" without further details. Add a delay with exponential backoff between retries after NAKs to limit the number of requests and cap the delay to 30 minutes.
2016-02-01sd-journal: properly export has_{persistent|runtime}_files()Lennart Poettering
This was missing in 39fd5b08a73f144a20202a665bd25cad51d8a90b.
2016-02-01sd-journal: minor optimizationLennart Poettering
No need to store the object and offset data if we don't actually need it ever.
2016-02-01journalctl: add new --fields switch to dump all currently used field namesLennart Poettering
Fixes #2176
2016-02-01sd-journal: add an API to enumerate known field names of the journalLennart Poettering
This adds two new calls to get the list of all journal fields names currently in use. This is the low-level support to implement the feature requested in #2176 in a more optimized way.
2016-02-01man: document the new RuntimeMaxSec= settingLennart Poettering
2016-02-01sd-netlink: since whe acquire the netlink socket's sockaddr anyway, let's ↵Lennart Poettering
actually verify it
2016-02-01sd-netlink: don't take possesion of netlink fd from caller on failureLennart Poettering
Fixes: #2338
2016-02-01core: no need to use unlink_noerrno()Lennart Poettering
2016-02-01core: rework unit timeout handling, and add new setting RuntimeMaxSec=Lennart Poettering
This clean-ups timeout handling in PID 1. Specifically, instead of storing 0 in internal timeout variables as indication for a disabled timeout, use USEC_INFINITY which is in-line with how we do this in the rest of our code (following the logic that 0 means "no", and USEC_INFINITY means "never"). This also replace all usec_t additions with invocations to usec_add(), so that USEC_INFINITY is properly propagated, and sd-event considers it has indication for turning off the event source. This also alters the deserialization of the units to restart timeouts from the time they were originally started from. Before this patch timeouts would be restarted beginning with the time of the deserialization, which could lead to artificially prolonged timeouts if a daemon reload took place. Finally, a new RuntimeMaxSec= setting is introduced for service units, that specifies a maximum runtime after which a specific service is forcibly terminated. This is useful to put time limits on time-intensive processing jobs. This also simplifies the various xyz_spawn() calls of the various types in that explicit distruction of the timers is removed, as that is done anyway by the state change handlers, and a state change is always done when the xyz_spawn() calls fail. Fixes: #2249
2016-02-01update TODOLennart Poettering
2016-02-01core: fix support for transient resource limit propertiesLennart Poettering
Make sure we can properly process resource limit properties. Specifically, allow transient configuration of both the soft and hard limit, the same way from the unit files. Previously, only the the hard rlimits could be configured but they'd implicitly spill into the soft hard rlimits. This also updates the client-side code to be able to parse hard/soft resource limit specifications. Since we need to serialize two properties in bus_append_unit_property_assignment() now, the marshalling of the container around it is now moved into the function itself. This has the benefit of shortening the calling code. As a side effect this now beefs up the rlimit parser of "systemctl set-property" to understand time and disk sizes where that's appropriate.
2016-02-01resolve: work around clang limitationLennart Poettering
clang is apparently not smart enough to detect when a switch statement contains case statements for all possible values of the used type. Work around that. (And while we are at it, normalize indentation a bit) Fixes: #2504
2016-02-01shared: simplify parsing of bus properties a bitLennart Poettering
Let's write the property name and value in one call, when that's possible, shorthing our code a bit.
2016-02-01core: when saving timer unit time values, store them in raw µsLennart Poettering
Let's simplify things a bit, and make sure we don't lose accuracy.
2016-02-01core: fix handling of AccuracyUSec and RandomDelayUSec bus propertiesLennart Poettering
Clear up some confusion regarding the USec and Sec suffixes we use. In configuration files we usually use the Sec suffix, to indicate the implied time unit if none is specified. The respective bus properties however use the USec property, since they expose 64bit unsigned integers containing time in µs. Before this patch timer units exposed a bus property AccuracyUSec (which hence is the correct name) but when parsing transient property data would look for AccuracySec instead (which is incorrect). This patch ensures we look for AccuracySec correctly, but keeps the code for AccuracyUSec in place for compatibility, but adds a warning to ensure that apps are updated to use the right property.
2016-02-01basic: add new rlimit_format() callLennart Poettering
This formats a struct rlimit the way rlimit_parse() expects it.
2016-02-01gpt-auto: don't log an EIO error if blkid finds something which is not a ↵Lennart Poettering
partition table Fixes: #2483
2016-02-01core: move parsing of rlimits into rlimit-util.[ch]Lennart Poettering
This way we can reuse it for parsing rlimit settings in "systemctl set-property" and related commands.
2016-02-01core: store for each unit when the last low-level unit state change took placeLennart Poettering
This adds a new timestamp field to the Unit struct, storing when the last low-level state change took place, and make sure this is restored after a daemon reload. This new field is useful to allow restarting of per-state timers exactly where they originally started.
2016-02-01sd-event: permit a USEC_INFINITY timeout as an alternative to a disabling an ↵Lennart Poettering
event source This should simplify handling of time events in clients and is in-line with the USEC_INFINITY macro we already have. This way setting a timeout to 0 indicates "elapse immediately", and a timeout of USEC_INFINITY "elapse never".
2016-02-01sd-event: when determining the last allowed time a time event may elapse, ↵Lennart Poettering
deal with overflows
2016-02-01util: add usec_add() which adds two usec_t values with overflow handlingLennart Poettering
2016-02-01resolved: rework what ResolveHostname() with family == AF_UNSPEC meansLennart Poettering
Previously, if a hostanem is resolved with AF_UNSPEC specified, this would be used as indication to resolve both an AF_INET and an AF_INET6 address. With this change this logic is altered: an AF_INET address is only resolved if there's actually a routable IPv4 address on the specific interface, and similar an AF_INET6 address is only resolved if there's a routable IPv6 address. With this in place, it's ensured that the returned data is actually connectable by applications. This logic mimics glibc's resolver behaviour. Note that if the client asks explicitly for AF_INET or AF_INET6 it will get what it asked for. This also simplifies the logic how it is determined whether a specific lookup shall take place on a scope. Specifically, the checks with dns_scope_good_key() are now moved out of the transaction code and into the query code, so that we don't even create a transaction object on a specific scope if we cannot execute the resolution on it anyway.
2016-02-01journal-cat: don't allocate memory for the syslog identifierLennart Poettering
Fixes: #2490
2016-02-01activate: reorder --help textLennart Poettering
Make sure the --help and --version options are mentioned first, like in all our other tools.
2016-02-01activate: fix memory allocation for execv() parametersLennart Poettering
Make sure we construct the full environment block on the heap, so that we can clean things up properly if execv() fails.
2016-02-01Merge pull request #2505 from torstehu/fix-typo4Lennart Poettering
Fix typos and a small build fix
2016-02-01resolve: Silence build warning, when systemd is built without libidnTorstein Husebø
HAVE_IDN is not defined when systemd is build without it