summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2016-05-03networkd: Add support to configure IPv6 preferred lifetime (#3102)Susant Sahani
Closes #2166. We only allow 0, infinity and forever. infinity and forever is same.
2016-05-03Merge pull request #3132 from ssahani/route-tableZbigniew Jędrzejewski-Szmek
networkd: add support to set route table
2016-05-03Merge pull request #3173 from poettering/dnssec-incapdns-fixZbigniew Jędrzejewski-Szmek
Dnssec incapdns fix
2016-05-03test-dnssec: drop unused variableLennart Poettering
(zjs: the tree is now back to 0b2abe0f034f7f2d8654adb11b516d1090ec9a9c.)
2016-05-03Merge pull request #2921 from keszybz/do-not-report-masked-units-as-changedZbigniew Jędrzejewski-Szmek
2016-05-03Revert "Do not report masked units as changed (#2921)"Zbigniew Jędrzejewski-Szmek
This reverts commit 6d10d308c6cd16528ef58fa4f5822aef936862d3. It got squashed by mistake.
2016-05-03Revert "test-dnssec: drop unused variable"Zbigniew Jędrzejewski-Szmek
This reverts commit 0bed31c1038c439cc5956fb44017ba28e503095b.
2016-05-03Merge pull request #3111 from poettering/nspawn-remove-vethZbigniew Jędrzejewski-Szmek
2016-05-03Revert "nspawn: explicitly remove veth links after use (#3111)"Zbigniew Jędrzejewski-Szmek
This reverts commit d2773e59de3dd970d861e9f996bc48de20ef4314. Merge got squashed by mistake.
2016-05-03networkd: add support to set route tableSusant Sahani
networkd: add support to set route table 1. add support to configure the table id. if id is less than 256 we can fit this in the header of route as netlink property is a char. But in kernel this proepty is a unsigned 32. Hence if greater that 256 add this as RTA_TABLE attribute. 2. we are not setting the address family now. Now set this property.
2016-05-03sd-netlink: introduce route attribute set APISusant Sahani
Introduce 1. sd_rtnl_message_route_set_table to set table ID 2. sd_rtnl_message_route_set_family to set family Both required to configure route properties.
2016-05-03sd-netlink: fix sd_netlink_message_append_dataSusant Sahani
Also remove the braces add_rtattr not required.
2016-05-02locale: Language fallbacks for fr_(BE|CA|CH|LU) to fr_FR (#3178)Sylvain Plantefève
2016-05-02Merge pull request #3162 from keszybz/alias-refusalLennart Poettering
Refuse Alias, DefaultInstance, templated units in install (as appropriate)
2016-05-02Merge pull request #3153 from poettering/async-cloneZbigniew Jędrzejewski-Szmek
machined: make "clone" asynchronous, and support copy-based fall-back
2016-05-02resolved: work around broken DNS zones set up by incapdns.netLennart Poettering
incapdns.net returns NXDOMAIN for the SOA of the zone itself but is not a terminal. This is against the specs, but we really should be able to deal with this. Previously, when verifying whether an NXDOMAIN response for a SOA/NS lookup is rightfully unsigned we'd issue a SOA lookup for the parent's domain, to derive the state from that. If the parent SOA would get an NXDOMAIN, we'd continue upwards, until we hit a signed top-level domain, which suggests that the domain actually exists. With this change whenver we need to authenticate an NXDOMAIN SOA reply, we'll request the DS RR for the zone first, and use for validation, since that this must be from the parent's zone, not the incorrect lower zone. Fixes: #2894
2016-05-02machinectl: since clone/remove/copy verbs are possibly slow, turn off bus ↵Lennart Poettering
call timeout By default we timeout all bus calls, but if we know that these bus calls might be slow, let's explicitly turn the timeouts off.
2016-05-02machined: rework copy-from/copy-to operation to use generic Operation objectLennart Poettering
With this all potentially slow operations are done out-of-process, asynchronously, using the same "Operation" object.
2016-05-02machined: also make image removal operation asynchronousLennart Poettering
If we remove a directory image (i.e. not a btrfs snapshot) then things might get quite expensive, hence run this asynchronous in a forked off process, too.
2016-05-02machined: support non-btrfs file systems with "machinectl clone"Lennart Poettering
Fall back to a normal copy operation when the backing file system isn't btrfs, and hence doesn't support cheap snapshotting. Of course, this will be slow, but given that the execution is asynchronous now, this should be OK. Fixes: #1308
2016-05-02tree-wide: fix invocations of chattr_path()Lennart Poettering
chattr_path() takes two bitmasks, and no booleans. Fix the various invocations to do this properly.
2016-05-02copy: adjust directory times after writing to the directoryLennart Poettering
When recursively copying a directory tree, fix up the file times after having created all contents in it, so that our changes don't end up altering any of the directory times.
2016-05-02copy: return the right error when we can't open a fileLennart Poettering
2016-05-02image: enable btrfs quotas on the clone destination, not the sourceLennart Poettering
2016-05-02util: rework sigkill_wait() to not require pid_t pointerLennart Poettering
Let's make sigkill_wait() take a normal pid_t, and add sigkill_waitp() that takes a pointer (which is useful for usage in _cleanup_), following the usual logic we have for this.
2016-05-02machined: run clone operation asynchronously in the backgroundLennart Poettering
Cloning an image can be slow, if the image is not on a btrfs subvolume, hence let's make sure we do this asynchronously in a child process, so that machined isn't blocked as long as we process the client request. This adds a new, generic "Operation" object to machined, that is used to track these kind of background processes. This is inspired by the MachineOperation object that already exists to make copy operations asynchronous. A later patch will rework the MachineOperation logic to use the generic Operation instead.
2016-05-01shared/install: refuse template files for non-templateable unitsZbigniew Jędrzejewski-Szmek
$ systemctl --root=/ enable templated@bar.mount Unit type mount cannot be templated. Failed to enable: Invalid argument.
2016-05-01shared/install: warn about DefaultInstance in non-template unitsZbigniew Jędrzejewski-Szmek
[/etc/systemd/system/mnt-test.mount:6] DefaultInstance only makes sense for template units, ignoring.
2016-05-01Move no_instances information to shared/Zbigniew Jędrzejewski-Szmek
This way it can be used in install.c in subsequent commit.
2016-05-01shared/install: ignore Alias in [Install] of units which don't allow aliasesZbigniew Jędrzejewski-Szmek
A downside is that a warning about missing [Install] is printed: $ systemctl --root=/ enable mnt-test.mount [/etc/systemd/system/mnt-test.mount:5] Aliases are not allowed for mount units, ignoring. The unit files have no installation config (WantedBy, RequiredBy, Also, Alias settings in the [Install] section, and DefaultInstance for template units). This means they are not meant to be enabled using systemctl. Possible reasons for having this kind of units are: 1) A unit may be statically enabled by being symlinked from another unit's .wants/ or .requires/ directory. 2) A unit's purpose may be to act as a helper for some other unit which has a requirement dependency on it. 3) A unit may be started when needed via activation (socket, path, timer, D-Bus, udev, scripted systemctl call, ...). 4) In case of template units, the unit is meant to be enabled with some instance name specified. That's a bit misleading, but I don't see an easy way to fix this. But the situation is similar for many other parsing errors, so maybe that's OK.
2016-05-01Move no_alias information to shared/Zbigniew Jędrzejewski-Szmek
This way it can be used in install.c in subsequent commit.
2016-04-30Merge pull request #3152 from poettering/aliasfixZbigniew Jędrzejewski-Szmek
Refuse aliases to non-aliasable units in more places Fixes #2730.
2016-04-30architecture: Add nios2 (#3159)Zbigniew Jędrzejewski-Szmek
Add nios2 architecture support. The nios2 is a softcore by Altera.
2016-04-29Merge pull request #3151 from keszybz/pr3149-2Zbigniew Jędrzejewski-Szmek
Assorted fixes #3149 + one commit tacked on top
2016-04-29core: when encountering a symlink alias for non-aliasable units warn nicelyLennart Poettering
If the user defines a symlink alias for a unit whose type does not support aliasing, detect this early and print a nice warning. Fixe: #2730
2016-04-29hashmap: optimize set_put_strdup() a bitLennart Poettering
Hashing should be quicker than allocating, hence let's first check if the string already exists and only then allocate a new copy for it.
2016-04-29core: refuse merging on units when the unit type does not support aliasLennart Poettering
The concept of merging units exists so that we can create Unit objects for a number of names early, and then load them only later, possibly merging units which then turn out to be symlinked to other names. This of course only makes sense for unit types where multiple names per unit are supported. For all others, let's refuse the merge operation early.
2016-04-29core: merge service_connection_unref() into service_close_socket_fd()Lennart Poettering
We always call one after the other anyway, and this way service_set_socket_fd() and service_close_socket_fd() nicely match each other as one undoes the effect of the other.
2016-04-29core: rerun GC logic for a unit that loses a referenceLennart Poettering
Let's make sure when we drop a reference to a unit, that we run the GC queue on it again. This (together with the previous commit) should deal with the GC issues pointed out in: https://github.com/systemd/systemd/pull/2993#issuecomment-215331189
2016-04-29core: rework socket/service GC logicLennart Poettering
There's no need to set the no_gc bit for service units that socket units prepare, as we always keep a proper reference (as maintained by unit_ref_set()) on them, and such references are honoured by the GC logic anyway. Moreover, explicitly setting the no_gc bit is problematic if the socket gets GC'ed for a reason, as the service might then leak with the bit set.
2016-04-29socket: really always close auxiliary fds when closing socket fdsLennart Poettering
2016-04-29core: make parsing of RLIMIT_NICE aware of actual nice levelsLennart Poettering
2016-04-29core: make sure to close connection fd when we fail to activate a ↵Lennart Poettering
per-connection service Fixes: #2993 #2691
2016-04-29core: minor error path fixLennart Poettering
In service_set_socket_fd(), let's make sure that if we can't add the requested dependencies we take no possession of the passed connection fd. This way, we follow the strict rule: we take possession of the passed fd on success, but on failure we don't, and the fd remains in possession of the caller.
2016-04-29core: rename StartLimitInterval= to StartLimitIntervalSec=Lennart Poettering
We generally follow the rule that for time settings we suffix the setting name with "Sec" to indicate the default unit if none is specified. The only exception was the rate limiting interval settings. Fix this, and keep the old names for compatibility. Do the same for journald's RateLimitInterval= setting
2016-04-29core: move start ratelimiting check after condition checksLennart Poettering
With #2564 unit start rate limiting was moved from after the condition checks are to before they are made, in an attempt to fix #2467. This however resulted in #2684. However, with a previous commit a concept of per socket unit trigger rate limiting has been added, to fix #2467 more comprehensively, hence the start limit can be moved after the condition checks again, thus fixing #2684. Fixes: #2684
2016-04-29core: introduce activation rate limiting for socket unitsLennart Poettering
This adds two new settings TriggerLimitIntervalSec= and TriggerLimitBurst= that define a rate limit for activation of socket units. When the limit is hit, the socket is is put into a failure mode. This is an alternative fix for #2467, since the original fix resulted in issue #2684. In a later commit the StartLimitInterval=/StartLimitBurst= rate limiter will be changed to be applied after any start conditions checks are made. This way, there are two separate rate limiters enforced: one at triggering time, before any jobs are queued with this patch, as well as the start limit that is moved again to be run immediately before the unit is activated. Condition checks are done in between the two, and thus no longer affect the start limit.
2016-04-29build-sys: improve compat with older kernel headersLennart Poettering
In 4.2 kernel headers, some netlink defines are missing that we need. missing.h already can add them in, but currently makes this dependent on a definition that these kernels already have. Change the check hence to check for the newest definition in the table, so that the whole bunch of definitions as added in on all kernels lacking this.
2016-04-29path-util: also support ".old" and ".new" suffixes and recommend themZbigniew Jędrzejewski-Szmek
~ suffix works fine, but looks to much like it the file is supposed to be automatically cleaned up. For new versions of configuration files installers might want to using something that looks more permanent like foobar.new. So let's add treat ".old" and ".new" as special. Update test to match.
2016-04-29core: Filter by unit name behind the D-Bus, instead on the client side (#3142)kayrus
This commit improves systemd performance on the systems which have thousands of units.