summaryrefslogtreecommitdiff
path: root/src/core/manager.c
AgeCommit message (Collapse)Author
2013-03-31Partially revert e62d8c394474Zbigniew Jędrzejewski-Szmek
The ~80 chars per line part wasn't well received.
2013-03-31ModernizationZbigniew Jędrzejewski-Szmek
Use _cleanup_ and wrap lines to ~80 chars and such.
2013-03-15core: reuse the same /tmp, /var/tmp and inaccessible dirMichal Sekletar
All Execs within the service, will get mounted the same /tmp and /var/tmp directories, if service is configured with PrivateTmp=yes. Temporary directories are cleaned up by service itself in addition to systemd-tmpfiles. Directory which is mounted as inaccessible is created at runtime in /run/systemd.
2013-03-13util, manager: and mempset() and use itMichal Schmidt
Just like mempcpy() is almost identical to memcpy() except the useful return value, so is the relation of mempset() to memset().
2013-03-13manager: use more stpcpy()Michal Schmidt
2013-03-13manager: push back animation timer whenever a job finishesMichal Schmidt
The running jobs animation is supposed to hide itself when jobs are progressing sufficiently fast.
2013-03-06manager: remove timer fd explicitly from epollEnrico Scholz
Forked processes can keep the old fd alive triggering epoll over and over again else. https://bugs.freedesktop.org/show_bug.cgi?id=61697
2013-03-04core/manager: fix conditions to start and stop watching running jobsMichal Schmidt
Harald encountered division by zero in manager_print_jobs_in_progress. Clearly we had the watch enabled when we shouldn't - there were no running jobs in m->jobs, only waiting ones. This is either a deadlock, or maybe some of them would be detected as runnable in the next dispatch of the run queue. In any case we mustn't crash. Fix it by starting and stopping the watch based on n_running_jobs instead of the number of all jobs.
2013-03-02manager: turn a superfluous check into assertMichal Schmidt
The crash that the check prevented has been fixed by commit 9e9e2b7.
2013-03-01manager: print p and then free itLukas Nykryn
2013-03-01core: fix running jobs counters after reload/reexecMichal Schmidt
All active units will call unit_notify() during coldplug, so we just make sure we're counting from zero again and get the correct result for n_on_console. For n_running_jobs we likewise reset it to zero and then count the running jobs as we encounter them in deserialization.
2013-03-01manager: prevent segfault in manager_print_jobs_in_progress()Harald Hoyer
2013-02-28core/manager: print status messages about running jobsMichal Schmidt
Sometimes the boot gets stuck until a timeout hits. The usual timeouts are on the order of minutes, so users may lose patience. Print animated status messages telling the names of units with running jobs to make it easy to see what systemd is waiting for. The animation looks cooler with a shorter interval, but 1 s is OK and should not be too hard on slow serial console users.
2013-02-28util, core: add support for ephemeral status linesMichal Schmidt
Ephemeral status lines do not end with a newline and they expect to be overwritten by the next printed status line.
2013-02-28core/manager: make a couple of functions staticMichal Schmidt
They're not used outside manager.c anymore.
2013-02-28core: add manager_status_printf()Michal Schmidt
unit_status_printf() checks the state of the manager, not of the unit as such. Move it to manager.c and rename it to manager_status_printf(). Temporarily keep unit_status_printf as a wrapper macro.
2013-02-22core, systemctl: add support for irreversible jobsMichal Schmidt
Add a new job mode: replace-irreversibly. Jobs enqueued using this mode cannot be implicitly canceled by later enqueued conflicting jobs. They can however still be canceled with an explicit "systemctl cancel" call.
2013-02-13build-sys: make EFI support build-time optionalLennart Poettering
2013-02-13manager: pass environment over daemon-reexecOleksii Shevchuk
Fixes this bug: alxchk > systemctl --user set-environment A=B alxchk > systemctl --user show-environment | grep ^A= A=B alxchk > systemctl --user daemon-reexec alxchk > systemctl --user show-environment | grep ^A= alxchk >
2013-02-11manager: clean environment before passing it on to othersLennart Poettering
2013-02-06systemd: raise level of message about lookup pathsZbigniew Jędrzejewski-Szmek
This can be pretty important for the user, and is not trivial to figure out in all cases. Also show failing path in error messages.
2013-02-06systemd: do not remove empty paths from unit lookup pathZbigniew Jędrzejewski-Szmek
The ability to start a new unit with 'systemctl start ...' should not depend on whether there are other units in the directory. Previously, an additional 'systemctl daemon-reload' would be necessary to tell systemd to update the list of unit lookup paths.
2013-01-22Replace autoconf int max test with simple defineZbigniew Jędrzejewski-Szmek
2013-01-22Fix some typosEelco Dolstra
2013-01-19core: if the bootloader supports it, determine firmware and boot loader delayLennart Poettering
This allows us to print simple performance data of all parts of the boot now: - firmware - boot loader - kernel - initrd - userspace This only works for bootloaders which support passing TSC data via EFI variables. As of now that's only gummiboot.
2013-01-18build-sys: add autoconf macro to pick macro for x32 compatibilityZbigniew Jędrzejewski-Szmek
2013-01-08core: properly initialize kernel timestampLennart Poettering
2013-01-06systemd: use unit logging macrosZbigniew Jędrzejewski-Szmek
2013-01-06core/manager: modernize styleZbigniew Jędrzejewski-Szmek
2012-12-22nspawn: try to orderly shutdown container when receiving SIGTERMLennart Poettering
2012-12-22socket: support socket activation of containersLennart Poettering
2012-11-25manager: fix build on 32bit systemsLennart Poettering
2012-11-25timer: recalculate next elapse for calendar timer units when the system ↵Lennart Poettering
clock is changed
2012-11-22manager: introduce watch_init() initializer for watchesLennart Poettering
2012-10-18manager: connect SIGRTMIN+24 to terminating --user instancesLennart Poettering
2012-10-13log: introduce a macro to format message idZbigniew Jędrzejewski-Szmek
The MESSAGE_ID=... stanza will appear in countless number of places. It is just too long to write it out in full each time. Incidentally, this also fixes a typo of MESSSAGE is three places.
2012-10-02audit: turn the audit fd into a static variableLennart Poettering
As audit is pretty much just a special kind of logging we should treat it similar, and manage the audit fd in a static variable. This simplifies the audit fd sharing with the SELinux access checking code quite a bit.
2012-09-18core: move ManagerRunningAs to sharedZbigniew Jędrzejewski-Szmek
Note: I did s/MANAGER/SYSTEMD/ everywhere, even though it makes the patch quite verbose. Nevertheless, keeping MANAGER prefix in some places, and SYSTEMD prefix in others would just lead to confusion down the road. Better to rip off the band-aid now.
2012-09-18selinux: use existing library calls for audit dataLennart Poettering
2012-09-17main: newer kernels return EINVAL if we invoke reboot() in a container ↵Lennart Poettering
lacking perms, deal with it
2012-09-13manager: fix the buildLennart Poettering
2012-09-13manager: extend performance measurement interface to include firmware/loader ↵Lennart Poettering
times This only adds the fields to the D-Bus interfaces but doesn't fill them in with anything useful yet. Gummiboot exposes the necessary bits of information to use however and as soon as I get my fingers on a proper UEFI laptop I'll hook up the remaining bits. Since we want to stabilize the D-Bus interface soon and include it in the stability promise we should get the last fixes in, hence this change now.
2012-09-03journal: suppress structured messages if they'd go to the consoleLennart Poettering
2012-09-03journal: generate structured journal messages for a number of eventsLennart Poettering
2012-07-26log.h: new log_oom() -> int -ENOMEM, use itShawn Landden
also a number of minor fixups and bug fixes: spelling, oom errors that didn't print errors, not properly forwarding error codes, few more consistency issues, et cetera
2012-07-25use "Out of memory." consistantly (or with "\n")Shawn Landden
glibc/glib both use "out of memory" consistantly so maybe we should consider that instead of this. Eliminates one string out of a number of binaries. Also fixes extra newline in udev/scsi_id
2012-07-19manager: use a private notify sockets in containers to avoid problems with ↵Lennart Poettering
shared abstract socket namespaces
2012-07-18unit: don't serialize job state, only unit state across switch-rootLennart Poettering
2012-07-13util: rename join() to strjoin()Lennart Poettering
This is to match strappend() and the other string related functions.
2012-07-10unit-name: remove unit_name_is_valid_no_type() and move unit_name_is_valid() ↵Lennart Poettering
to unit-name.h