1
0
mirror of https://github.com/systemd/systemd.git synced 2024-12-23 21:35:11 +03:00
The systemd System and Service Manager
Go to file
Michal Schmidt 1abc85b8d0 job: avoid recursion into transaction code from job cancelation
I hit an "assert(j->installed)" failure in transaction_apply(). Looking
into the backtrace I saw what happened:
1. The system was booting. var.mount/start was an installed job.
2. I pressed Ctrl+Alt+Del.
3. reboot.target was going to be isolated.
4. transaction_apply() proceeded to install a var.mount/stop job.
5. job_install() canceled the conflicting start job.
6. Depending jobs ended recursively with JOB_DEPENDENCY, among them was
   local-fs.target/start.
7. Its OnFailure action triggered - emergency.target was now going to be
   isolated.
8. We recursed back into transaction_apply() where the half-installed
   var.mount/stop job confused us.

Recursing from job installation back into the transaction code cannot be
a good idea. Avoid the problem by canceling the conflicting job
non-recursively in job_install(). I don't think we'll miss anything by
not recursing here. After all, we are called from transaction_apply().
We will not be installing just this one job, but all jobs from a
transaction. All requirement dependencies will be included in it and
will be installed separately. Every transaction job will get a chance
to cancel its own conflicting installed job.
2012-10-25 03:21:32 +02:00
bash-completion bash-completion: update journalctl for recently added flags 2012-10-21 16:47:15 -04:00
docs docs: install README files into /var/log and 7etc/rc.d/init.d 2012-10-17 21:25:42 +02:00
hwdb udev: add hardware database support 2012-10-23 16:43:32 +02:00
keymaps keymaps: Add "e" key for Acer Aspire 5720 2012-08-24 07:11:20 +02:00
keymaps-force-release udev: keymap - move src/udev/force-release-maps/ to keymaps-force-release/ 2012-04-14 19:53:31 +02:00
m4 build-sys: Append -Werror when testing flags 2012-09-14 19:06:50 +02:00
man journal: properly serialize fields with multiple values into JSON 2012-10-25 01:24:44 +02:00
po intltool: skip the intermediate file in case it remains, not the source file 2012-07-15 19:28:21 +02:00
rules rules: Remove HP iLO from USB HID PM rules 2012-10-23 16:57:03 +02:00
src job: avoid recursion into transaction code from job cancelation 2012-10-25 03:21:32 +02:00
sysctl.d relicense to LGPLv2.1 (with exceptions) 2012-04-12 00:24:39 +02:00
test udev: fix rule-syntax-check.py 2012-10-09 00:49:15 +02:00
tmpfiles.d tmpfiles: write /run/nologin during early boot to disallow too early user logins 2012-06-25 17:35:13 +02:00
units units: don't order tmp.monut after local-fs-pre.target 2012-10-23 22:33:00 +02:00
.dir-locals.el Keep emacs configuration in one configuration file. 2011-03-08 01:53:46 +01:00
.gitignore update .gitignore 2012-10-22 14:33:35 +02:00
.mailmap update mailmap 2012-08-09 12:52:49 +02:00
.vimrc add .vimrc 2012-01-23 04:42:11 +01:00
autogen.sh autogen.sh: disable _FORTIFY_SOURCE, we want -O0, which is incompatible 2012-08-08 13:16:57 +02:00
CODING_STYLE Minor typo 2012-10-01 21:48:15 +02:00
configure.ac udev: add hardware database support 2012-10-23 16:43:32 +02:00
DISTRO_PORTING main: replace --running-as= by --session and --system do mimic related tools and D-Bus 2010-07-13 18:57:58 +02:00
introspect.awk build-sys: allow cross-compilation 2010-11-23 22:38:55 +01:00
LICENSE.GPL2 relicense to LGPLv2.1 (with exceptions) 2012-04-12 00:24:39 +02:00
LICENSE.LGPL2.1 relicense to LGPLv2.1 (with exceptions) 2012-04-12 00:24:39 +02:00
LICENSE.MIT relicense to LGPLv2.1 (with exceptions) 2012-04-12 00:24:39 +02:00
make-directive-index.py directive-index: journal directives 2012-09-17 12:42:22 +02:00
make-man-index.py python: change license to LGPL 2.1 2012-09-13 04:06:11 +02:00
Makefile.am udev: add hardware database support 2012-10-23 16:43:32 +02:00
NEWS update TODO 2012-10-23 17:13:20 +02:00
README journal: implement time-based rotation/vacuuming 2012-10-16 22:58:07 +02:00
TODO update TODO 2012-10-25 01:24:44 +02:00

systemd System and Service Manager

DETAILS:
        http://0pointer.de/blog/projects/systemd.html

WEB SITE:
        http://www.freedesktop.org/wiki/Software/systemd

GIT:
        git://anongit.freedesktop.org/systemd/systemd
        ssh://git.freedesktop.org/git/systemd/systemd

GITWEB:
        http://cgit.freedesktop.org/systemd/systemd

MAILING LIST:
        http://lists.freedesktop.org/mailman/listinfo/systemd-devel
        http://lists.freedesktop.org/mailman/listinfo/systemd-commits

IRC:
        #systemd on irc.freenode.org

BUG REPORTS:
        https://bugs.freedesktop.org/enter_bug.cgi?product=systemd

AUTHOR:
        Lennart Poettering
        Kay Sievers
        ...and many others

LICENSE:
        LGPLv2.1+ for all code
        - except sd-daemon.[ch] and sd-readahead.[ch] which are MIT
        - except src/udev/ which is GPLv2.0+

REQUIREMENTS:
        Linux kernel >= 2.6.39
                with devtmpfs
                with cgroups (but it's OK to disable all controllers)
                optional but strongly recommended: autofs4, ipv6
        dbus >= 1.4.0
        libcap
        libblkid >= 2.20 (from util-linux)
        libkmod >= 5
        PAM >= 1.1.2 (optional)
        libcryptsetup (optional)
        libgcrypt (optional)
        libaudit (optional)
        libacl (optional)
        libattr (optional)
        libselinux (optional)
        liblzma (optional)
        tcpwrappers (optional)
        libgcrypt (optional)
        libqrencode (optional)
        libmicrohttpd (optional)

        When you build from git you need the following additional dependencies:

        docbook-xsl
        xsltproc
        automake
        autoconf
        libtool
        intltool
        gperf
        gtkdocize (optional)
        python (optional)
        make, gcc, and similar tools

        During runtime you need the following dependencies:

        util-linux > v2.18 (requires fsck -l, agetty -s)
        sulogin (from sysvinit-tools, optional but recommended)
        dracut (optional)

        When systemd-hostnamed is used it is strongly recommended to
        install nss-myhostname to ensure that in a world of
        dynamically changing hostnames the hostname stays resolveable
        under all circumstances. In fact, systemd-hostnamed will warn
        if nss-myhostname is not installed. Packagers are encouraged to
        add a dependency on nss-myhostname to the package that
        includes systemd-hostnamed.

        Note that D-Bus can link against libsystemd-login.so, which
        results in a cyclic build dependency. To accommodate for this
        please build D-Bus without systemd first, then build systemd,
        then rebuild D-Bus with systemd support.

WARNINGS:
        systemd will warn you during boot if /etc/mtab is not a
        symlink to /proc/mounts. Please ensure that /etc/mtab is a
        proper symlink.

        systemd will warn you during boot if /usr is on a different
        file system than /. While in systemd itself very little will
        break if /usr is on a separate partition many of its
        dependencies very likely will break sooner or later in one
        form or another. For example udev rules tend to refer to
        binaries in /usr, binaries that link to libraries in /usr or
        binaries that refer to data files in /usr. Since these
        breakages are not always directly visible systemd will warn
        about this, since this kind of file system setup is not really
        supported anymore by the basic set of Linux OS components.

        For more information on this issue consult
        http://freedesktop.org/wiki/Software/systemd/separate-usr-is-broken

        To run systemd under valgrind, compile with VALGRIND defined
        (e.g. ./configure CPPFLAGS='... -DVALGRIND=1'). Otherwise,
        false positives will be triggered by code which violates
        some rules but is actually safe.

ENGINEERING AND CONSULTING SERVICES:
        ProFUSION <http://profusion.mobi> offers professional
        engineering and consulting services for systemd for embedded
        and other use. Please contact Gustavo Barbieri
        <barbieri@profusion.mobi> for more information.

        Disclaimer: This notice is not a recommendation or official
        endorsement. However, ProFUSION's upstream work has been very
        beneficial for the systemd project.