Commit Graph

19053 Commits

Author SHA1 Message Date
Lennart Poettering 2bc39683c0 update TODO 2015-01-27 17:58:57 +01:00
Lennart Poettering 831f18cbf3 build-sys: make bzip2 really optional 2015-01-27 17:58:57 +01:00
Lennart Poettering 0ef403877a units: turn on watchdog for resolved 2015-01-27 14:31:44 +01:00
Lennart Poettering e87bc3ef67 units: fix all TTY paths for container gettys
Spotted by Christian Seiler:

http://lists.freedesktop.org/archives/systemd-devel/2015-January/027441.html
2015-01-27 14:31:44 +01:00
Patrik Flykt c62c4628d9 networkd-dhcp6: Assign DHCPv6 addresses and prefix lengths
Once IPv6 addresses have been acquired, assign these to the interface
with the prefix lengths taken from the ICMPv6 Router Advertisement
handling code. The preferred and valid IPv6 address lifetimes are
handed to the kernel which will clean up them if not renewed in time.

When a prefix announced via Router Advertisements expires, find all
addresses that match that prefix and update the address to have a
prefix length of 128 causing the prefix to be off-link.
2015-01-27 09:35:24 +02:00
Patrik Flykt bd1957e906 sd-icmp6-nd: Add support for fetching the latest expired prefix
Keep the expired prefix for the duration of the prefix expiration event
and remove it afterwards.
2015-01-27 09:35:24 +02:00
Patrik Flykt 99af546d0e test-icmp6-nd: Add test cases for prefixes
Add test cases that feeds an Router Advertisement to the ICMPv6 code
and verify that the correct prefix lengths are returned given an IPv6
address.

Enhance the prefix verification test by adding a shorter prefix and
check that the intended prefix lengths are now updated.
2015-01-27 09:35:24 +02:00
Patrik Flykt d77bde34cf sd-icmp6-nd: Parse ICMPv6 prefix information
Save each new onlink IPv6 prefix and attach an expiry timer to it.
If the prefixes overlap, take the shorter prefix and write a debug
message about the event. Once the prefix is resent in a Router
Advertisement, update the timer. Add a new event for the expiring
prefix.

Add two helper functions, one for returning a prefix length given a
Router Advertisement and the other for generic prefix matching given
an IPv6 prefix and address.
2015-01-27 09:35:24 +02:00
Patrik Flykt 8d7f2c6a47 test-icmp6-rs: Add trivial test case for an MTU that is not present 2015-01-27 09:35:24 +02:00
Patrik Flykt d14b5bc621 sd-icmp6-nd: Add helper function to get the IPv6 link MTU
Update MTU according to the latest value received.
2015-01-27 09:35:24 +02:00
Patrik Flykt 5624c4801e sd-icmp6-nd: Add link and prefix structures for ICMPv6
Each ICMPv6 structure has an interface index and will therefore be
associated with an IPv6 link containing a list of of prefixes.
2015-01-27 09:35:24 +02:00
Patrik Flykt 09667885ba sd-icmp6-nd: Update Router Advertisement handling
As the IPv6 prefixes are needed, update the ICMPv6 Router Advertisement
code to dynamically allocate a suitably sized buffer. Iterate through
the ICMPv6 options one by one returning error if the option length is
too big to fit the buffer.
2015-01-27 09:35:24 +02:00
Patrik Flykt e7504d9547 sd-dhcp6-lease: Revise address iteration functions
Revise the address iteration functions so that one helper function
resets the iterator to the start of the address list while the
second one fetches addresses one by one.

The test case is also updated.
2015-01-27 09:35:24 +02:00
Zbigniew Jędrzejewski-Szmek 2a481c8456 compile-unifont: Python 2 compatibility
Under Python 2, sys.stdout.buffer is missing.
2015-01-26 23:56:34 -05:00
Zbigniew Jędrzejewski-Szmek 10bc4cd469 build-sys: unbundle unifont
We should prefer the unifont.hex file from the system, instead of our
own. Upstream has made a few releases since our version was included,
and we should follow upstream changes. But adding 2.6MB to our source
repo every time upstream releases is not nice.
2015-01-26 23:56:34 -05:00
Zbigniew Jędrzejewski-Szmek 4a84f3e614 TODO: remove laccess conversion
I looked over all access invocations, and I think are using access()
correctly. Accepting dangling symlinks makes sense only in special
circumstances.

So far we do not allow "flag" files like "/fastboot" to be dangling
symlinks. We could, but I don't see a reason to.
2015-01-26 23:56:26 -05:00
Lennart Poettering 687f6a0ba7 update TODO 2015-01-27 02:36:40 +01:00
Lennart Poettering 7e26029ff3 timesyncd: set RLIMIT_NPROC to 2
This way timesyncd cannot be used to fork().

Note that it generally is not safe to use RLIMIT_NPROC, since it breaks
running the same daemon in multiple containers if they do not use user
namespacing. However, timesyncd is excepted from running in a container
anyway, hence it is safe in this case.
2015-01-27 02:33:46 +01:00
Lennart Poettering c51cbfdcc7 man: document that ProtectSystem= also covers /boot 2015-01-27 02:19:33 +01:00
Lennart Poettering 297d563de4 core: explain why failing to set up the crash handler is not a real problem
http://lists.freedesktop.org/archives/systemd-devel/2015-January/027428.html
2015-01-27 01:49:09 +01:00
Lennart Poettering 31a11e8f30 update TODO 2015-01-27 01:29:02 +01:00
Zbigniew Jędrzejewski-Szmek 6b321a7901 system-update-generator: accept a dangling symlink
The offline update mechanism is explicitly designed to work with a
separate /var. systemd-update-generator is supposed to run early,
before filesystems are mounted, so it cannot check if the
/system-update symlink actually points to anything.

The update is run *after* filesystems are mounted, so it should be
able to access the target of the symlink without trouble.

https://bugzilla.redhat.com/show_bug.cgi?id=1178978
2015-01-27 01:29:02 +01:00
Michael Olbrich 7fd68245a1 missing: define correct syscall numbers for memfd_create() and getrandom() on aarch64 2015-01-27 00:35:45 +01:00
Lennart Poettering dbdee28bfa update TODO 2015-01-26 21:52:07 +01:00
Lennart Poettering b381de4197 sd-bus: change serialization of kdbus messages to qualify in their entirety as gvariant objects
Previously, we only minimally altered the dbus1 framing for kdbus, and
while the header and its fields where compliant Gvariant objects, and so
was the body, the entire message together was not.

As result of discussions with Ryan Lortie this is now changed, so that
the messages in there entirely are fully compliant GVariants. This
follows the framing description described here:

https://wiki.gnome.org/Projects/GLib/GDBus/Version2

Note that this change changes the framing of *all* messages sent via
kdbus, this means you have to reboot your kdbus system, after compiling
and installing this new version.
2015-01-26 21:52:07 +01:00
Lennart Poettering ee04388a54 bus-dump: fix two minor memory leaks 2015-01-26 21:52:07 +01:00
Lennart Poettering ad4cdc5515 man: fix minor type in man page 2015-01-26 21:52:07 +01:00
Lennart Poettering 72e6110485 sd-bus: reuse the KDBUS_CMD_FREE wrapper wherever appropriate 2015-01-26 21:52:07 +01:00
Torstein Husebø cc98b3025e treewide: fix multiple typos 2015-01-26 10:39:47 -05:00
Zbigniew Jędrzejewski-Szmek ebf31a1f58 tmpfiles: use casts instead of warning suppression
This warning got its own name only in gcc5, so the suppression does
not work in gcc4, and generates a warning of its own. Use a cast,
which is ugly too, but less so.
2015-01-26 10:39:03 -05:00
Lennart Poettering 9cccac8cd2 man: minor typo fix
Spotted by John Paul Adrian Glaubitz
2015-01-26 15:28:18 +01:00
Tom Gundersen 71ef8b3ac4 libudev: private - drop some functions from the internal API 2015-01-26 14:48:04 +01:00
Tom Gundersen 2df959ec3b libudev: monitor - move nulstr parsing to libudev-device
Hide the details a bit.
2015-01-26 14:45:12 +01:00
Tom Gundersen 04ef387ea9 udev: event - minor nit
Stay uniform and use 'dev' rather than 'event->dev', as these are aliases (and event->dev looks
like it may be a typo for event->dev_db).
2015-01-26 14:13:31 +01:00
Tom Gundersen fa639f3ae7 udev: event - introduce and use internal udev_device_shallow_clone() 2015-01-26 14:12:45 +01:00
Tom Gundersen 243d182543 udev: event - move renaming of udev_device to libudev
This is not exposed in the public API. We want to simplify the internal libudev-device API as much as possible
so that it will be simpler to rip the whole thing out in the future.
2015-01-26 13:33:00 +01:00
Zbigniew Jędrzejewski-Szmek df99a9ef5b tmpfiles: do not bump access times of directories we are cleaning up
Both plain opendir() and glob() will bump access time. Privileged
option O_NOATIME can be used to prevent the access time from being
updated. We already used it for subdirectories of the directories
which we were cleaning up. But for the directories specified directly
in the config files, we wouldn't do that. This means that,
paradoxically, our own temporary directories for PrivateTmp would stay
around forever, as long as one let systemd-tmpfiles-clean.service run
regularly, because they had their own glob patterns specified.

https://bugzilla.redhat.com/show_bug.cgi?id=1183684
2015-01-24 23:38:59 -05:00
Zbigniew Jędrzejewski-Szmek 582deb8446 tmpfiles: add debug statements for all actions
systemd-tmpfiles can be used by users, but it can be quite hard to
figure out the logic it follows, especially since the logic is in some
places rather torturous. Hopefuly this will make it easier for users
to understand what is happening.
2015-01-24 23:38:44 -05:00
Sergey Ptashnick ff485617d9 po: update Russian translation
Add strings for importd.
2015-01-24 21:11:46 -05:00
Piotr Drąg d8681b3fa5 catalog,po: update Polish translation
Patch updates Polish translation with new strings from
org.freedesktop.import1.policy.in, as well as incorporates updates in
catalog and po files to accommodate recent changes in the original
strings (commits 2e219e5672 and
2057124e79).

https://bugs.freedesktop.org/show_bug.cgi?id=88707
2015-01-24 21:11:45 -05:00
Zbigniew Jędrzejewski-Szmek 56b921c3d8 machinectl: fix typo 2015-01-24 21:11:45 -05:00
Cristian Rodríguez cb708b1c6d mount-setup: Do not bother with /proc/bus/usb
Current systemd requires kernel >= 3.7 per the README file
but CONFIG_USB_DEVICEFS disappeared from the kernel in
upstream commit fb28d58b72aa9215b26f1d5478462af394a4d253
(kernel 3.5-rc1)
2015-01-23 19:10:28 +01:00
Cristian Rodríguez 66b0e0e0e3 build-sys: lookup for sulogin, it might not be in /sbin 2015-01-23 19:09:37 +01:00
Lennart Poettering 36a03ca2a8 resolved: when rereading /etc/resolv.conf, always start using first DNS server again
Previously we tried to stick to a DNS server as long as it is available.
When /etc/resolv.conf changed, and the old DNS server we used was still
in there we'd continue to use it, even if it was at the end of the list.

With this change we'll now always start with the first DNS server in the
list again.

Rationale: certain network managing implementations (notably
NetworkManager) when connected to a VPN place both the VPN DNS server as
well as the local DNS server in /etc/resolv.conf. If we used the local
one before we would thus continue to use the local one, making VPN names
unresolvable. NetworkManager really should be fixed to only place the
VPN DNS servers in the file, but with this commit things are at least
similarly bad as they used to be...
2015-01-23 19:03:07 +01:00
Zbigniew Jędrzejewski-Szmek c9403dced7 #pragma once here and there 2015-01-23 09:30:44 -05:00
Zbigniew Jędrzejewski-Szmek 6825a04de6 build-sys: fix build on compilers without static_assert
Build would fail when assert was used on the same line in
different files #included together.

https://bugs.freedesktop.org/show_bug.cgi?id=87339
2015-01-23 09:30:44 -05:00
Sangjung Woo b986229efe systemctl: bugfix for systemctl reboot command with argument
According to systemctl man page, 'systemctl reboot [arg]' should work
without any errors. However, it does not work because of 'Invalid number
of arguments' error, except for 'reboot [arg]'. This patch fixes the bug
so that both of commands work in exactly the same way.
2015-01-23 09:30:44 -05:00
Lennart Poettering 874d3404cb core,shutdown: don't bother with unmounting any mounts below /sys, /proc, /dev when shutting down
After all, mounts below these directories are pretty much guaranteed to
be virtual, and it's hence unnecessary to unmount them during shutdown.
Moreover, in less-priviliged containers we might lack the rights to
unmount them, hence don't even try.

http://lists.freedesktop.org/archives/systemd-devel/2015-January/027113.html
2015-01-23 13:47:41 +01:00
Lennart Poettering b4d5b78374 mount-setup: /selinux, /cgroup, /dev/cgroup are sooo old, don't bother with them anymore 2015-01-23 13:47:41 +01:00
Zbigniew Jędrzejewski-Szmek 7fcb4b9b17 tmpfiles: minor simplification 2015-01-23 00:12:52 -05:00