summaryrefslogtreecommitdiff
path: root/src/core
Commit message (Collapse)AuthorAge
...
* core: fix typo in log messageMichael Biebl2015-01-05
|
* nspawn: mount most of the cgroup tree read-only in nspawn containers except ↵Lennart Poettering2015-01-05
| | | | | | | for the container's own subtree in the name=systemd hierarchy More specifically mount all other hierarchies in their entirety and the name=systemd above the container's subtree read-only.
* cgroup: downgrade log messages when we cannot write to cgroup trees that are ↵Lennart Poettering2015-01-05
| | | | mounted read-only
* mount: do not use -n when running in --user modeZbigniew Jędrzejewski-Szmek2015-01-01
| | | | | | | | -n is only allowed for root. /etc/mtab is nowadays almost always a link to /proc/, so in practice this does not really matter too much, but should allow .mount units to work in --user mode. https://bugs.freedesktop.org/show_bug.cgi?id=87602
* Type of mount(2) flags is unsigned longTopi Miettinen2015-01-01
|
* tree-wide: spelling fixesVeres Lajos2014-12-30
| | | | | | | https://github.com/vlajos/misspell_fixer https://github.com/torstehu/systemd/commit/b6fdeb618cf2f3ce1645b3315f15f482710c7ffa Thanks to Torstein Husebo <torstein@huseboe.net>.
* core: loopback - correctly fail the loopback_check if somehow the rtnl calls ↵Tom Gundersen2014-12-29
| | | | fail
* core: loopback - simplify check_loopback()Tom Gundersen2014-12-28
| | | | | | We no longer configure the addresses on the loopback interface, but simply bring it up and let the kernel do the rest. Also change the check to only check if the interface is up, rather than checking for the IPv4 loopback address.
* tmpfiles: add new line type 'v' for creating btrfs subvolumesLennart Poettering2014-12-28
|
* Fix check_loopback()Stéphane Graber2014-12-27
| | | | | Add missing htonl() so that check_loopback() actually tests for 127.0.0.1 instead of 1.0.0.127 on little-endian machines.
* util: fix strict aliasing violations in use of struct inotify_event v5Shawn Paul Landden2014-12-24
| | | | | There is alot of cleanup that will have to happen to turn on -fstrict-aliasing, but I think our code should be "correct" to the rule.
* bus: add missing bus-policy.[ch]Lennart Poettering2014-12-23
| | | | Accidentally forgot to commit this. Sorry!
* build-sys: move core/build.h → shared/build.hLennart Poettering2014-12-23
| | | | | | | | After all, pretty much all our tools include it, and it should hence be shared. Also move sysfs-show.h from core/ to login/, since it has no point to exist in core.
* env-util: don't include files from src/core/Lennart Poettering2014-12-23
|
* core: rearrange code so that libsystemd/sd-bus/ does not include header ↵Lennart Poettering2014-12-23
| | | | | | | files from core Stuff in src/shared or src/libsystemd should *never* include code from src/core or any of the tools, so don't do that here either. It's not OK!
* run: add a new "-t" mode for invoking a binary on an allocated TTYLennart Poettering2014-12-23
|
* busname: fix CMD_FREE ioctlDaniel Mack2014-12-22
| | | | The KDBUS_CMD_FREE ioctl struct has a size field now, which needs to be set.
* util: rename ignore_file() to hidden_file()Lennart Poettering2014-12-19
| | | | | hidden_file() is a bit more precise, since dot files usually shouldn't be ignored, but certainly be considered hidden.
* execute: the runtime directory can only be on tmpfs, hence don't use ↵Lennart Poettering2014-12-19
| | | | rm_rf_dangerous() needlessly
* load-fragment: allow quoting in command name and document allowed escapesZbigniew Jędrzejewski-Szmek2014-12-18
| | | | | | | | | The handling of the command name and other arguments is unified. This simplifies things and should make them more predictable for users. Incidentally, this makes ExecStart handling match the .desktop file specification, apart for the requirment for an absolute path. https://bugs.freedesktop.org/show_bug.cgi?id=86171
* tree-wide: make condition_free_list return NULLZbigniew Jędrzejewski-Szmek2014-12-18
|
* core: make exec_command_free_list return NULLZbigniew Jędrzejewski-Szmek2014-12-18
|
* core: use raw_clone instead of fork in signal handlerZbigniew Jędrzejewski-Szmek2014-12-18
| | | | | | | | | | | | fork() is not async-signal-safe and calling it from the signal handler could result in a deadlock when at_fork() handlers are called. Using the raw clone() syscall sidesteps that problem. The tricky part is that raise() does not work, since getpid() does not work. Add raw_getpid() to get the real pid, and use kill() instead of raise(). https://bugs.freedesktop.org/show_bug.cgi?id=86604
* load-fragment: properly unescape \;tomsod-m ya ru2014-12-17
| | | | https://bugs.freedesktop.org/show_bug.cgi?id=87393
* Move dropin listing to sharedZbigniew Jędrzejewski-Szmek2014-12-16
| | | | | No functional change. This is in preparation for using this in systemctl in the future.
* unit: handle nicely of certain unit types are not supported on specific systemsLennart Poettering2014-12-15
| | | | | | | | | | | | Containers do not really support .device, .automount or .swap units; Systems compiled without support for swap do not support .swap units; Systems without kdbus do not support .busname units. With this change attempts to start a unsupported unit types will result in an immediate "unsupported" job result, which is a lot more descriptive then before. Also, attempts to start device units in containers will now immediately fail instead of causing jobs to be enqueued that never go away.
* wrap a few *_FOREACH macros in curly bracesThomas Hindoe Paaboel Andersen2014-12-12
| | | | | | cppcheck would give up with "syntax error" without them. This led to reports of syntax errors in unrelated locations and potentially hid other errors
* core: retry unmounting until we are done, in case of stacked mountsLennart Poettering2014-12-12
|
* copy: use btrfs reflinking only whe we know we copy full filesLennart Poettering2014-12-12
|
* util: when using basename() for creating temporary files, verify the ↵Lennart Poettering2014-12-12
| | | | | | | | resulting name is actually valid Also, rename filename_is_safe() to filename_is_valid(), since it actually does a full validation for what the kernel will accept as file name, it's not just a heuristic.
* core: correct spacing near eol in code commentsTorstein Husebø2014-12-11
|
* bus: sync with kdbus.gitDavid Herrmann2014-12-11
| | | | | | | | | | Sync up with recent kdbus changed: * several ioctls gained .size and .items members (but still unused) * CMD_SEND gained its own ioctl structure * several members of kdbus_msg were dropped as they were only used during SEND, not during RECV etc. * CMD_RECV and CMD_SEND now share a kdbus_reply member which contains the offset and size of the returned message.
* scope: make attachment of initial PIDs a bit more robustLennart Poettering2014-12-10
|
* core: don't migrate PIDs for units that may contain subcgroups, do this only ↵Lennart Poettering2014-12-10
| | | | | | | for leaf units Otherwise a slice or delegation unit might move PIDs around ignoring the fact that it is attached to a subcgroup.
* core: properly pass unit file state to clients via the busLennart Poettering2014-12-10
|
* sd-bus: move common errors src/shared/bus-errors.h → ↵Lennart Poettering2014-12-10
| | | | | | src/libsystemd/sd-bus/bus-common-errors.h Stuff in src/shared/ should not use stuff from src/libsystemd/ really.
* ima-setup: simplifyZbigniew Jędrzejewski-Szmek2014-12-09
|
* treewide: sanitize loop_writeZbigniew Jędrzejewski-Szmek2014-12-09
| | | | | | | loop_write() didn't follow the usual systemd rules and returned status partially in errno and required extensive checks from callers. Some of the callers dealt with this properly, but many did not, treating partial writes as successful. Simplify things by conforming to usual rules.
* util: introduce our own gperf based capability listLennart Poettering2014-12-10
| | | | | This way, we can ensure we have a more complete, up-to-date list of capabilities around, always.
* mount: clarify that we really need to replace the utab inotify code with the ↵Lennart Poettering2014-12-10
| | | | native API for this in libmount, as soon as that's stable
* core: unify how we iterate over inotify eventsLennart Poettering2014-12-10
| | | | | Let's add some syntactic sugar for iterating through inotify events, and use it everywhere.
* mount: use bools where appropriateLennart Poettering2014-12-10
|
* unit: update unit dropin paths and time when dropin file is written.WaLyong Cho2014-12-09
| | | | | | | | If a unit is set property by "systemctl set-property", a new dropin file is generated. But the unit's dropin_paths and dropin_mtime are not updated. So the unit is shown as need daemon reload. Update unit dropin_paths and dropin_mtime also when dropin file is written.
* run: introduce timer support optionWaLyong Cho2014-12-09
| | | | | | | | | | | | | Support timer options --on-active=, --on-boot=, --on-startup=, --on-unit-active=, --on-unit-inactive=, --on-calendar=. Each options corresponding with OnActiveSec=, OnBootSec=, OnStartupSec=, OnUnitActiveSec=, OnUnitInactiveSec=, OnCalendar= of timer respectively. And OnCalendar= and WakeSystem= supported by --timer-property= option like --property= of systemd-run. And if --unit= option and timer options are specified the command can be omitted. In this case, systemd-run assumes the target service is already loaded. And just try to generate transient timer unit only.
* core: rename unit_destroy_cgroup() to unit_destroy_cgroup_if_empty() since ↵Lennart Poettering2014-12-09
| | | | it's not quite as destructive as it sounds nowadays
* cgroup: Handle error when destroying cgroupRoss Lagerwall2014-12-09
| | | | | | | | | If a cgroup fails to be destroyed (most likely because there are still processes running as part of a service after the main pid exits), don't free and remove the cgroup unit from the manager. This fixes a regression introduced by the cgroup rework in v205 where systemd would forget about processes still running after the unit becomes inactive. (This can happen when the main pid exits and KillMode=process or none).
* load-fragment: remove wrong ifdef guardZbigniew Jędrzejewski-Szmek2014-12-08
| | | | | | config_parse_warn_compat is now always used for removed options. https://bugs.freedesktop.org/show_bug.cgi?id=87125
* timer: timer can be a transient unitWaLyong Cho2014-12-08
|
* bus: StartTransientUnit can have aux unitWaLyong Cho2014-12-08
|
* selinux: figure out selinux context applied on exec() before closing all fdsMichal Sekletar2014-12-04
| | | | | | We need original socket_fd around otherwise mac_selinux_get_child_mls_label fails with -EINVAL return code. Also don't call setexeccon twice but rather pass context value of SELinuxContext option as an extra argument.