├── docs ├── .gitignore ├── Makefile ├── sysvinit │ ├── .gitignore │ └── Makefile └── var-log │ ├── .gitignore │ └── Makefile ├── hwdb ├── Makefile ├── .gitignore └── 20-net-ifname.hwdb ├── man ├── Makefile ├── .gitignore └── libsystemd-pkgconfig.xml ├── src ├── boot │ ├── Makefile │ └── efi │ │ ├── .gitignore │ │ └── disk.h ├── cgls │ └── Makefile ├── core │ ├── Makefile │ ├── .gitignore │ └── org.freedesktop.systemd1.service ├── fsck │ └── Makefile ├── hwdb │ └── Makefile ├── path │ └── Makefile ├── run │ └── Makefile ├── test │ ├── Makefile │ └── .gitignore ├── udev │ ├── Makefile │ ├── ata_id │ │ └── Makefile │ ├── cdrom_id │ │ └── Makefile │ ├── collect │ │ └── Makefile │ ├── mtd_probe │ │ └── Makefile │ ├── net │ │ ├── Makefile │ │ └── .gitignore │ ├── scsi_id │ │ ├── Makefile │ │ ├── .gitignore │ │ └── README │ ├── v4l_id │ │ └── Makefile │ ├── udev.conf │ ├── udev.pc.in │ ├── .gitignore │ └── .vimrc ├── ac-power │ └── Makefile ├── activate │ └── Makefile ├── analyze │ ├── Makefile │ └── .gitignore ├── backlight │ └── Makefile ├── basic │ ├── Makefile │ ├── .gitignore │ └── siphash24.h ├── binfmt │ └── Makefile ├── cgtop │ └── Makefile ├── coredump │ ├── Makefile │ └── coredump.conf ├── delta │ └── Makefile ├── escape │ └── Makefile ├── firstboot │ └── Makefile ├── hostname │ ├── Makefile │ ├── .gitignore │ └── org.freedesktop.hostname1.service ├── import │ ├── Makefile │ ├── .gitignore │ ├── import-pubring.gpg │ └── org.freedesktop.import1.service ├── initctl │ └── Makefile ├── journal │ ├── Makefile │ ├── .gitignore │ └── lookup3.h ├── libudev │ ├── Makefile │ ├── .gitignore │ └── libudev.pc.in ├── locale │ ├── Makefile │ ├── .gitignore │ ├── language-fallback-map │ └── org.freedesktop.locale1.service ├── login │ ├── Makefile │ ├── .gitignore │ ├── systemd-user.m4 │ ├── pam_systemd.sym │ ├── org.freedesktop.login1.service │ └── 73-seat-late.rules.in ├── machine │ ├── Makefile │ ├── .gitignore │ └── org.freedesktop.machine1.service ├── network │ ├── Makefile │ ├── .gitignore │ ├── org.freedesktop.network1.service │ └── networkd-gperf.gperf ├── notify │ └── Makefile ├── nspawn │ ├── Makefile │ └── .gitignore ├── resolve │ ├── Makefile │ ├── test-data │ │ ├── root.pkts │ │ ├── fake-caa.pkts │ │ ├── gandi.net.pkts │ │ ├── google.com.pkts │ │ ├── kyhwana.org.pkts │ │ ├── teamits.com.pkts │ │ ├── fedoraproject.org.pkts │ │ ├── zbyszek@fedoraproject.org.pkts │ │ ├── _443._tcp.fedoraproject.org.pkts │ │ ├── _openpgpkey.fedoraproject.org.pkts │ │ └── sw1a1aa-sw1a2aa-sw1a2ab-sw1a2ac.find.me.uk.pkts │ ├── .gitignore │ ├── org.freedesktop.resolve1.service │ └── resolved.conf.in ├── rfkill │ └── Makefile ├── shared │ └── Makefile ├── sleep │ └── Makefile ├── sysctl │ └── Makefile ├── systemctl │ └── Makefile ├── systemd │ └── Makefile ├── sysusers │ └── Makefile ├── timedate │ ├── Makefile │ ├── .gitignore │ └── org.freedesktop.timedate1.service ├── timesync │ ├── Makefile │ ├── .gitignore │ ├── timesyncd-gperf.gperf │ └── timesyncd.conf.in ├── tmpfiles │ └── Makefile ├── vconsole │ ├── Makefile │ ├── .gitignore │ └── 90-vconsole.rules.in ├── ask-password │ └── Makefile ├── cgroups-agent │ └── Makefile ├── cryptsetup │ └── Makefile ├── detect-virt │ └── Makefile ├── journal-remote │ ├── Makefile │ ├── .gitignore │ ├── journal-upload.conf.in │ └── journal-remote.conf.in ├── kernel-install │ ├── Makefile │ └── 50-depmod.install ├── libsystemd │ ├── Makefile │ ├── sd-login │ │ └── Makefile │ ├── sd-path │ │ └── Makefile │ ├── .gitignore │ ├── sd-bus │ │ └── Makefile │ ├── sd-daemon │ │ └── Makefile │ ├── sd-device │ │ └── Makefile │ ├── sd-event │ │ └── Makefile │ ├── sd-hwdb │ │ └── Makefile │ ├── sd-id128 │ │ └── Makefile │ ├── sd-netlink │ │ └── Makefile │ ├── sd-network │ │ └── Makefile │ ├── sd-resolve │ │ └── Makefile │ ├── sd-utf8 │ │ └── Makefile │ └── libsystemd.pc.in ├── modules-load │ └── Makefile ├── nss-myhostname │ ├── Makefile │ └── nss-myhostname.sym ├── nss-mymachines │ ├── Makefile │ └── nss-mymachines.sym ├── nss-resolve │ ├── Makefile │ └── nss-resolve.sym ├── quotacheck │ └── Makefile ├── random-seed │ └── Makefile ├── remount-fs │ └── Makefile ├── reply-password │ └── Makefile ├── socket-proxy │ └── Makefile ├── sysv-generator │ └── Makefile ├── update-done │ └── Makefile ├── update-utmp │ └── Makefile ├── user-sessions │ └── Makefile ├── dbus1-generator │ └── Makefile ├── debug-generator │ └── Makefile ├── fstab-generator │ └── Makefile ├── getty-generator │ └── Makefile ├── gpt-auto-generator │ └── Makefile ├── hibernate-resume │ └── Makefile ├── libsystemd-network │ └── Makefile ├── machine-id-setup │ └── Makefile ├── rc-local-generator │ └── Makefile ├── system-update-generator │ └── Makefile ├── tty-ask-password-agent │ └── Makefile └── .gitignore ├── catalog └── Makefile ├── network ├── Makefile ├── 99-default.link ├── 80-container-host0.network ├── 80-container-vz.network └── 80-container-ve.network ├── rules ├── Makefile ├── .gitignore ├── 60-drm.rules ├── 75-probe_mtd.rules ├── 80-net-setup-link.rules ├── 64-btrfs.rules ├── 75-net-description.rules ├── 60-block.rules ├── 80-drivers.rules ├── 60-persistent-alsa.rules ├── 70-mouse.rules └── 60-evdev.rules ├── sysctl.d ├── Makefile ├── .gitignore └── 50-coredump.conf.in ├── test ├── loopy2.service ├── loopy4.service ├── basic.target ├── sockets.target ├── sysinit.target ├── timers.target ├── shutdown.target ├── TEST-03-JOBS │ └── Makefile ├── test-path │ ├── basic.target │ ├── paths.target │ ├── path-changed.service │ ├── path-exists.service │ ├── path-existsglob.service │ ├── path-modified.service │ ├── sysinit.target │ ├── path-makedirectory.service │ ├── path-directorynotempty.service │ ├── path-mycustomunit.service │ ├── path-service.service │ ├── path-exists.path │ ├── path-changed.path │ ├── path-modified.path │ ├── path-existsglob.path │ ├── path-directorynotempty.path │ ├── path-unit.path │ └── path-makedirectory.path ├── TEST-02-CRYPTSETUP │ └── Makefile ├── TEST-04-JOURNAL │ └── Makefile ├── TEST-05-RLIMITS │ ├── Makefile │ └── test-rlimits.sh ├── TEST-06-SELINUX │ ├── Makefile │ ├── systemd_test.if │ └── test-selinux-checks.sh ├── TEST-07-ISSUE-1981 │ ├── Makefile │ └── test-segfault.sh ├── TEST-08-ISSUE-2730 │ └── Makefile ├── TEST-09-ISSUE-2691 │ └── Makefile ├── TEST-10-ISSUE-2467 │ └── Makefile ├── TEST-11-ISSUE-3166 │ └── Makefile ├── TEST-12-ISSUE-3171 │ └── Makefile ├── loopy.service ├── .gitignore ├── splash.bmp ├── sys.tar.xz ├── f.service ├── parent.slice ├── loopy3.service ├── b.service ├── h.service ├── parent-deep.slice ├── c.service ├── g.service ├── loopy.service.d │ └── compat.conf ├── hello.service ├── sleep.service ├── a.service ├── sched_rr_ok.service ├── daughter.service ├── sched_idle_ok.service ├── sched_idle_bad.service ├── d.service ├── e.service ├── grandchild.service ├── son.service ├── testsuite.target ├── hello-after-sleep.target ├── test-execute │ ├── exec-user.service │ ├── exec-group.service │ ├── exec-ignoresigpipe-no.service │ ├── exec-ignoresigpipe-yes.service │ ├── exec-privatedevices-no.service │ ├── exec-user-nfsnobody.service │ ├── exec-group-nfsnobody.service │ ├── exec-privatedevices-yes.service │ ├── exec-systemcallfilter-not-failing2.service │ ├── exec-privatetmp-no.service │ ├── exec-privatetmp-yes.service │ ├── exec-personality-s390.service │ ├── exec-personality-x86.service │ ├── exec-personality-x86-64.service │ ├── exec-spec-interpolation.service │ ├── exec-privatenetwork-yes.service │ ├── exec-systemcallerrornumber.service │ ├── exec-oomscoreadjust-negative.service │ ├── exec-oomscoreadjust-positive.service │ ├── exec-ioschedulingclass-idle.service │ ├── exec-ioschedulingclass-none.service │ ├── exec-runtimedirectory.service │ ├── exec-workingdirectory.service │ ├── exec-ioschedulingclass-realtime.service │ ├── exec-umask-default.service │ ├── exec-umask-0177.service │ ├── exec-ioschedulingclass-best-effort.service │ ├── exec-systemcallfilter-failing2.service │ ├── exec-passenvironment.service │ ├── exec-capabilityboundingset-invert.service │ ├── exec-systemcallfilter-failing.service │ ├── exec-environment.service │ ├── exec-environmentfile.service │ ├── exec-capabilityambientset.service │ ├── exec-capabilityboundingset-simple.service │ ├── exec-capabilityambientset-nfsnobody.service │ ├── exec-capabilityboundingset-reset.service │ ├── exec-environment-multiple.service │ ├── exec-runtimedirectory-mode.service │ ├── exec-environment-empty.service │ ├── exec-systemcallfilter-not-failing.service │ ├── exec-passenvironment-repeated.service │ ├── exec-passenvironment-empty.service │ ├── exec-capabilityambientset-merge.service │ ├── exec-passenvironment-absent.service │ ├── exec-capabilityboundingset-merge.service │ ├── exec-capabilityambientset-merge-nfsnobody.service │ ├── exec-systemcallfilter-system-user.service │ ├── exec-systemcallfilter-system-user-nfsnobody.service │ ├── exec-runtimedirectory-owner.service │ └── exec-runtimedirectory-owner-nfsnobody.service ├── unstoppable.service ├── sched_rr_bad.service ├── sched_rr_change.service ├── end.service ├── TEST-01-BASIC │ └── Makefile ├── bus-policy │ ├── hello.conf │ ├── signals.conf │ ├── check-own-rules.conf │ ├── methods.conf │ └── ownerships.conf ├── Makefile └── mocks │ └── fsck ├── units ├── Makefile ├── user │ ├── Makefile │ ├── .gitignore │ ├── default.target │ ├── basic.target │ ├── exit.target │ └── systemd-exit.service.in ├── paths.target ├── swap.target ├── sockets.target ├── busnames.target ├── sigpwr.target ├── cryptsetup.target ├── printer.target ├── bluetooth.target ├── smartcard.target ├── sound.target ├── user.slice ├── time-sync.target ├── cryptsetup-pre.target ├── local-fs-pre.target ├── remote-fs-pre.target ├── x-.slice ├── machine.slice ├── shutdown.target ├── slices.target ├── timers.target ├── umount.target ├── sleep.target ├── systemd-journal-remote.socket ├── emergency.target ├── final.target ├── suspend.target ├── system.slice ├── getty.target ├── hibernate.target ├── sysinit.target ├── network-pre.target ├── network-online.target ├── systemd-tmpfiles-clean.timer ├── hybrid-sleep.target ├── network.target ├── nss-user-lookup.target ├── systemd-journal-gatewayd.socket ├── org.freedesktop.import1.busname ├── multi-user.target ├── remote-fs.target ├── rescue.target ├── var-lib-machines.mount ├── halt.target ├── rpcbind.target ├── systemd-initctl.service.in ├── org.freedesktop.systemd1.busname ├── exit.target ├── kexec.target ├── local-fs.target ├── nss-lookup.target ├── systemd-coredump.socket ├── systemd-exit.service.in ├── systemd-suspend.service.in ├── initrd-root-device.target ├── systemd-hibernate.service.in ├── initrd-root-fs.target ├── machines.target ├── systemd-initctl.socket ├── systemd-hybrid-sleep.service.in ├── org.freedesktop.timedate1.busname ├── graphical.target ├── initrd-fs.target ├── reboot.target ├── systemd-halt.service.in ├── user@.service.m4.in ├── org.freedesktop.locale1.busname ├── org.freedesktop.machine1.busname ├── systemd-reboot.service.in ├── org.freedesktop.hostname1.busname ├── poweroff.target ├── systemd-kexec.service.in ├── systemd-poweroff.service.in ├── quotaon.service.in ├── system-update.target ├── systemd-ask-password-wall.path ├── systemd-udevd-kernel.socket ├── systemd-fsck-root.service.in ├── systemd-udevd-control.socket ├── halt-local.service.in ├── org.freedesktop.login1.busname ├── systemd-user-sessions.service.in ├── proc-sys-fs-binfmt_misc.mount ├── systemd-networkd.socket ├── kmod-static-nodes.service.in ├── systemd-journald-audit.socket ├── systemd-rfkill.socket ├── systemd-tmpfiles-clean.service.in ├── dev-mqueue.mount ├── systemd-quotacheck.service.in ├── systemd-vconsole-setup.service.in ├── initrd-cleanup.service.in ├── systemd-fsck@.service.in ├── tmp.mount.m4 ├── ldconfig.service ├── systemd-hibernate-resume@.service.in ├── systemd-update-done.service.in ├── systemd-ask-password-console.path ├── initrd-switch-root.service.in ├── sys-kernel-debug.mount ├── systemd-sysctl.service.in ├── dev-hugepages.mount ├── systemd-ask-password-console.service.in ├── systemd-timedated.service.in ├── initrd-switch-root.target ├── initrd-udevadm-cleanup-db.service.in ├── systemd-ask-password-wall.service.in ├── systemd-sysusers.service.in ├── org.freedesktop.network1.busname ├── rc-local.service.in ├── systemd-tmpfiles-setup.service.in ├── proc-sys-fs-binfmt_misc.automount ├── initrd.target ├── systemd-journal-catalog-update.service.in ├── systemd-localed.service.in ├── systemd-rfkill.service.in ├── systemd-networkd-wait-online.service.in ├── sys-fs-fuse-connections.mount ├── sys-kernel-config.mount └── systemd-machine-id-commit.service.in ├── system-preset └── Makefile ├── sysusers.d ├── Makefile ├── .gitignore ├── systemd-remote.conf.m4 └── systemd.conf.m4 ├── tmpfiles.d ├── Makefile ├── .gitignore ├── home.conf ├── systemd-nologin.conf ├── var.conf ├── systemd-remote.conf ├── x11.conf ├── tmp.conf └── etc.conf.m4 ├── shell-completion ├── Makefile ├── bash │ ├── Makefile │ └── .gitignore └── zsh │ ├── Makefile │ ├── .gitignore │ ├── _sd_hosts_or_user_at_host │ ├── _sd_outputmodes │ ├── _sd_unit_files │ ├── _sd_machines │ ├── _systemd-delta │ ├── _kernel-install │ └── _systemd-tmpfiles ├── .gitattributes ├── coccinelle ├── mfree.cocci ├── strjoina.cocci ├── safe_close-no-if.cocci ├── strempty.cocci ├── xsprintf.cocci ├── while-true.cocci ├── no-if-assignments.cocci ├── safe_close.cocci ├── safe_fclose.cocci ├── strv_free.cocci ├── safe_closedir.cocci └── empty-if.cocci ├── m4 ├── .gitignore └── arch.m4 ├── po ├── .gitignore ├── LINGUAS ├── POTFILES.in └── POTFILES.skip ├── factory └── etc │ ├── nsswitch.conf │ └── pam.d │ ├── other │ └── system-auth ├── xorg └── 50-systemd-user.sh ├── .editorconfig ├── tools └── check-includes.pl ├── .travis.yml └── .github └── ISSUE_TEMPLATE.md /docs/.gitignore: -------------------------------------------------------------------------------- 1 | /html 2 | -------------------------------------------------------------------------------- /docs/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /hwdb/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /man/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /src/boot/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/cgls/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/core/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/fsck/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/hwdb/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/path/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/run/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/test/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /catalog/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /network/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /rules/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /src/ac-power/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/activate/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/analyze/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/backlight/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/basic/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/binfmt/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/cgtop/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/coredump/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/delta/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/escape/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/firstboot/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/hostname/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/import/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/initctl/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/journal/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libudev/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/locale/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/login/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/machine/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/network/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/notify/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/nspawn/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/resolve/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/rfkill/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/shared/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/sleep/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/sysctl/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/systemctl/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/systemd/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/sysusers/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/timedate/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/timesync/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/tmpfiles/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/vconsole/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /sysctl.d/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /test/loopy2.service: -------------------------------------------------------------------------------- 1 | loopy.service -------------------------------------------------------------------------------- /test/loopy4.service: -------------------------------------------------------------------------------- 1 | loopy3.service -------------------------------------------------------------------------------- /units/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /docs/sysvinit/.gitignore: -------------------------------------------------------------------------------- 1 | /README 2 | -------------------------------------------------------------------------------- /docs/var-log/.gitignore: -------------------------------------------------------------------------------- 1 | /README 2 | -------------------------------------------------------------------------------- /rules/.gitignore: -------------------------------------------------------------------------------- 1 | /99-systemd.rules 2 | -------------------------------------------------------------------------------- /src/ask-password/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/cgroups-agent/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/cryptsetup/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/detect-virt/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/journal-remote/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/kernel-install/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libsystemd/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libudev/.gitignore: -------------------------------------------------------------------------------- 1 | /libudev.pc 2 | -------------------------------------------------------------------------------- /src/modules-load/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/nss-myhostname/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/nss-mymachines/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/nss-resolve/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/quotacheck/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/random-seed/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/remount-fs/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/reply-password/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/socket-proxy/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/sysv-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/ata_id/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/cdrom_id/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/collect/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/mtd_probe/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/net/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/udev/scsi_id/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/v4l_id/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/update-done/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/update-utmp/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/user-sessions/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /system-preset/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /sysusers.d/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /test/basic.target: -------------------------------------------------------------------------------- 1 | ../units/basic.target -------------------------------------------------------------------------------- /tmpfiles.d/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /units/user/Makefile: -------------------------------------------------------------------------------- 1 | ../../src/Makefile -------------------------------------------------------------------------------- /docs/sysvinit/Makefile: -------------------------------------------------------------------------------- 1 | ../../src/Makefile -------------------------------------------------------------------------------- /docs/var-log/Makefile: -------------------------------------------------------------------------------- 1 | ../../src/Makefile -------------------------------------------------------------------------------- /shell-completion/Makefile: -------------------------------------------------------------------------------- 1 | ../src/Makefile -------------------------------------------------------------------------------- /shell-completion/bash/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /shell-completion/zsh/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/analyze/.gitignore: -------------------------------------------------------------------------------- 1 | /systemd-analyze 2 | -------------------------------------------------------------------------------- /src/dbus1-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/debug-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/fstab-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/getty-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/gpt-auto-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/hibernate-resume/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libsystemd-network/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-login/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-path/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/machine-id-setup/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/nspawn/.gitignore: -------------------------------------------------------------------------------- 1 | /nspawn-gperf.c 2 | -------------------------------------------------------------------------------- /src/rc-local-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /sysctl.d/.gitignore: -------------------------------------------------------------------------------- 1 | /50-coredump.conf 2 | -------------------------------------------------------------------------------- /test/sockets.target: -------------------------------------------------------------------------------- 1 | ../units/sockets.target -------------------------------------------------------------------------------- /test/sysinit.target: -------------------------------------------------------------------------------- 1 | ../units/sysinit.target -------------------------------------------------------------------------------- /test/timers.target: -------------------------------------------------------------------------------- 1 | ../units/timers.target -------------------------------------------------------------------------------- /shell-completion/bash/.gitignore: -------------------------------------------------------------------------------- 1 | /systemctl 2 | -------------------------------------------------------------------------------- /shell-completion/zsh/.gitignore: -------------------------------------------------------------------------------- 1 | /_systemctl 2 | -------------------------------------------------------------------------------- /src/libsystemd/.gitignore: -------------------------------------------------------------------------------- 1 | /libsystemd.pc 2 | -------------------------------------------------------------------------------- /src/libsystemd/sd-bus/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-daemon/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-device/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-event/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-hwdb/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-id128/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-netlink/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-network/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-resolve/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/libsystemd/sd-utf8/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile -------------------------------------------------------------------------------- /src/system-update-generator/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/test/.gitignore: -------------------------------------------------------------------------------- 1 | test-hashmap-ordered.c 2 | -------------------------------------------------------------------------------- /src/tty-ask-password-agent/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile -------------------------------------------------------------------------------- /src/udev/net/.gitignore: -------------------------------------------------------------------------------- 1 | /link-config-gperf.c 2 | -------------------------------------------------------------------------------- /src/vconsole/.gitignore: -------------------------------------------------------------------------------- 1 | /90-vconsole.rules 2 | -------------------------------------------------------------------------------- /test/shutdown.target: -------------------------------------------------------------------------------- 1 | ../units/shutdown.target -------------------------------------------------------------------------------- /units/user/.gitignore: -------------------------------------------------------------------------------- 1 | /systemd-exit.service 2 | -------------------------------------------------------------------------------- /src/udev/scsi_id/.gitignore: -------------------------------------------------------------------------------- 1 | scsi_id_version.h 2 | -------------------------------------------------------------------------------- /test/TEST-03-JOBS/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/test-path/basic.target: -------------------------------------------------------------------------------- 1 | ../../units/basic.target -------------------------------------------------------------------------------- /test/test-path/paths.target: -------------------------------------------------------------------------------- 1 | ../../units/paths.target -------------------------------------------------------------------------------- /tmpfiles.d/.gitignore: -------------------------------------------------------------------------------- 1 | /etc.conf 2 | /systemd.conf 3 | -------------------------------------------------------------------------------- /src/boot/efi/.gitignore: -------------------------------------------------------------------------------- 1 | /systemd_boot.so 2 | /stub.so 3 | -------------------------------------------------------------------------------- /src/import/.gitignore: -------------------------------------------------------------------------------- 1 | /org.freedesktop.import1.policy 2 | -------------------------------------------------------------------------------- /src/locale/.gitignore: -------------------------------------------------------------------------------- 1 | org.freedesktop.locale1.policy 2 | -------------------------------------------------------------------------------- /test/TEST-02-CRYPTSETUP/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-04-JOURNAL/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-05-RLIMITS/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-06-SELINUX/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-07-ISSUE-1981/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-08-ISSUE-2730/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-09-ISSUE-2691/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-10-ISSUE-2467/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-11-ISSUE-3166/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/TEST-12-ISSUE-3171/Makefile: -------------------------------------------------------------------------------- 1 | ../TEST-01-BASIC/Makefile -------------------------------------------------------------------------------- /test/loopy.service: -------------------------------------------------------------------------------- 1 | [Service] 2 | ExecStart=/bin/true 3 | -------------------------------------------------------------------------------- /test/test-path/path-changed.service: -------------------------------------------------------------------------------- 1 | path-service.service -------------------------------------------------------------------------------- /test/test-path/path-exists.service: -------------------------------------------------------------------------------- 1 | path-service.service -------------------------------------------------------------------------------- /test/test-path/path-existsglob.service: -------------------------------------------------------------------------------- 1 | path-service.service -------------------------------------------------------------------------------- /test/test-path/path-modified.service: -------------------------------------------------------------------------------- 1 | path-service.service -------------------------------------------------------------------------------- /test/test-path/sysinit.target: -------------------------------------------------------------------------------- 1 | ../../units/sysinit.target -------------------------------------------------------------------------------- /src/hostname/.gitignore: -------------------------------------------------------------------------------- 1 | org.freedesktop.hostname1.policy 2 | -------------------------------------------------------------------------------- /src/machine/.gitignore: -------------------------------------------------------------------------------- 1 | /org.freedesktop.machine1.policy 2 | -------------------------------------------------------------------------------- /src/timedate/.gitignore: -------------------------------------------------------------------------------- 1 | org.freedesktop.timedate1.policy 2 | -------------------------------------------------------------------------------- /test/test-path/path-makedirectory.service: -------------------------------------------------------------------------------- 1 | path-service.service -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.[ch] whitespace=tab-in-indent,trailing-space 2 | -------------------------------------------------------------------------------- /src/timesync/.gitignore: -------------------------------------------------------------------------------- 1 | /timesyncd.conf 2 | /timesyncd-gperf.c 3 | -------------------------------------------------------------------------------- /test/.gitignore: -------------------------------------------------------------------------------- 1 | .testdir 2 | test.log 3 | /dev 4 | /run 5 | /sys 6 | -------------------------------------------------------------------------------- /test/test-path/path-directorynotempty.service: -------------------------------------------------------------------------------- 1 | path-service.service -------------------------------------------------------------------------------- /src/core/.gitignore: -------------------------------------------------------------------------------- 1 | /macros.systemd 2 | /triggers.systemd 3 | /systemd.pc 4 | -------------------------------------------------------------------------------- /src/journal-remote/.gitignore: -------------------------------------------------------------------------------- 1 | /journal-remote.conf 2 | /journal-upload.conf 3 | -------------------------------------------------------------------------------- /src/udev/udev.conf: -------------------------------------------------------------------------------- 1 | # see udev.conf(5) for details 2 | 3 | #udev_log="info" 4 | -------------------------------------------------------------------------------- /sysusers.d/.gitignore: -------------------------------------------------------------------------------- 1 | /basic.conf 2 | /systemd.conf 3 | /systemd-remote.conf 4 | -------------------------------------------------------------------------------- /test/splash.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/test/splash.bmp -------------------------------------------------------------------------------- /test/sys.tar.xz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/test/sys.tar.xz -------------------------------------------------------------------------------- /test/f.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=F 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | -------------------------------------------------------------------------------- /test/parent.slice: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Parent Slice 3 | 4 | [Slice] 5 | IOWeight=200 6 | -------------------------------------------------------------------------------- /hwdb/.gitignore: -------------------------------------------------------------------------------- 1 | /pci.ids 2 | /usb.ids 3 | /ma-large.txt 4 | /ma-medium.txt 5 | /ma-small.txt 6 | -------------------------------------------------------------------------------- /src/network/.gitignore: -------------------------------------------------------------------------------- 1 | /networkd-network-gperf.c 2 | /networkd-netdev-gperf.c 3 | /networkd-gperf.c 4 | -------------------------------------------------------------------------------- /test/loopy3.service: -------------------------------------------------------------------------------- 1 | [Service] 2 | ExecStart=/bin/true 3 | 4 | [Unit] 5 | Conflicts=loopy4.service 6 | -------------------------------------------------------------------------------- /coccinelle/mfree.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression p; 3 | @@ 4 | - free(p); 5 | - p = NULL; 6 | + p = mfree(p); 7 | -------------------------------------------------------------------------------- /src/import/import-pubring.gpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/import/import-pubring.gpg -------------------------------------------------------------------------------- /test/b.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=B 3 | Wants=f.service 4 | 5 | [Service] 6 | ExecStart=/bin/true 7 | -------------------------------------------------------------------------------- /test/h.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=H 3 | Wants=g.service 4 | 5 | [Service] 6 | ExecStart=/bin/true 7 | -------------------------------------------------------------------------------- /test/parent-deep.slice: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Deeper Parent Slice 3 | 4 | [Slice] 5 | MemoryLimit=3G 6 | -------------------------------------------------------------------------------- /m4/.gitignore: -------------------------------------------------------------------------------- 1 | intltool.m4 2 | libtool.m4 3 | ltoptions.m4 4 | ltsugar.m4 5 | ltversion.m4 6 | lt~obsolete.m4 7 | -------------------------------------------------------------------------------- /po/.gitignore: -------------------------------------------------------------------------------- 1 | POTFILES 2 | Makefile.in.in 3 | .intltool-merge-cache 4 | Makefile 5 | systemd.pot 6 | /*.gmo 7 | -------------------------------------------------------------------------------- /src/resolve/test-data/root.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/root.pkts -------------------------------------------------------------------------------- /src/udev/udev.pc.in: -------------------------------------------------------------------------------- 1 | Name: udev 2 | Description: udev 3 | Version: @VERSION@ 4 | 5 | udevdir=@udevlibexecdir@ 6 | -------------------------------------------------------------------------------- /test/c.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=C 3 | Requires=a.service 4 | 5 | [Service] 6 | ExecStart=/bin/true 7 | -------------------------------------------------------------------------------- /test/g.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=G 3 | Conflicts=e.service 4 | 5 | [Service] 6 | ExecStart=/bin/true 7 | -------------------------------------------------------------------------------- /test/loopy.service.d/compat.conf: -------------------------------------------------------------------------------- 1 | [Unit] 2 | BindsTo=loopy2.service 3 | 4 | [Install] 5 | Also=loopy2.service 6 | -------------------------------------------------------------------------------- /man/.gitignore: -------------------------------------------------------------------------------- 1 | /systemd.directives.xml 2 | /systemd.index.xml 3 | /*.[13578] 4 | /*.html 5 | /custom-entities.ent 6 | -------------------------------------------------------------------------------- /network/99-default.link: -------------------------------------------------------------------------------- 1 | [Link] 2 | NamePolicy=kernel database onboard slot path 3 | MACAddressPolicy=persistent 4 | -------------------------------------------------------------------------------- /test/hello.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Hello World 3 | 4 | [Service] 5 | ExecStart=/bin/echo "Hello World" 6 | -------------------------------------------------------------------------------- /src/journal/.gitignore: -------------------------------------------------------------------------------- 1 | /journald-gperf.c 2 | /libsystemd-journal.pc 3 | /audit_type-list.txt 4 | /audit_type-*-name.* 5 | -------------------------------------------------------------------------------- /src/resolve/test-data/fake-caa.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/fake-caa.pkts -------------------------------------------------------------------------------- /src/resolve/test-data/gandi.net.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/gandi.net.pkts -------------------------------------------------------------------------------- /src/resolve/test-data/google.com.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/google.com.pkts -------------------------------------------------------------------------------- /src/resolve/test-data/kyhwana.org.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/kyhwana.org.pkts -------------------------------------------------------------------------------- /src/resolve/test-data/teamits.com.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/teamits.com.pkts -------------------------------------------------------------------------------- /src/udev/.gitignore: -------------------------------------------------------------------------------- 1 | /udev.pc 2 | /keyboard-keys-from-name.gperf 3 | /keyboard-keys-from-name.h 4 | /keyboard-keys-list.txt 5 | -------------------------------------------------------------------------------- /test/sleep.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Sleep for 1 minute 3 | 4 | [Service] 5 | Type=oneshot 6 | ExecStart=/bin/sleep 60 7 | -------------------------------------------------------------------------------- /test/a.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=A 3 | Requires=b.service 4 | Before=b.service 5 | 6 | [Service] 7 | ExecStart=/bin/true 8 | -------------------------------------------------------------------------------- /src/resolve/test-data/fedoraproject.org.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/fedoraproject.org.pkts -------------------------------------------------------------------------------- /coccinelle/strjoina.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression n, m; 3 | expression list s; 4 | @@ 5 | - n = strjoina(m, s, NULL); 6 | + n = strjoina(m, s); 7 | -------------------------------------------------------------------------------- /test/sched_rr_ok.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Default prio for RR 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | CPUSchedulingPolicy=rr 7 | -------------------------------------------------------------------------------- /shell-completion/zsh/_sd_hosts_or_user_at_host: -------------------------------------------------------------------------------- 1 | #autoload 2 | 3 | _alternative \ 4 | 'users-hosts:: _user_at_host' \ 5 | 'hosts:: _hosts' 6 | -------------------------------------------------------------------------------- /src/udev/.vimrc: -------------------------------------------------------------------------------- 1 | " 'set exrc' in ~/.vimrc will read .vimrc from the current directory 2 | set tabstop=8 3 | set shiftwidth=8 4 | set expandtab 5 | -------------------------------------------------------------------------------- /test/daughter.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Daughter Service 3 | 4 | [Service] 5 | Slice=parent.slice 6 | Type=oneshot 7 | ExecStart=/bin/true 8 | -------------------------------------------------------------------------------- /test/sched_idle_ok.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Sched idle with prio 0 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | CPUSchedulingPriority=0 7 | -------------------------------------------------------------------------------- /coccinelle/safe_close-no-if.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression fd; 3 | @@ 4 | - if (fd >= 0) { 5 | - fd = safe_close(fd); 6 | - } 7 | + fd = safe_close(fd); 8 | -------------------------------------------------------------------------------- /src/login/.gitignore: -------------------------------------------------------------------------------- 1 | /logind-gperf.c 2 | /logind.conf 3 | /org.freedesktop.login1.policy 4 | /71-seat.rules 5 | /73-seat-late.rules 6 | /systemd-user 7 | -------------------------------------------------------------------------------- /src/resolve/test-data/zbyszek@fedoraproject.org.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/zbyszek@fedoraproject.org.pkts -------------------------------------------------------------------------------- /test/sched_idle_bad.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Bad sched priority for Idle 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | CPUSchedulingPriority=1 7 | -------------------------------------------------------------------------------- /test/test-path/path-mycustomunit.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Service Test Path Unit= 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | Type=oneshot 7 | -------------------------------------------------------------------------------- /test/test-path/path-service.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Service Test for Path units 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | Type=oneshot 7 | -------------------------------------------------------------------------------- /hwdb/20-net-ifname.hwdb: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | 3 | # Dell iDRAC Virtual USB NIC 4 | usb:v413CpA102* 5 | ID_NET_NAME_FROM_DATABASE=idrac 6 | -------------------------------------------------------------------------------- /src/resolve/test-data/_443._tcp.fedoraproject.org.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/_443._tcp.fedoraproject.org.pkts -------------------------------------------------------------------------------- /test/d.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=D:Cyclic 3 | After=b.service 4 | Before=a.service 5 | Requires=a.service 6 | 7 | [Service] 8 | ExecStart=/bin/true 9 | -------------------------------------------------------------------------------- /test/e.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=E:Cyclic 3 | After=b.service 4 | Before=a.service 5 | Wants=a.service 6 | 7 | [Service] 8 | ExecStart=/bin/true 9 | -------------------------------------------------------------------------------- /test/grandchild.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Grandchild Service 3 | 4 | [Service] 5 | Slice=parent-deep.slice 6 | Type=oneshot 7 | ExecStart=/bin/true 8 | -------------------------------------------------------------------------------- /test/son.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Son Service 3 | 4 | [Service] 5 | Slice=parent.slice 6 | Type=oneshot 7 | ExecStart=/bin/true 8 | CPUShares=100 9 | -------------------------------------------------------------------------------- /src/resolve/test-data/_openpgpkey.fedoraproject.org.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/_openpgpkey.fedoraproject.org.pkts -------------------------------------------------------------------------------- /coccinelle/strempty.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression s; 3 | @@ 4 | - s ?: "" 5 | + strempty(s) 6 | @@ 7 | expression s; 8 | @@ 9 | - s ? s : "" 10 | + strempty(s) 11 | -------------------------------------------------------------------------------- /coccinelle/xsprintf.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression e, fmt; 3 | expression list vaargs; 4 | @@ 5 | - snprintf(e, sizeof(e), fmt, vaargs); 6 | + xsprintf(e, fmt, vaargs); 7 | -------------------------------------------------------------------------------- /factory/etc/nsswitch.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | 3 | passwd: files 4 | shadow: files 5 | group: files 6 | hosts: files mymachines resolve myhostname 7 | -------------------------------------------------------------------------------- /src/resolve/.gitignore: -------------------------------------------------------------------------------- 1 | /resolved-gperf.c 2 | /resolved.conf 3 | /dns_type-from-name.gperf 4 | /dns_type-from-name.h 5 | /dns_type-list.txt 6 | /dns_type-to-name.h 7 | -------------------------------------------------------------------------------- /test/testsuite.target: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Testsuite target 3 | Requires=multi-user.target 4 | After=multi-user.target 5 | Conflicts=rescue.target 6 | AllowIsolate=yes 7 | -------------------------------------------------------------------------------- /test/test-path/path-exists.path: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test PathExists 3 | 4 | [Path] 5 | PathExists=/tmp/test-path_exists 6 | 7 | [Install] 8 | WantedBy=multi-user.target 9 | -------------------------------------------------------------------------------- /coccinelle/while-true.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | statement s; 3 | @@ 4 | - while (true) 5 | + for (;;) 6 | s 7 | @@ 8 | statement s; 9 | @@ 10 | - while (1) 11 | + for (;;) 12 | s 13 | -------------------------------------------------------------------------------- /rules/60-drm.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | ACTION!="remove", SUBSYSTEM=="drm", SUBSYSTEMS=="pci|usb|platform", IMPORT{builtin}="path_id" 4 | -------------------------------------------------------------------------------- /test/hello-after-sleep.target: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Sleep for a minute, then say hello. 3 | Wants=sleep.service hello.service 4 | After=sleep.service 5 | Before=hello.service 6 | -------------------------------------------------------------------------------- /test/test-execute/exec-user.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for User 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$USER" = "nobody"' 6 | Type=oneshot 7 | User=nobody 8 | -------------------------------------------------------------------------------- /test/test-path/path-changed.path: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test PathChanged 3 | 4 | [Path] 5 | PathChanged=/tmp/test-path_changed 6 | 7 | [Install] 8 | WantedBy=multi-user.target 9 | -------------------------------------------------------------------------------- /src/resolve/test-data/sw1a1aa-sw1a2aa-sw1a2ab-sw1a2ac.find.me.uk.pkts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NixOS/systemd/HEAD/src/resolve/test-data/sw1a1aa-sw1a2aa-sw1a2ab-sw1a2ac.find.me.uk.pkts -------------------------------------------------------------------------------- /test/test-path/path-modified.path: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test PathModified 3 | 4 | [Path] 5 | PathModified=/tmp/test-path_modified 6 | 7 | [Install] 8 | WantedBy=multi-user.target 9 | -------------------------------------------------------------------------------- /test/unstoppable.service: -------------------------------------------------------------------------------- 1 | [Service] 2 | Type=oneshot 3 | RemainAfterExit=yes 4 | ExecStart=/bin/echo "I'm unstoppable!" 5 | ExecStop=/bin/systemctl start --no-block unstoppable.service 6 | -------------------------------------------------------------------------------- /test/test-execute/exec-group.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Group 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$(id -n -g)" = "nobody"' 6 | Type=oneshot 7 | Group=nobody 8 | -------------------------------------------------------------------------------- /factory/etc/pam.d/other: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | 3 | auth include system-auth 4 | account include system-auth 5 | password include system-auth 6 | session include system-auth 7 | -------------------------------------------------------------------------------- /test/test-path/path-existsglob.path: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test PathExistsGlob 3 | 4 | [Path] 5 | PathExistsGlob=/tmp/test-path_existsglob* 6 | 7 | [Install] 8 | WantedBy=multi-user.target 9 | -------------------------------------------------------------------------------- /po/LINGUAS: -------------------------------------------------------------------------------- 1 | be 2 | be@latin 3 | bg 4 | da 5 | de 6 | el 7 | es 8 | fr 9 | gl 10 | hr 11 | hu 12 | it 13 | ko 14 | pl 15 | pt_BR 16 | ru 17 | sr 18 | sv 19 | tr 20 | uk 21 | zh_CN 22 | zh_TW 23 | -------------------------------------------------------------------------------- /test/test-execute/exec-ignoresigpipe-no.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for IgnoreSIGPIPE=no 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'kill -PIPE 0' 6 | Type=oneshot 7 | IgnoreSIGPIPE=no 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-ignoresigpipe-yes.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for IgnoreSIGPIPE=yes 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'kill -PIPE 0' 6 | Type=oneshot 7 | IgnoreSIGPIPE=yes 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-privatedevices-no.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PrivateDev=no 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test -c /dev/mem' 6 | Type=oneshot 7 | PrivateDevices=no 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-user-nfsnobody.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for User 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$USER" = "nfsnobody"' 6 | Type=oneshot 7 | User=nfsnobody 8 | -------------------------------------------------------------------------------- /test/sched_rr_bad.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Bad sched priority for RR 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | CPUSchedulingPolicy=rr 7 | CPUSchedulingPriority=0 8 | CPUSchedulingPriority=100 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-group-nfsnobody.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Group 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$(id -n -g)" = "nfsnobody"' 6 | Type=oneshot 7 | Group=nfsnobody 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-privatedevices-yes.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PrivateDev=yes 3 | 4 | [Service] 5 | ExecStart=/bin/sh -c 'test ! -c /dev/mem' 6 | Type=oneshot 7 | PrivateDevices=yes 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-systemcallfilter-not-failing2.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for SystemCallFilter 3 | 4 | [Service] 5 | ExecStart=/bin/echo "Foo bar" 6 | Type=oneshot 7 | SystemCallFilter= 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-privatetmp-no.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PrivateTmp=no 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test -f /tmp/test-exec_privatetmp' 6 | Type=oneshot 7 | PrivateTmp=no 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-privatetmp-yes.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PrivateTmp=yes 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test ! -f /tmp/test-exec_privatetmp' 6 | Type=oneshot 7 | PrivateTmp=yes 8 | -------------------------------------------------------------------------------- /test/test-path/path-directorynotempty.path: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test DirectoryNotEmpty 3 | 4 | [Path] 5 | DirectoryNotEmpty=/tmp/test-path_directorynotempty/ 6 | 7 | [Install] 8 | WantedBy=multi-user.target 9 | -------------------------------------------------------------------------------- /test/test-path/path-unit.path: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test Path Unit= 3 | 4 | [Path] 5 | PathExists=/tmp/test-path_unit 6 | Unit=path-mycustomunit.service 7 | 8 | [Install] 9 | WantedBy=multi-user.target 10 | -------------------------------------------------------------------------------- /src/.gitignore: -------------------------------------------------------------------------------- 1 | load-fragment-gperf-nulstr.c 2 | load-fragment-gperf.c 3 | load-fragment-gperf.gperf 4 | org.freedesktop.systemd1.policy.in 5 | org.freedesktop.systemd1.policy 6 | 99-systemd.rules 7 | *.gcno 8 | *.gcda 9 | -------------------------------------------------------------------------------- /src/udev/scsi_id/README: -------------------------------------------------------------------------------- 1 | scsi_id - generate a SCSI unique identifier for a given SCSI device 2 | 3 | Please send questions, comments or patches to or 4 | . 5 | -------------------------------------------------------------------------------- /test/test-execute/exec-personality-s390.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Personality=s390 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(uname -m); test "$$c" = "s390"' 6 | Type=oneshot 7 | Personality=s390 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-personality-x86.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Personality=x86 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(uname -m); test "$$c" = "i686"' 6 | Type=oneshot 7 | Personality=x86 8 | -------------------------------------------------------------------------------- /rules/75-probe_mtd.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | ACTION!="add", GOTO="mtd_probe_end" 4 | 5 | KERNEL=="mtd*ro", IMPORT{program}="mtd_probe $devnode" 6 | 7 | LABEL="mtd_probe_end" 8 | -------------------------------------------------------------------------------- /test/TEST-06-SELINUX/systemd_test.if: -------------------------------------------------------------------------------- 1 | template(`systemd_test_base_template', ` 2 | gen_require(` 3 | attribute systemd_test_domain_type; 4 | ') 5 | 6 | type $1_t, systemd_test_domain_type; 7 | domain_type($1_t) 8 | ') 9 | -------------------------------------------------------------------------------- /test/sched_rr_change.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Change prio 3 | 4 | [Service] 5 | ExecStart=/bin/true 6 | CPUSchedulingPolicy=rr 7 | CPUSchedulingPriority=1 8 | CPUSchedulingPriority=2 9 | CPUSchedulingPriority=99 10 | -------------------------------------------------------------------------------- /test/test-execute/exec-personality-x86-64.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Personality=x86-64 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(uname -m); test "$$c" = "x86_64"' 6 | Type=oneshot 7 | Personality=x86-64 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-spec-interpolation.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=https://github.com/systemd/systemd/issues/2637 3 | 4 | [Service] 5 | Type=oneshot 6 | ExecStart=/bin/sh -x -c "perl -e 'exit(!(qq{%%U} eq qq{\\x25U}))'" 7 | -------------------------------------------------------------------------------- /test/test-execute/exec-privatenetwork-yes.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PrivateNetwork 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'i=$$(ip link | grep ": " | grep -v ": lo:"); test -z "$$i"' 6 | Type=oneshot 7 | PrivateNetwork=yes 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-systemcallerrornumber.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for SystemCallErrorNumber 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'uname -a' 6 | Type=oneshot 7 | SystemCallFilter=~uname 8 | SystemCallErrorNumber=EACCES 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-oomscoreadjust-negative.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for OOMScoreAdjust 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(cat /proc/self/oom_score_adj); test "$$c" -eq -100' 6 | Type=oneshot 7 | OOMScoreAdjust=-100 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-oomscoreadjust-positive.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for OOMScoreAdjust 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(cat /proc/self/oom_score_adj); test "$$c" -eq 100' 6 | Type=oneshot 7 | OOMScoreAdjust=100 8 | -------------------------------------------------------------------------------- /xorg/50-systemd-user.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | systemctl --user import-environment DISPLAY XAUTHORITY 4 | 5 | if which dbus-update-activation-environment >/dev/null 2>&1; then 6 | dbus-update-activation-environment DISPLAY XAUTHORITY 7 | fi 8 | -------------------------------------------------------------------------------- /shell-completion/zsh/_sd_outputmodes: -------------------------------------------------------------------------------- 1 | #autoload 2 | 3 | local -a _output_opts 4 | _output_opts=(short short-iso short-precise short-monotonic verbose export json json-pretty json-sse cat) 5 | _describe -t output 'output mode' _output_opts || compadd "$@" 6 | -------------------------------------------------------------------------------- /test/test-execute/exec-ioschedulingclass-idle.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for IOSchedulingClass=idle 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(LC_ALL=C ionice); test "$${c%%:*}" = "idle"' 6 | Type=oneshot 7 | IOSchedulingClass=idle 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-ioschedulingclass-none.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for IOSchedulingClass=none 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(LC_ALL=C ionice); test "$${c%%:*}" = "none"' 6 | Type=oneshot 7 | IOSchedulingClass=none 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-runtimedirectory.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for RuntimeDirectory 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test -d /tmp/test-exec_runtimedirectory' 6 | Type=oneshot 7 | RuntimeDirectory=test-exec_runtimedirectory 8 | -------------------------------------------------------------------------------- /src/journal-remote/journal-upload.conf.in: -------------------------------------------------------------------------------- 1 | [Upload] 2 | # URL= 3 | # ServerKeyFile=@CERTIFICATEROOT@/private/journal-upload.pem 4 | # ServerCertificateFile=@CERTIFICATEROOT@/certs/journal-upload.pem 5 | # TrustedCertificateFile=@CERTIFICATEROOT@/ca/trusted.pem 6 | -------------------------------------------------------------------------------- /src/kernel-install/50-depmod.install: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- 3 | # ex: ts=8 sw=4 sts=4 et filetype=sh 4 | 5 | [[ $1 == "add" ]] || exit 0 6 | [[ $2 ]] || exit 1 7 | 8 | exec depmod -a "$2" 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-workingdirectory.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for WorkingDirectory 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$PWD" = "/tmp/test-exec_workingdirectory"' 6 | Type=oneshot 7 | WorkingDirectory=/tmp/test-exec_workingdirectory 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-ioschedulingclass-realtime.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for IOSchedulingClass=realtime 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(LC_ALL=C ionice); test "$${c%%:*}" = "realtime"' 6 | Type=oneshot 7 | IOSchedulingClass=realtime 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-umask-default.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for UMask default 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'touch /tmp/test-exec-umask; mode=$$(stat -c %%a /tmp/test-exec-umask); test "$$mode" = "644"' 6 | Type=oneshot 7 | PrivateTmp=yes 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-umask-0177.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for UMask 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'touch /tmp/test-exec-umask; mode=$$(stat -c %%a /tmp/test-exec-umask); test "$$mode" = "600"' 6 | Type=oneshot 7 | UMask=0177 8 | PrivateTmp=yes 9 | -------------------------------------------------------------------------------- /test/test-path/path-makedirectory.path: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test MakeDirectory & DirectoryMode 3 | 4 | [Path] 5 | DirectoryNotEmpty=/tmp/test-path_makedirectory/ 6 | MakeDirectory=yes 7 | DirectoryMode=0744 8 | 9 | [Install] 10 | WantedBy=multi-user.target 11 | -------------------------------------------------------------------------------- /test/test-execute/exec-ioschedulingclass-best-effort.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for IOSchedulingClass=best-effort 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(LC_ALL=C ionice); test "$${c%%:*}" = "best-effort"' 6 | Type=oneshot 7 | IOSchedulingClass=best-effort 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-systemcallfilter-failing2.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for SystemCallFilter 3 | 4 | [Service] 5 | ExecStart=/bin/echo "This should not be seen" 6 | Type=oneshot 7 | SystemCallFilter=~write open execve exit_group close mmap munmap fstat DONOTEXIST 8 | -------------------------------------------------------------------------------- /test/end.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=End the test 3 | After=testsuite.service 4 | OnFailure=poweroff.target 5 | OnFailureJobMode=replace-irreversibly 6 | 7 | [Service] 8 | Type=oneshot 9 | ExecStart=/bin/sh -x -c 'systemctl poweroff --no-block' 10 | TimeoutStartSec=5m 11 | -------------------------------------------------------------------------------- /test/test-execute/exec-passenvironment.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PassEnvironment 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$VAR1" = "word1 word2" && test "$$VAR2" = word3 && test "$$VAR3" = "\\$$word 5 6"' 6 | Type=oneshot 7 | PassEnvironment=VAR1 VAR2 VAR3 8 | -------------------------------------------------------------------------------- /src/journal-remote/journal-remote.conf.in: -------------------------------------------------------------------------------- 1 | [Remote] 2 | # Seal=false 3 | # SplitMode=host 4 | # ServerKeyFile=@CERTIFICATEROOT@/private/journal-remote.pem 5 | # ServerCertificateFile=@CERTIFICATEROOT@/certs/journal-remote.pem 6 | # TrustedCertificateFile=@CERTIFICATEROOT@/ca/trusted.pem 7 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityboundingset-invert.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for CapabilityBoundingSet 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(capsh --print | grep "^Bounding set .*cap_chown"); test -z "$$c"' 6 | Type=oneshot 7 | CapabilityBoundingSet=~CAP_CHOWN 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-systemcallfilter-failing.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for SystemCallFilter 3 | 4 | [Service] 5 | ExecStart=/bin/echo "This should not be seen" 6 | Type=oneshot 7 | SystemCallFilter=ioperm 8 | SystemCallFilter=~ioperm 9 | SystemCallFilter=ioperm 10 | -------------------------------------------------------------------------------- /shell-completion/zsh/_sd_unit_files: -------------------------------------------------------------------------------- 1 | #autoload 2 | 3 | _sd_unit_files() { 4 | local files expl 5 | files=( '*:files:->files' ) 6 | 7 | _description files expl 'unit file' 8 | _files "$expl[@]" -g '*.(automount|busname|device|mount|path|service|socket|swap|target|timer)' 9 | } 10 | -------------------------------------------------------------------------------- /test/test-execute/exec-environment.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Environment 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$VAR1" = "word1 word2" && test "$$VAR2" = word3 && test "$$VAR3" = "\\$$word 5 6"' 6 | Type=oneshot 7 | Environment="VAR1=word1 word2" VAR2=word3 "VAR3=$word 5 6" 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-environmentfile.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for EnvironmentFile 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$VAR1" = "word1 word2" && test "$$VAR2" = word3 && test "$$VAR3" = "\\$$word 5 6"' 6 | Type=oneshot 7 | EnvironmentFile=/tmp/test-exec_environmentfile.conf 8 | -------------------------------------------------------------------------------- /src/locale/language-fallback-map: -------------------------------------------------------------------------------- 1 | csb_PL csb:pl 2 | en_AU en_AU:en_GB 3 | en_IE en_IE:en_GB 4 | en_NZ en_NZ:en_GB 5 | en_ZA en_ZA:en_GB 6 | fr_BE fr_BE:fr_FR 7 | fr_CA fr_CA:fr_FR 8 | fr_CH fr_CH:fr_FR 9 | fr_LU fr_LU:fr_FR 10 | it_CH it_CH:it_IT 11 | mai_IN mai:hi 12 | nds_DE nds:de 13 | szl_PL szl:pl 14 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityambientset.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for AmbientCapabilities 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(grep "CapAmb:" /proc/self/status); test "$$c" = "CapAmb: 0000000000003000"' 6 | Type=oneshot 7 | User=nobody 8 | AmbientCapabilities=CAP_NET_ADMIN CAP_NET_RAW 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityboundingset-simple.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for CapabilityBoundingSet 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(capsh --print | grep "Bounding set "); test "$$c" = "Bounding set =cap_fowner,cap_kill"' 6 | Type=oneshot 7 | CapabilityBoundingSet=CAP_FOWNER CAP_KILL 8 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityambientset-nfsnobody.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for AmbientCapabilities 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(grep "CapAmb:" /proc/self/status); test "$$c" = "CapAmb: 0000000000003000"' 6 | Type=oneshot 7 | User=nfsnobody 8 | AmbientCapabilities=CAP_NET_ADMIN CAP_NET_RAW 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityboundingset-reset.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for CapabilityBoundingSet 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(capsh --print | grep "Bounding set "); test "$$c" = "Bounding set ="' 6 | Type=oneshot 7 | CapabilityBoundingSet=CAP_FOWNER CAP_KILL 8 | CapabilityBoundingSet= 9 | -------------------------------------------------------------------------------- /coccinelle/no-if-assignments.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression p, q; 3 | identifier r; 4 | statement s; 5 | @@ 6 | - if ((r = q) < p) 7 | - s 8 | + r = q; 9 | + if (r < p) 10 | + s 11 | @@ 12 | expression p, q; 13 | identifier r; 14 | statement s; 15 | @@ 16 | - if ((r = q) >= p) 17 | - s 18 | + r = q; 19 | + if (r >= p) 20 | + s 21 | -------------------------------------------------------------------------------- /coccinelle/safe_close.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression fd; 3 | @@ 4 | - close(fd); 5 | - fd = -1; 6 | + fd = safe_close(fd); 7 | @@ 8 | expression fd; 9 | @@ 10 | - close_nointr(fd); 11 | - fd = -1; 12 | + fd = safe_close(fd); 13 | @@ 14 | expression fd; 15 | @@ 16 | - safe_close(fd); 17 | - fd = -1; 18 | + fd = safe_close(fd); 19 | -------------------------------------------------------------------------------- /test/test-execute/exec-environment-multiple.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Environment 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$VAR1" = "word1 word2" && test "$$VAR2" = word3 && test "$$VAR3" = foobar' 6 | Type=oneshot 7 | Environment="VAR1=word1 word2" VAR2=word3 "VAR3=$word 5 6" 8 | Environment="VAR3=foobar" 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-runtimedirectory-mode.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for RuntimeDirectoryMode 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'mode=$$(stat -c %%a /tmp/test-exec_runtimedirectory-mode); test "$$mode" = "750"' 6 | Type=oneshot 7 | RuntimeDirectory=test-exec_runtimedirectory-mode 8 | RuntimeDirectoryMode=0750 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-environment-empty.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for Environment 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$${VAR1-unset}" = "unset" && test "$${VAR2-unset}" = "unset" && test "$${VAR3-unset}" = "unset"' 6 | Type=oneshot 7 | Environment="VAR1=word1 word2" VAR2=word3 "VAR3=$word 5 6" 8 | Environment= 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-systemcallfilter-not-failing.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for SystemCallFilter 3 | 4 | [Service] 5 | ExecStart=/bin/echo "Foo bar" 6 | Type=oneshot 7 | SystemCallFilter=~read write open execve ioperm 8 | SystemCallFilter=ioctl 9 | SystemCallFilter=read write open execve 10 | SystemCallFilter=~ioperm 11 | -------------------------------------------------------------------------------- /test/TEST-06-SELINUX/test-selinux-checks.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -x 4 | set -e 5 | set -o pipefail 6 | 7 | echo 1 >/sys/fs/selinux/enforce 8 | runcon -t systemd_test_start_t systemctl start hola 9 | runcon -t systemd_test_reload_t systemctl reload hola 10 | runcon -t systemd_test_stop_t systemctl stop hola 11 | 12 | touch /testok 13 | -------------------------------------------------------------------------------- /test/test-execute/exec-passenvironment-repeated.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PassEnvironment with a variable name repeated 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$$VAR1" = "word1 word2" && test "$$VAR2" = word3 && test "$$VAR3" = "\\$$word 5 6"' 6 | Type=oneshot 7 | PassEnvironment=VAR1 VAR2 8 | PassEnvironment=VAR1 VAR3 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-passenvironment-empty.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PassEnvironment and erasing the variable list 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$${VAR1-unset}" = "unset" && test "$${VAR2-unset}" = "unset" && test "$${VAR3-unset}" = "unset"' 6 | Type=oneshot 7 | PassEnvironment=VAR1 VAR2 VAR3 8 | PassEnvironment= 9 | -------------------------------------------------------------------------------- /m4/arch.m4: -------------------------------------------------------------------------------- 1 | 2 | dnl SET_ARCH(ARCHNAME, PATTERN) 3 | dnl 4 | dnl Define ARCH_ condition if the pattern match with the current 5 | dnl architecture 6 | dnl 7 | AC_DEFUN([SET_ARCH], [ 8 | cpu_$1=false 9 | case "$host" in 10 | $2) cpu_$1=true ;; 11 | esac 12 | AM_CONDITIONAL(AS_TR_CPP(ARCH_$1), [test "x$cpu_$1" = xtrue]) 13 | ]) 14 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityambientset-merge.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for AmbientCapabilities 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(grep "CapAmb:" /proc/self/status); test "$$c" = "CapAmb: 0000000000003000"' 6 | Type=oneshot 7 | User=nobody 8 | AmbientCapabilities=CAP_NET_ADMIN 9 | AmbientCapabilities=CAP_NET_RAW 10 | -------------------------------------------------------------------------------- /test/test-execute/exec-passenvironment-absent.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for PassEnvironment with variables absent from the execution environment 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'test "$${VAR1-unset}" = "unset" && test "$${VAR2-unset}" = "unset" && test "$${VAR3-unset}" = "unset"' 6 | Type=oneshot 7 | PassEnvironment=VAR1 VAR2 VAR3 8 | -------------------------------------------------------------------------------- /src/login/systemd-user.m4: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # Used by systemd --user instances. 4 | 5 | account include system-auth 6 | 7 | m4_ifdef(`HAVE_SELINUX', 8 | session required pam_selinux.so close 9 | session required pam_selinux.so nottys open 10 | )m4_dnl 11 | session required pam_loginuid.so 12 | session include system-auth 13 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityboundingset-merge.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for CapabilityBoundingSet 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(capsh --print | grep "Bounding set "); test "$$c" = "Bounding set =cap_chown,cap_fowner,cap_kill"' 6 | Type=oneshot 7 | CapabilityBoundingSet=CAP_FOWNER 8 | CapabilityBoundingSet=CAP_KILL CAP_CHOWN 9 | -------------------------------------------------------------------------------- /test/test-execute/exec-capabilityambientset-merge-nfsnobody.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for AmbientCapabilities 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'c=$$(grep "CapAmb:" /proc/self/status); test "$$c" = "CapAmb: 0000000000003000"' 6 | Type=oneshot 7 | User=nfsnobody 8 | AmbientCapabilities=CAP_NET_ADMIN 9 | AmbientCapabilities=CAP_NET_RAW 10 | -------------------------------------------------------------------------------- /rules/80-net-setup-link.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | SUBSYSTEM!="net", GOTO="net_setup_link_end" 4 | 5 | IMPORT{builtin}="path_id" 6 | 7 | ACTION!="add", GOTO="net_setup_link_end" 8 | 9 | IMPORT{builtin}="net_setup_link" 10 | 11 | NAME=="", ENV{ID_NET_NAME}!="", NAME="$env{ID_NET_NAME}" 12 | 13 | LABEL="net_setup_link_end" 14 | -------------------------------------------------------------------------------- /src/basic/.gitignore: -------------------------------------------------------------------------------- 1 | /cap-from-name.gperf 2 | /cap-from-name.h 3 | /cap-list.txt 4 | /cap-to-name.h 5 | /errno-from-name.gperf 6 | /errno-from-name.h 7 | /errno-list.txt 8 | /errno-to-name.h 9 | /af-from-name.gperf 10 | /af-from-name.h 11 | /af-list.txt 12 | /af-to-name.h 13 | /arphrd-from-name.gperf 14 | /arphrd-from-name.h 15 | /arphrd-list.txt 16 | /arphrd-to-name.h 17 | -------------------------------------------------------------------------------- /po/POTFILES.in: -------------------------------------------------------------------------------- 1 | src/core/org.freedesktop.systemd1.policy.in.in 2 | src/hostname/org.freedesktop.hostname1.policy.in 3 | src/import/org.freedesktop.import1.policy.in 4 | src/locale/org.freedesktop.locale1.policy.in 5 | src/login/org.freedesktop.login1.policy.in 6 | src/machine/org.freedesktop.machine1.policy.in 7 | src/timedate/org.freedesktop.timedate1.policy.in 8 | src/core/dbus-unit.c 9 | -------------------------------------------------------------------------------- /test/TEST-01-BASIC/Makefile: -------------------------------------------------------------------------------- 1 | all: 2 | @make -s --no-print-directory -C ../.. all 3 | @basedir=../.. TEST_BASE_DIR=../ ./test.sh --all 4 | setup: 5 | @make --no-print-directory -C ../.. all 6 | @basedir=../.. TEST_BASE_DIR=../ ./test.sh --setup 7 | clean: 8 | @basedir=../.. TEST_BASE_DIR=../ ./test.sh --clean 9 | run: 10 | @basedir=../.. TEST_BASE_DIR=../ ./test.sh --run 11 | -------------------------------------------------------------------------------- /test/test-execute/exec-systemcallfilter-system-user.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for SystemCallFilter in system mode with User set 3 | 4 | [Service] 5 | ExecStart=/bin/echo "Foo bar" 6 | Type=oneshot 7 | User=nobody 8 | SystemCallFilter=~read write open execve ioperm 9 | SystemCallFilter=ioctl 10 | SystemCallFilter=read write open execve 11 | SystemCallFilter=~ioperm 12 | -------------------------------------------------------------------------------- /test/test-execute/exec-systemcallfilter-system-user-nfsnobody.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for SystemCallFilter in system mode with User set 3 | 4 | [Service] 5 | ExecStart=/bin/echo "Foo bar" 6 | Type=oneshot 7 | User=nfsnobody 8 | SystemCallFilter=~read write open execve ioperm 9 | SystemCallFilter=ioctl 10 | SystemCallFilter=read write open execve 11 | SystemCallFilter=~ioperm 12 | -------------------------------------------------------------------------------- /shell-completion/zsh/_sd_machines: -------------------------------------------------------------------------------- 1 | #autoload 2 | __get_machines () { 3 | machinectl --full --no-legend --no-pager list | {while read -r a b; do echo $a; done;}; 4 | } 5 | 6 | local -a _machines 7 | _machines=("${(fo)$(__get_machines)}") 8 | typeset -U _machines 9 | if [[ -n "$_machines" ]]; then 10 | _describe 'machines' _machines 11 | else 12 | _message 'no machines' 13 | fi 14 | -------------------------------------------------------------------------------- /test/test-execute/exec-runtimedirectory-owner.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for RuntimeDirectory owner (must not be the default group of the user if Group is set) 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'group=$$(stat -c %%G /tmp/test-exec_runtimedirectory-owner); test "$$group" = "nobody"' 6 | Type=oneshot 7 | Group=nobody 8 | User=root 9 | RuntimeDirectory=test-exec_runtimedirectory-owner 10 | -------------------------------------------------------------------------------- /units/paths.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Paths 10 | Documentation=man:systemd.special(7) 11 | -------------------------------------------------------------------------------- /units/swap.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Swap 10 | Documentation=man:systemd.special(7) 11 | -------------------------------------------------------------------------------- /units/sockets.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Sockets 10 | Documentation=man:systemd.special(7) 11 | -------------------------------------------------------------------------------- /factory/etc/pam.d/system-auth: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | 3 | auth sufficient pam_unix.so nullok try_first_pass 4 | 5 | account required pam_nologin.so 6 | account sufficient pam_unix.so 7 | 8 | password sufficient pam_unix.so nullok sha512 shadow try_first_pass try_authtok 9 | 10 | -session optional pam_loginuid.so 11 | -session optional pam_systemd.so 12 | session sufficient pam_unix.so 13 | -------------------------------------------------------------------------------- /units/busnames.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Bus Names 10 | Documentation=man:systemd.special(7) 11 | -------------------------------------------------------------------------------- /units/sigpwr.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Power Failure 10 | Documentation=man:systemd.special(7) 11 | -------------------------------------------------------------------------------- /test/test-execute/exec-runtimedirectory-owner-nfsnobody.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Test for RuntimeDirectory owner (must not be the default group of the user if Group is set) 3 | 4 | [Service] 5 | ExecStart=/bin/sh -x -c 'group=$$(stat -c %%G /tmp/test-exec_runtimedirectory-owner); test "$$group" = "nfsnobody"' 6 | Type=oneshot 7 | Group=nfsnobody 8 | User=root 9 | RuntimeDirectory=test-exec_runtimedirectory-owner 10 | -------------------------------------------------------------------------------- /tmpfiles.d/home.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See tmpfiles.d(5) for details 9 | 10 | Q /home 0755 - - - 11 | q /srv 0755 - - - 12 | -------------------------------------------------------------------------------- /units/cryptsetup.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Encrypted Volumes 10 | Documentation=man:systemd.special(7) 11 | -------------------------------------------------------------------------------- /units/printer.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Printer 10 | Documentation=man:systemd.special(7) 11 | StopWhenUnneeded=yes 12 | -------------------------------------------------------------------------------- /units/bluetooth.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Bluetooth 10 | Documentation=man:systemd.special(7) 11 | StopWhenUnneeded=yes 12 | -------------------------------------------------------------------------------- /units/smartcard.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Smart Card 10 | Documentation=man:systemd.special(7) 11 | StopWhenUnneeded=yes 12 | -------------------------------------------------------------------------------- /units/sound.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Sound Card 10 | Documentation=man:systemd.special(7) 11 | StopWhenUnneeded=yes 12 | -------------------------------------------------------------------------------- /src/core/org.freedesktop.systemd1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.systemd1 10 | Exec=/bin/false 11 | User=root 12 | -------------------------------------------------------------------------------- /units/user.slice: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=User and Session Slice 10 | Documentation=man:systemd.special(7) 11 | Before=slices.target 12 | -------------------------------------------------------------------------------- /test/bus-policy/hello.conf: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /units/time-sync.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=System Time Synchronized 10 | Documentation=man:systemd.special(7) 11 | RefuseManualStart=yes 12 | -------------------------------------------------------------------------------- /units/cryptsetup-pre.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Encrypted Volumes (Pre) 10 | Documentation=man:systemd.special(7) 11 | RefuseManualStart=yes 12 | -------------------------------------------------------------------------------- /units/local-fs-pre.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Local File Systems (Pre) 10 | Documentation=man:systemd.special(7) 11 | RefuseManualStart=yes 12 | -------------------------------------------------------------------------------- /units/remote-fs-pre.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Remote File Systems (Pre) 10 | Documentation=man:systemd.special(7) 11 | RefuseManualStart=yes 12 | -------------------------------------------------------------------------------- /units/x-.slice: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Root Slice 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Before=slices.target 13 | -------------------------------------------------------------------------------- /coccinelle/safe_fclose.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression p; 3 | @@ 4 | - if (p) { 5 | - fclose(p); 6 | - p = NULL; 7 | - } 8 | + p = safe_fclose(p); 9 | @@ 10 | expression p; 11 | @@ 12 | - if (p) 13 | - fclose(p); 14 | - p = NULL; 15 | + p = safe_fclose(p); 16 | @@ 17 | expression p; 18 | @@ 19 | - fclose(p); 20 | - p = NULL; 21 | + p = safe_fclose(p); 22 | @@ 23 | expression p; 24 | @@ 25 | - if (p) 26 | - fclose(p); 27 | + safe_fclose(p); 28 | -------------------------------------------------------------------------------- /coccinelle/strv_free.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression p; 3 | @@ 4 | - strv_free(p); 5 | - p = NULL; 6 | + p = strv_free(p); 7 | @@ 8 | expression p; 9 | @@ 10 | - if (p) 11 | - strv_free(p); 12 | - p = NULL; 13 | + p = strv_free(p); 14 | @@ 15 | expression p; 16 | @@ 17 | - if (p) { 18 | - strv_free(p); 19 | - p = NULL; 20 | - } 21 | + p = strv_free(p); 22 | @@ 23 | expression p; 24 | @@ 25 | - if (p) 26 | - strv_free(p); 27 | + strv_free(p); 28 | -------------------------------------------------------------------------------- /src/login/pam_systemd.sym: -------------------------------------------------------------------------------- 1 | /*** 2 | This file is part of systemd. 3 | 4 | systemd is free software; you can redistribute it and/or modify it 5 | under the terms of the GNU Lesser General Public License as published by 6 | the Free Software Foundation; either version 2.1 of the License, or 7 | (at your option) any later version. 8 | ***/ 9 | 10 | { 11 | global: 12 | pam_sm_close_session; 13 | pam_sm_open_session; 14 | local: *; 15 | }; 16 | -------------------------------------------------------------------------------- /units/machine.slice: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Virtual Machine and Container Slice 10 | Documentation=man:systemd.special(7) 11 | Before=slices.target 12 | -------------------------------------------------------------------------------- /units/shutdown.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Shutdown 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | RefuseManualStart=yes 13 | -------------------------------------------------------------------------------- /units/slices.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Slices 10 | Documentation=man:systemd.special(7) 11 | Wants=-.slice system.slice 12 | After=-.slice system.slice 13 | -------------------------------------------------------------------------------- /units/timers.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Timers 10 | Documentation=man:systemd.special(7) 11 | 12 | DefaultDependencies=no 13 | Conflicts=shutdown.target 14 | -------------------------------------------------------------------------------- /units/umount.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Unmount All Filesystems 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | RefuseManualStart=yes 13 | -------------------------------------------------------------------------------- /coccinelle/safe_closedir.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression p; 3 | @@ 4 | - if (p) { 5 | - closedir(p); 6 | - p = NULL; 7 | - } 8 | + p = safe_closedir(p); 9 | @@ 10 | expression p; 11 | @@ 12 | - if (p) 13 | - closedir(p); 14 | - p = NULL; 15 | + p = safe_closedir(p); 16 | @@ 17 | expression p; 18 | @@ 19 | - closedir(p); 20 | - p = NULL; 21 | + p = safe_closedir(p); 22 | @@ 23 | expression p; 24 | @@ 25 | - if (p) 26 | - closedir(p); 27 | + safe_closedir(p); 28 | -------------------------------------------------------------------------------- /rules/64-btrfs.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | SUBSYSTEM!="block", GOTO="btrfs_end" 4 | ACTION=="remove", GOTO="btrfs_end" 5 | ENV{ID_FS_TYPE}!="btrfs", GOTO="btrfs_end" 6 | 7 | # let the kernel know about this btrfs filesystem, and check if it is complete 8 | IMPORT{builtin}="btrfs ready $devnode" 9 | 10 | # mark the device as not ready to be used by the system 11 | ENV{ID_BTRFS_READY}=="0", ENV{SYSTEMD_READY}="0" 12 | 13 | LABEL="btrfs_end" 14 | -------------------------------------------------------------------------------- /test/bus-policy/signals.conf: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /units/sleep.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Sleep 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | RefuseManualStart=yes 13 | StopWhenUnneeded=yes 14 | -------------------------------------------------------------------------------- /units/user/default.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Default 10 | Documentation=man:systemd.special(7) 11 | Requires=basic.target 12 | After=basic.target 13 | AllowIsolate=yes 14 | -------------------------------------------------------------------------------- /test/Makefile: -------------------------------------------------------------------------------- 1 | # Just a little hook script to easy building when in this directory 2 | .PHONY: all check clean 3 | 4 | all: 5 | $(MAKE) -C .. 6 | 7 | clean: 8 | @for i in TEST-[0-9]*; do \ 9 | [ -d $$i ] || continue ; \ 10 | [ -f $$i/Makefile ] || continue ; \ 11 | make -C $$i clean ; \ 12 | done 13 | 14 | check: 15 | $(MAKE) -C .. all 16 | @for i in TEST-[0-9]*; do \ 17 | [ -d $$i ] || continue ; \ 18 | [ -f $$i/Makefile ] || continue ; \ 19 | make -C $$i all ; \ 20 | done 21 | -------------------------------------------------------------------------------- /units/systemd-journal-remote.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Journal Remote Sink Socket 10 | 11 | [Socket] 12 | ListenStream=19532 13 | 14 | [Install] 15 | WantedBy=sockets.target 16 | -------------------------------------------------------------------------------- /src/import/org.freedesktop.import1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.import1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.import1.service 13 | -------------------------------------------------------------------------------- /src/locale/org.freedesktop.locale1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.locale1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.locale1.service 13 | -------------------------------------------------------------------------------- /src/login/org.freedesktop.login1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.login1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.login1.service 13 | -------------------------------------------------------------------------------- /src/machine/org.freedesktop.machine1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.machine1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.machine1.service 13 | -------------------------------------------------------------------------------- /src/network/org.freedesktop.network1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.network1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.network1.service 13 | -------------------------------------------------------------------------------- /src/resolve/org.freedesktop.resolve1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.resolve1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.resolve1.service 13 | -------------------------------------------------------------------------------- /units/emergency.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Emergency Mode 10 | Documentation=man:systemd.special(7) 11 | Requires=emergency.service 12 | After=emergency.service 13 | AllowIsolate=yes 14 | -------------------------------------------------------------------------------- /src/hostname/org.freedesktop.hostname1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.hostname1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.hostname1.service 13 | -------------------------------------------------------------------------------- /src/timedate/org.freedesktop.timedate1.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [D-BUS Service] 9 | Name=org.freedesktop.timedate1 10 | Exec=/bin/false 11 | User=root 12 | SystemdService=dbus-org.freedesktop.timedate1.service 13 | -------------------------------------------------------------------------------- /src/vconsole/90-vconsole.rules.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # Each vtcon keeps its own state of fonts. 9 | # 10 | ACTION=="add", SUBSYSTEM=="vtconsole", KERNEL=="vtcon*", RUN+="@rootlibexecdir@/systemd-vconsole-setup" 11 | -------------------------------------------------------------------------------- /units/final.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Final Step 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | RefuseManualStart=yes 13 | After=shutdown.target umount.target 14 | -------------------------------------------------------------------------------- /units/suspend.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Suspend 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | BindsTo=systemd-suspend.service 13 | After=systemd-suspend.service 14 | -------------------------------------------------------------------------------- /units/system.slice: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=System Slice 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Before=slices.target 13 | Requires=-.slice 14 | After=-.slice 15 | -------------------------------------------------------------------------------- /units/getty.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Login Prompts 10 | Documentation=man:systemd.special(7) man:systemd-getty-generator(8) 11 | Documentation=http://0pointer.de/blog/projects/serial-console.html 12 | -------------------------------------------------------------------------------- /units/hibernate.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Hibernate 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | BindsTo=systemd-hibernate.service 13 | After=systemd-hibernate.service 14 | -------------------------------------------------------------------------------- /units/sysinit.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=System Initialization 10 | Documentation=man:systemd.special(7) 11 | Conflicts=emergency.service emergency.target 12 | After=emergency.service emergency.target 13 | -------------------------------------------------------------------------------- /units/user/basic.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Basic System 10 | Documentation=man:systemd.special(7) 11 | Wants=sockets.target timers.target paths.target 12 | After=sockets.target timers.target paths.target 13 | -------------------------------------------------------------------------------- /units/network-pre.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Network (Pre) 10 | Documentation=man:systemd.special(7) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget 12 | RefuseManualStart=yes 13 | -------------------------------------------------------------------------------- /rules/75-net-description.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | ACTION=="remove", GOTO="net_end" 4 | SUBSYSTEM!="net", GOTO="net_end" 5 | 6 | IMPORT{builtin}="net_id" 7 | 8 | SUBSYSTEMS=="usb", IMPORT{builtin}="usb_id", IMPORT{builtin}="hwdb --subsystem=usb" 9 | SUBSYSTEMS=="usb", GOTO="net_end" 10 | 11 | SUBSYSTEMS=="pci", ENV{ID_BUS}="pci", ENV{ID_VENDOR_ID}="$attr{vendor}", ENV{ID_MODEL_ID}="$attr{device}" 12 | SUBSYSTEMS=="pci", IMPORT{builtin}="hwdb --subsystem=pci" 13 | 14 | LABEL="net_end" 15 | -------------------------------------------------------------------------------- /test/bus-policy/check-own-rules.conf: -------------------------------------------------------------------------------- 1 | 3 | 4 | mybususer 5 | unix:path=/foo/bar 6 | tcp:port=1234 7 | /usr/share/foo 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /units/network-online.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Network is Online 10 | Documentation=man:systemd.special(7) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget 12 | After=network.target 13 | -------------------------------------------------------------------------------- /units/systemd-tmpfiles-clean.timer: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Daily Cleanup of Temporary Directories 10 | Documentation=man:tmpfiles.d(5) man:systemd-tmpfiles(8) 11 | 12 | [Timer] 13 | OnBootSec=15min 14 | OnUnitActiveSec=1d 15 | -------------------------------------------------------------------------------- /units/user/exit.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Exit the Session 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=systemd-exit.service 13 | After=systemd-exit.service 14 | AllowIsolate=yes 15 | -------------------------------------------------------------------------------- /units/hybrid-sleep.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Hybrid Suspend+Hibernate 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | BindsTo=systemd-hybrid-sleep.service 13 | After=systemd-hybrid-sleep.service 14 | -------------------------------------------------------------------------------- /units/network.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Network 10 | Documentation=man:systemd.special(7) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget 12 | After=network-pre.target 13 | RefuseManualStart=yes 14 | -------------------------------------------------------------------------------- /man/libsystemd-pkgconfig.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | Notes 7 | 8 | These APIs are implemented as a shared 9 | library, which can be compiled and linked to with the 10 | libsystemd pkg-config1 11 | file. 12 | 13 | -------------------------------------------------------------------------------- /units/nss-user-lookup.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # This exists mostly for implementations lacking socket/bus 9 | # activation. 10 | 11 | [Unit] 12 | Description=User and Group Name Lookups 13 | Documentation=man:systemd.special(7) 14 | RefuseManualStart=yes 15 | -------------------------------------------------------------------------------- /units/systemd-journal-gatewayd.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Journal Gateway Service Socket 10 | Documentation=man:systemd-journal-gatewayd(8) 11 | 12 | [Socket] 13 | ListenStream=19531 14 | 15 | [Install] 16 | WantedBy=sockets.target 17 | -------------------------------------------------------------------------------- /test/TEST-05-RLIMITS/test-rlimits.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -x 4 | set -e 5 | set -o pipefail 6 | 7 | [[ "$(systemctl show -p DefaultLimitNOFILESoft)" = "DefaultLimitNOFILESoft=10000" ]] 8 | [[ "$(systemctl show -p DefaultLimitNOFILE)" = "DefaultLimitNOFILE=16384" ]] 9 | 10 | [[ "$(systemctl show -p LimitNOFILESoft testsuite.service)" = "LimitNOFILESoft=10000" ]] 11 | [[ "$(systemctl show -p LimitNOFILE testsuite.service)" = "LimitNOFILE=16384" ]] 12 | 13 | [[ "$(ulimit -n -S)" = "10000" ]] 14 | [[ "$(ulimit -n -H)" = "16384" ]] 15 | 16 | touch /testok 17 | -------------------------------------------------------------------------------- /tmpfiles.d/systemd-nologin.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See tmpfiles.d(5), systemd-user-session.service(5) and pam_nologin(8). 9 | # This file has special suffix so it is not run by mistake. 10 | 11 | F! /run/nologin 0644 - - - "System is booting up. See pam_nologin(8)" 12 | -------------------------------------------------------------------------------- /units/org.freedesktop.import1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Virtual Machine and Container Download Service Bus Name 10 | Documentation=man:systemd-importd.service(8) 11 | 12 | [BusName] 13 | Service=systemd-importd.service 14 | AllowWorld=talk 15 | -------------------------------------------------------------------------------- /units/multi-user.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Multi-User System 10 | Documentation=man:systemd.special(7) 11 | Requires=basic.target 12 | Conflicts=rescue.service rescue.target 13 | After=basic.target rescue.service rescue.target 14 | AllowIsolate=yes 15 | -------------------------------------------------------------------------------- /units/remote-fs.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Remote File Systems 10 | Documentation=man:systemd.special(7) 11 | After=remote-fs-pre.target 12 | DefaultDependencies=no 13 | Conflicts=shutdown.target 14 | 15 | [Install] 16 | WantedBy=multi-user.target 17 | -------------------------------------------------------------------------------- /units/rescue.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Rescue Mode 10 | Documentation=man:systemd.special(7) 11 | Requires=sysinit.target rescue.service 12 | After=sysinit.target rescue.service 13 | AllowIsolate=yes 14 | 15 | [Install] 16 | Alias=kbrequest.target 17 | -------------------------------------------------------------------------------- /units/var-lib-machines.mount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Virtual Machine and Container Storage 10 | ConditionPathExists=/var/lib/machines.raw 11 | 12 | [Mount] 13 | What=/var/lib/machines.raw 14 | Where=/var/lib/machines 15 | Type=btrfs 16 | Options=loop 17 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig configuration for systemd 2 | # http://EditorConfig.org 3 | 4 | # NOTE: If you update this file make sure to update .dir-locals.el and .vimrc, 5 | # too. 6 | 7 | # Top-most EditorConfig file 8 | root = true 9 | 10 | # Unix-style newlines with a newline ending every file, utf-8 charset 11 | [*] 12 | end_of_line = lf 13 | insert_final_newline = true 14 | trim_trailing_whitespace = true 15 | charset = utf-8 16 | 17 | # Match config files, set indent to spaces with width of eight 18 | [*.{c,h}] 19 | indent_style = space 20 | indent_size = 8 21 | -------------------------------------------------------------------------------- /units/halt.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Halt 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=systemd-halt.service 13 | After=systemd-halt.service 14 | AllowIsolate=yes 15 | 16 | [Install] 17 | Alias=ctrl-alt-del.target 18 | -------------------------------------------------------------------------------- /units/rpcbind.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # This exists mostly for compatibility with SysV/LSB units, and 9 | # implementations lacking socket/bus activation. 10 | 11 | [Unit] 12 | Description=RPC Port Mapper 13 | Documentation=man:systemd.special(7) 14 | RefuseManualStart=yes 15 | -------------------------------------------------------------------------------- /units/systemd-initctl.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=/dev/initctl Compatibility Daemon 10 | Documentation=man:systemd-initctl.service(8) 11 | DefaultDependencies=no 12 | 13 | [Service] 14 | ExecStart=@rootlibexecdir@/systemd-initctl 15 | NotifyAccess=all 16 | -------------------------------------------------------------------------------- /po/POTFILES.skip: -------------------------------------------------------------------------------- 1 | src/core/dbus-automount.c 2 | src/core/dbus-device.c 3 | src/core/dbus-job.c 4 | src/core/dbus-manager.c 5 | src/core/dbus-mount.c 6 | src/core/dbus-path.c 7 | src/core/dbus-service.c 8 | src/core/dbus-slice.c 9 | src/core/dbus-socket.c 10 | src/core/dbus-swap.c 11 | src/core/dbus-target.c 12 | src/core/dbus-timer.c 13 | src/core/dbus-unit.c 14 | src/core/dbus-scope.c 15 | src/hostname/hostnamed.c 16 | src/locale/localed.c 17 | src/core/org.freedesktop.systemd1.policy.in 18 | src/timedate/timedated.c 19 | units/user@.service.in 20 | units/debug-shell.service.in 21 | -------------------------------------------------------------------------------- /units/org.freedesktop.systemd1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=System and Service Manager Bus Name 10 | Documentation=man:systemd(1) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd 12 | 13 | [BusName] 14 | Activating=no 15 | AllowWorld=talk 16 | -------------------------------------------------------------------------------- /units/exit.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Exit the container 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=systemd-exit.service 13 | After=systemd-exit.service 14 | AllowIsolate=yes 15 | 16 | [Install] 17 | Alias=ctrl-alt-del.target 18 | -------------------------------------------------------------------------------- /units/kexec.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Reboot via kexec 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=systemd-kexec.service 13 | After=systemd-kexec.service 14 | AllowIsolate=yes 15 | 16 | [Install] 17 | Alias=ctrl-alt-del.target 18 | -------------------------------------------------------------------------------- /units/local-fs.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Local File Systems 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=local-fs-pre.target 14 | OnFailure=emergency.target 15 | OnFailureJobMode=replace-irreversibly 16 | -------------------------------------------------------------------------------- /units/nss-lookup.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # This exists mostly for compatibility with SysV/LSB units, and 9 | # implementations lacking socket/bus activation. 10 | 11 | [Unit] 12 | Description=Host and Network Name Lookups 13 | Documentation=man:systemd.special(7) 14 | RefuseManualStart=yes 15 | -------------------------------------------------------------------------------- /sysctl.d/50-coredump.conf.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See sysctl.d(5) for the description of the files in this directory, 9 | # and systemd-coredump(8) and core(5) for the explanation of the 10 | # setting below. 11 | 12 | kernel.core_pattern=|@rootlibexecdir@/systemd-coredump %P %u %g %s %t %c %e 13 | -------------------------------------------------------------------------------- /units/systemd-coredump.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Process Core Dump Socket 10 | Documentation=man:systemd-coredump(8) 11 | DefaultDependencies=no 12 | 13 | [Socket] 14 | ListenSequentialPacket=/run/systemd/coredump 15 | SocketMode=0600 16 | Accept=yes 17 | MaxConnections=16 18 | -------------------------------------------------------------------------------- /units/systemd-exit.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Exit the Session 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=shutdown.target 13 | After=shutdown.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@SYSTEMCTL@ --force exit 18 | -------------------------------------------------------------------------------- /units/user/systemd-exit.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Exit the Session 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=shutdown.target 13 | After=shutdown.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@KILL@ -s 58 $MANAGERPID 18 | -------------------------------------------------------------------------------- /src/libudev/libudev.pc.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | prefix=@prefix@ 9 | exec_prefix=@exec_prefix@ 10 | libdir=@libdir@ 11 | includedir=@includedir@ 12 | 13 | Name: libudev 14 | Description: Library to access udev device information 15 | Version: @VERSION@ 16 | Libs: -L${libdir} -ludev 17 | Cflags: -I${includedir} 18 | -------------------------------------------------------------------------------- /units/systemd-suspend.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Suspend 10 | Documentation=man:systemd-suspend.service(8) 11 | DefaultDependencies=no 12 | Requires=sleep.target 13 | After=sleep.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@rootlibexecdir@/systemd-sleep suspend 18 | -------------------------------------------------------------------------------- /sysusers.d/systemd-remote.conf.m4: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | m4_ifdef(`HAVE_MICROHTTPD', 9 | u systemd-journal-gateway - "systemd Journal Gateway" 10 | u systemd-journal-remote - "systemd Journal Remote" 11 | )m4_dnl 12 | m4_ifdef(`HAVE_LIBCURL', 13 | u systemd-journal-upload - "systemd Journal Upload" 14 | )m4_dnl 15 | -------------------------------------------------------------------------------- /test/mocks/fsck: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | fd=0 3 | 4 | OPTIND=1 5 | while getopts "C:aTlM" opt; do 6 | case "$opt" in 7 | C) 8 | fd=$OPTARG 9 | ;; 10 | \?);; 11 | esac 12 | done 13 | 14 | shift "$((OPTIND-1))" 15 | device=$1 16 | 17 | echo "Running fake fsck on $device" 18 | 19 | declare -a maxpass=(30 5 2 30 60) 20 | 21 | for pass in {1..5}; do 22 | maxprogress=${maxpass[$((pass-1))]} 23 | for (( current=0; current<=${maxprogress}; current++)); do 24 | echo "$pass $current $maxprogress $device">&$fd 25 | sleep 0.1 26 | done 27 | done 28 | -------------------------------------------------------------------------------- /units/initrd-root-device.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Initrd Root Device 10 | Documentation=man:systemd.special(7) 11 | ConditionPathExists=/etc/initrd-release 12 | OnFailure=emergency.target 13 | OnFailureJobMode=replace-irreversibly 14 | DefaultDependencies=no 15 | Conflicts=shutdown.target 16 | -------------------------------------------------------------------------------- /units/systemd-hibernate.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Hibernate 10 | Documentation=man:systemd-suspend.service(8) 11 | DefaultDependencies=no 12 | Requires=sleep.target 13 | After=sleep.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@rootlibexecdir@/systemd-sleep hibernate 18 | -------------------------------------------------------------------------------- /units/initrd-root-fs.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Initrd Root File System 10 | Documentation=man:systemd.special(7) 11 | ConditionPathExists=/etc/initrd-release 12 | OnFailure=emergency.target 13 | OnFailureJobMode=replace-irreversibly 14 | DefaultDependencies=no 15 | Conflicts=shutdown.target 16 | -------------------------------------------------------------------------------- /shell-completion/zsh/_systemd-delta: -------------------------------------------------------------------------------- 1 | #compdef systemd-delta 2 | 3 | _delta_type() { 4 | local -a _delta_types 5 | _delta_types=(masked equivalent redirected overridden unchanged) 6 | _values -s , "${_delta_types[@]}" 7 | } 8 | 9 | _arguments \ 10 | {-h,--help}'[Show this help]' \ 11 | '--version[Show package version]' \ 12 | '--no-pager[Do not pipe output into a pager]' \ 13 | '--diff=[Show a diff when overridden files differ]:boolean:(1 0)' \ 14 | {-t+,--type=}'[Only display a selected set of override types]:types:_delta_type' \ 15 | ':SUFFIX:(tmpfiles.d sysctl.d systemd/system)' 16 | -------------------------------------------------------------------------------- /src/libsystemd/libsystemd.pc.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | prefix=@prefix@ 9 | exec_prefix=@exec_prefix@ 10 | libdir=@libdir@ 11 | includedir=@includedir@ 12 | 13 | Name: systemd 14 | Description: systemd Library 15 | URL: @PACKAGE_URL@ 16 | Version: @PACKAGE_VERSION@ 17 | Libs: -L${libdir} -lsystemd 18 | Cflags: -I${includedir} 19 | -------------------------------------------------------------------------------- /units/machines.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Containers 10 | Documentation=man:systemd.special(7) 11 | Requires=basic.target 12 | Conflicts=rescue.service rescue.target 13 | After=basic.target rescue.service rescue.target 14 | Before=multi-user.target 15 | 16 | [Install] 17 | WantedBy=multi-user.target 18 | -------------------------------------------------------------------------------- /units/systemd-initctl.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=/dev/initctl Compatibility Named Pipe 10 | Documentation=man:systemd-initctl.service(8) 11 | DefaultDependencies=no 12 | Before=sockets.target 13 | 14 | [Socket] 15 | ListenFIFO=/run/systemd/initctl/fifo 16 | Symlinks=/dev/initctl 17 | SocketMode=0600 18 | -------------------------------------------------------------------------------- /src/timesync/timesyncd-gperf.gperf: -------------------------------------------------------------------------------- 1 | %{ 2 | #include 3 | #include "conf-parser.h" 4 | #include "timesyncd-conf.h" 5 | %} 6 | struct ConfigPerfItem; 7 | %null_strings 8 | %language=ANSI-C 9 | %define slot-name section_and_lvalue 10 | %define hash-function-name timesyncdd_gperf_hash 11 | %define lookup-function-name timesyncd_gperf_lookup 12 | %readonly-tables 13 | %omit-struct-type 14 | %struct-type 15 | %includes 16 | %% 17 | Time.NTP, config_parse_servers, SERVER_SYSTEM, 0 18 | Time.Servers, config_parse_servers, SERVER_SYSTEM, 0 19 | Time.FallbackNTP, config_parse_servers, SERVER_FALLBACK, 0 20 | -------------------------------------------------------------------------------- /src/timesync/timesyncd.conf.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | # 8 | # Entries in this file show the compile time defaults. 9 | # You can change settings by editing this file. 10 | # Defaults can be restored by simply deleting this file. 11 | # 12 | # See timesyncd.conf(5) for details. 13 | 14 | [Time] 15 | #NTP= 16 | #FallbackNTP=@NTP_SERVERS@ 17 | -------------------------------------------------------------------------------- /units/systemd-hybrid-sleep.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Hybrid Suspend+Hibernate 10 | Documentation=man:systemd-suspend.service(8) 11 | DefaultDependencies=no 12 | Requires=sleep.target 13 | After=sleep.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@rootlibexecdir@/systemd-sleep hybrid-sleep 18 | -------------------------------------------------------------------------------- /units/org.freedesktop.timedate1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Time & Date Service Bus Name 10 | Documentation=man:systemd-timedated.service(8) man:localtime(5) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/timedated 12 | 13 | [BusName] 14 | Service=systemd-timedated.service 15 | AllowWorld=talk 16 | -------------------------------------------------------------------------------- /units/graphical.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Graphical Interface 10 | Documentation=man:systemd.special(7) 11 | Requires=multi-user.target 12 | Wants=display-manager.service 13 | Conflicts=rescue.service rescue.target 14 | After=multi-user.target rescue.service rescue.target display-manager.service 15 | AllowIsolate=yes 16 | -------------------------------------------------------------------------------- /units/initrd-fs.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Initrd File Systems 10 | Documentation=man:systemd.special(7) 11 | OnFailure=emergency.target 12 | OnFailureJobMode=replace-irreversibly 13 | ConditionPathExists=/etc/initrd-release 14 | After=initrd-parse-etc.service 15 | DefaultDependencies=no 16 | Conflicts=shutdown.target 17 | -------------------------------------------------------------------------------- /units/reboot.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Reboot 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=systemd-reboot.service 13 | After=systemd-reboot.service 14 | AllowIsolate=yes 15 | JobTimeoutSec=30min 16 | JobTimeoutAction=reboot-force 17 | 18 | [Install] 19 | Alias=ctrl-alt-del.target 20 | -------------------------------------------------------------------------------- /units/systemd-halt.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Halt 10 | Documentation=man:systemd-halt.service(8) 11 | DefaultDependencies=no 12 | Requires=shutdown.target umount.target final.target 13 | After=shutdown.target umount.target final.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@SYSTEMCTL@ --force halt 18 | -------------------------------------------------------------------------------- /units/user@.service.m4.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=User Manager for UID %i 10 | After=systemd-user-sessions.service 11 | 12 | [Service] 13 | User=%i 14 | PAMName=systemd-user 15 | Type=notify 16 | ExecStart=-@rootlibexecdir@/systemd --user 17 | Slice=user-%i.slice 18 | KillMode=mixed 19 | Delegate=yes 20 | TasksMax=infinity 21 | -------------------------------------------------------------------------------- /tmpfiles.d/var.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See tmpfiles.d(5) for details 9 | 10 | q /var 0755 - - - 11 | 12 | L /var/run - - - - ../run 13 | 14 | d /var/log 0755 - - - 15 | f /var/log/wtmp 0664 root utmp - 16 | f /var/log/btmp 0600 root utmp - 17 | 18 | d /var/cache 0755 - - - 19 | 20 | d /var/lib 0755 - - - 21 | 22 | d /var/spool 0755 - - - 23 | -------------------------------------------------------------------------------- /units/org.freedesktop.locale1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Locale Service Bus Name 10 | Documentation=man:systemd-localed.service(8) man:locale.conf(5) man:vconsole.conf(5) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/localed 12 | 13 | [BusName] 14 | Service=systemd-localed.service 15 | AllowWorld=talk 16 | -------------------------------------------------------------------------------- /units/org.freedesktop.machine1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Virtual Machine and Container Registration Service Bus Name 10 | Documentation=man:systemd-machined.service(8) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/machined 12 | 13 | [BusName] 14 | Service=systemd-machined.service 15 | AllowWorld=talk 16 | -------------------------------------------------------------------------------- /units/systemd-reboot.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Reboot 10 | Documentation=man:systemd-halt.service(8) 11 | DefaultDependencies=no 12 | Requires=shutdown.target umount.target final.target 13 | After=shutdown.target umount.target final.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@SYSTEMCTL@ --force reboot 18 | -------------------------------------------------------------------------------- /src/network/networkd-gperf.gperf: -------------------------------------------------------------------------------- 1 | %{ 2 | #include 3 | #include "conf-parser.h" 4 | #include "networkd-conf.h" 5 | %} 6 | struct ConfigPerfItem; 7 | %null_strings 8 | %language=ANSI-C 9 | %define slot-name section_and_lvalue 10 | %define hash-function-name networkd_gperf_hash 11 | %define lookup-function-name networkd_gperf_lookup 12 | %readonly-tables 13 | %omit-struct-type 14 | %struct-type 15 | %includes 16 | %% 17 | DHCP.DUIDType, config_parse_duid_type, 0, offsetof(Manager, duid.type) 18 | DHCP.DUIDRawData, config_parse_duid_rawdata, 0, offsetof(Manager, duid) 19 | -------------------------------------------------------------------------------- /tools/check-includes.pl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl 2 | # 3 | # checkincludes: Find files included more than once in (other) files. 4 | # Copyright abandoned, 2000, Niels Kristian Bech Jensen . 5 | 6 | foreach $file (@ARGV) { 7 | open(FILE, $file) or die "Cannot open $file: $!.\n"; 8 | 9 | my %includedfiles = (); 10 | 11 | while () { 12 | if (m/^\s*#\s*include\s*[<"](\S*)[>"]/o) { 13 | ++$includedfiles{$1}; 14 | } 15 | } 16 | foreach $filename (keys %includedfiles) { 17 | if ($includedfiles{$filename} > 1) { 18 | print "$file: $filename is included more than once.\n"; 19 | } 20 | } 21 | 22 | close(FILE); 23 | } 24 | -------------------------------------------------------------------------------- /tmpfiles.d/systemd-remote.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See tmpfiles.d(5) for details 9 | 10 | d /var/lib/systemd/journal-upload 0755 systemd-journal-upload systemd-journal-upload - - 11 | 12 | z /var/log/journal/remote 2755 systemd-journal-remote systemd-journal-remote - - 13 | z /run/log/journal/remote 2755 systemd-journal-remote systemd-journal-remote - - 14 | -------------------------------------------------------------------------------- /units/org.freedesktop.hostname1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Hostname Service Bus Name 10 | Documentation=man:systemd-hostnamed.service(8) man:hostname(5) man:machine-info(5) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/hostnamed 12 | 13 | [BusName] 14 | Service=systemd-hostnamed.service 15 | AllowWorld=talk 16 | -------------------------------------------------------------------------------- /units/poweroff.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Power-Off 10 | Documentation=man:systemd.special(7) 11 | DefaultDependencies=no 12 | Requires=systemd-poweroff.service 13 | After=systemd-poweroff.service 14 | AllowIsolate=yes 15 | JobTimeoutSec=30min 16 | JobTimeoutAction=poweroff-force 17 | 18 | [Install] 19 | Alias=ctrl-alt-del.target 20 | -------------------------------------------------------------------------------- /units/systemd-kexec.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Reboot via kexec 10 | Documentation=man:systemd-halt.service(8) 11 | DefaultDependencies=no 12 | Requires=shutdown.target umount.target final.target 13 | After=shutdown.target umount.target final.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@SYSTEMCTL@ --force kexec 18 | -------------------------------------------------------------------------------- /units/systemd-poweroff.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Power-Off 10 | Documentation=man:systemd-halt.service(8) 11 | DefaultDependencies=no 12 | Requires=shutdown.target umount.target final.target 13 | After=shutdown.target umount.target final.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@SYSTEMCTL@ --force poweroff 18 | -------------------------------------------------------------------------------- /src/nss-resolve/nss-resolve.sym: -------------------------------------------------------------------------------- 1 | /*** 2 | This file is part of systemd. 3 | 4 | systemd is free software; you can redistribute it and/or modify it 5 | under the terms of the GNU Lesser General Public License as published by 6 | the Free Software Foundation; either version 2.1 of the License, or 7 | (at your option) any later version. 8 | ***/ 9 | 10 | { 11 | global: 12 | _nss_resolve_gethostbyname_r; 13 | _nss_resolve_gethostbyname2_r; 14 | _nss_resolve_gethostbyname3_r; 15 | _nss_resolve_gethostbyname4_r; 16 | _nss_resolve_gethostbyaddr_r; 17 | _nss_resolve_gethostbyaddr2_r; 18 | local: *; 19 | }; 20 | -------------------------------------------------------------------------------- /rules/60-block.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | # enable in-kernel media-presence polling 4 | ACTION=="add", SUBSYSTEM=="module", KERNEL=="block", ATTR{parameters/events_dfl_poll_msecs}=="0", \ 5 | ATTR{parameters/events_dfl_poll_msecs}="2000" 6 | 7 | # forward scsi device event to corresponding block device 8 | ACTION=="change", SUBSYSTEM=="scsi", ENV{DEVTYPE}=="scsi_device", TEST=="block", ATTR{block/*/uevent}="change" 9 | 10 | # watch metadata changes, caused by tools closing the device node which was opened for writing 11 | ACTION!="remove", SUBSYSTEM=="block", KERNEL=="loop*|nvme*|sd*|vd*|xvd*", OPTIONS+="watch" 12 | -------------------------------------------------------------------------------- /units/quotaon.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Enable File System Quotas 10 | Documentation=man:quotaon(8) 11 | DefaultDependencies=no 12 | After=systemd-quotacheck.service 13 | Before=local-fs.target shutdown.target 14 | ConditionPathExists=@QUOTAON@ 15 | 16 | [Service] 17 | Type=oneshot 18 | RemainAfterExit=yes 19 | ExecStart=@QUOTAON@ -aug 20 | -------------------------------------------------------------------------------- /units/system-update.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=System Update 10 | Documentation=http://freedesktop.org/wiki/Software/systemd/SystemUpdates 11 | Documentation=man:systemd.special(7) man:systemd-system-update-generator(8) 12 | Requires=sysinit.target 13 | Conflicts=shutdown.target 14 | After=sysinit.target 15 | Before=shutdown.target 16 | AllowIsolate=yes 17 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: c 2 | compiler: 3 | - gcc 4 | before_install: 5 | - sudo apt-get update -qq 6 | - sudo apt-get install autotools-dev automake autoconf libtool libdbus-1-dev libcap-dev libblkid-dev libmount-dev libpam-dev libcryptsetup-dev libaudit-dev libacl1-dev libattr1-dev libselinux-dev liblzma-dev libgcrypt-dev libqrencode-dev libmicrohttpd-dev gperf python2.7-dev 7 | script: ./autogen.sh && ./configure && make V=1 && sudo ./systemd-machine-id-setup && make check && make distcheck 8 | after_failure: cat test-suite.log 9 | notifications: 10 | irc: 11 | channels: 12 | - "irc.freenode.org#systemd" 13 | on_success: change 14 | on_failure: always 15 | -------------------------------------------------------------------------------- /units/systemd-ask-password-wall.path: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Forward Password Requests to Wall Directory Watch 10 | Documentation=man:systemd-ask-password-console.service(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | Before=paths.target shutdown.target 14 | 15 | [Path] 16 | DirectoryNotEmpty=/run/systemd/ask-password 17 | MakeDirectory=yes 18 | -------------------------------------------------------------------------------- /coccinelle/empty-if.cocci: -------------------------------------------------------------------------------- 1 | @@ 2 | expression e, f, g, h, i, j; 3 | statement s, t; 4 | @@ 5 | ( 6 | if (e) { 7 | ( 8 | if (h) s 9 | | 10 | if (h) s else t 11 | | 12 | while (h) s 13 | | 14 | for (h; i; j) s 15 | ) 16 | } 17 | | 18 | while (e) { 19 | ( 20 | if (h) s 21 | | 22 | if (h) s else t 23 | | 24 | while (h) s 25 | | 26 | for (h; i; j) s 27 | ) 28 | } 29 | | 30 | for (e; f; g) { 31 | ( 32 | if (h) s 33 | | 34 | if (h) s else t 35 | | 36 | while (h) s 37 | | 38 | for (h; i; j) s 39 | ) 40 | } 41 | | 42 | - if (e) { 43 | + if (e) 44 | s 45 | - } 46 | | 47 | - while (e) { 48 | + while (e) 49 | s 50 | - } 51 | | 52 | - for (e; f; g) { 53 | + for (e; f; g) 54 | s 55 | - } 56 | ) 57 | -------------------------------------------------------------------------------- /src/nss-myhostname/nss-myhostname.sym: -------------------------------------------------------------------------------- 1 | /*** 2 | This file is part of systemd. 3 | 4 | systemd is free software; you can redistribute it and/or modify it 5 | under the terms of the GNU Lesser General Public License as published by 6 | the Free Software Foundation; either version 2.1 of the License, or 7 | (at your option) any later version. 8 | ***/ 9 | 10 | { 11 | global: 12 | _nss_myhostname_gethostbyname_r; 13 | _nss_myhostname_gethostbyname2_r; 14 | _nss_myhostname_gethostbyname3_r; 15 | _nss_myhostname_gethostbyname4_r; 16 | _nss_myhostname_gethostbyaddr_r; 17 | _nss_myhostname_gethostbyaddr2_r; 18 | local: *; 19 | }; 20 | -------------------------------------------------------------------------------- /units/systemd-udevd-kernel.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=udev Kernel Socket 10 | Documentation=man:systemd-udevd.service(8) man:udev(7) 11 | DefaultDependencies=no 12 | Before=sockets.target 13 | ConditionPathIsReadWrite=/sys 14 | 15 | [Socket] 16 | Service=systemd-udevd.service 17 | ReceiveBuffer=128M 18 | ListenNetlink=kobject-uevent 1 19 | PassCredentials=yes 20 | -------------------------------------------------------------------------------- /rules/80-drivers.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | ACTION=="remove", GOTO="drivers_end" 4 | 5 | ENV{MODALIAS}=="?*", RUN{builtin}+="kmod load $env{MODALIAS}" 6 | SUBSYSTEM=="tifm", ENV{TIFM_CARD_TYPE}=="SD", RUN{builtin}+="kmod load tifm_sd" 7 | SUBSYSTEM=="tifm", ENV{TIFM_CARD_TYPE}=="MS", RUN{builtin}+="kmod load tifm_ms" 8 | SUBSYSTEM=="memstick", RUN{builtin}+="kmod load ms_block mspro_block" 9 | SUBSYSTEM=="i2o", RUN{builtin}+="kmod load i2o_block" 10 | SUBSYSTEM=="module", KERNEL=="parport_pc", RUN{builtin}+="kmod load ppdev" 11 | KERNEL=="mtd*ro", ENV{MTD_FTL}=="smartmedia", RUN{builtin}+="kmod load sm_ftl" 12 | 13 | LABEL="drivers_end" 14 | -------------------------------------------------------------------------------- /units/systemd-fsck-root.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=File System Check on Root Device 10 | Documentation=man:systemd-fsck-root.service(8) 11 | DefaultDependencies=no 12 | Before=local-fs.target shutdown.target 13 | ConditionPathIsReadWrite=!/ 14 | 15 | [Service] 16 | Type=oneshot 17 | RemainAfterExit=yes 18 | ExecStart=@rootlibexecdir@/systemd-fsck 19 | TimeoutSec=0 20 | -------------------------------------------------------------------------------- /units/systemd-udevd-control.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=udev Control Socket 10 | Documentation=man:systemd-udevd.service(8) man:udev(7) 11 | DefaultDependencies=no 12 | Before=sockets.target 13 | ConditionPathIsReadWrite=/sys 14 | 15 | [Socket] 16 | Service=systemd-udevd.service 17 | ListenSequentialPacket=/run/udev/control 18 | SocketMode=0600 19 | PassCredentials=yes 20 | -------------------------------------------------------------------------------- /src/login/73-seat-late.rules.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | ACTION=="remove", GOTO="seat_late_end" 9 | 10 | ENV{ID_SEAT}=="", ENV{ID_AUTOSEAT}=="1", ENV{ID_FOR_SEAT}!="", ENV{ID_SEAT}="seat-$env{ID_FOR_SEAT}" 11 | ENV{ID_SEAT}=="", IMPORT{parent}="ID_SEAT" 12 | 13 | ENV{ID_SEAT}!="", TAG+="$env{ID_SEAT}" 14 | 15 | TAG=="uaccess", ENV{MAJOR}!="", RUN{builtin}+="uaccess" 16 | 17 | LABEL="seat_late_end" 18 | -------------------------------------------------------------------------------- /src/resolve/resolved.conf.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | # 8 | # Entries in this file show the compile time defaults. 9 | # You can change settings by editing this file. 10 | # Defaults can be restored by simply deleting this file. 11 | # 12 | # See resolved.conf(5) for details 13 | 14 | [Resolve] 15 | #DNS= 16 | #FallbackDNS=@DNS_SERVERS@ 17 | #Domains= 18 | #LLMNR=yes 19 | #DNSSEC=@DEFAULT_DNSSEC_MODE@ 20 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | ### Submission type 2 | 3 | - [ ] Bug report 4 | - [ ] Request for enhancement (RFE) 5 | 6 | *NOTE: Do not submit anything other than bug reports or RFEs via the issue tracker!* 7 | 8 | ### systemd version the issue has been seen with 9 | 10 | > … 11 | 12 | *NOTE: Do not submit bug reports about anything but the two most recently released systemd versions upstream!* 13 | 14 | ### Used distribution 15 | 16 | > … 17 | 18 | ### In case of bug report: Expected behaviour you didn't see 19 | 20 | > … 21 | 22 | ### In case of bug report: Unexpected behaviour you saw 23 | 24 | > … 25 | 26 | ### In case of bug report: Steps to reproduce the problem 27 | 28 | > … 29 | -------------------------------------------------------------------------------- /rules/60-persistent-alsa.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | ACTION=="remove", GOTO="persistent_alsa_end" 4 | SUBSYSTEM!="sound", GOTO="persistent_alsa_end" 5 | KERNEL!="controlC[0-9]*", GOTO="persistent_alsa_end" 6 | 7 | SUBSYSTEMS=="usb", ENV{ID_MODEL}=="", IMPORT{builtin}="usb_id" 8 | ENV{ID_SERIAL}=="?*", ENV{ID_USB_INTERFACE_NUM}=="?*", SYMLINK+="snd/by-id/$env{ID_BUS}-$env{ID_SERIAL}-$env{ID_USB_INTERFACE_NUM}" 9 | ENV{ID_SERIAL}=="?*", ENV{ID_USB_INTERFACE_NUM}=="", SYMLINK+="snd/by-id/$env{ID_BUS}-$env{ID_SERIAL}" 10 | 11 | IMPORT{builtin}="path_id" 12 | ENV{ID_PATH}=="?*", SYMLINK+="snd/by-path/$env{ID_PATH}" 13 | 14 | LABEL="persistent_alsa_end" 15 | -------------------------------------------------------------------------------- /units/halt-local.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=@RC_LOCAL_SCRIPT_PATH_STOP@ Compatibility 10 | ConditionFileIsExecutable=@RC_LOCAL_SCRIPT_PATH_STOP@ 11 | DefaultDependencies=no 12 | After=shutdown.target 13 | Before=final.target 14 | 15 | [Service] 16 | Type=oneshot 17 | ExecStart=@RC_LOCAL_SCRIPT_PATH_STOP@ 18 | TimeoutSec=0 19 | StandardOutput=tty 20 | RemainAfterExit=yes 21 | -------------------------------------------------------------------------------- /units/org.freedesktop.login1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Login Service Bus Name 10 | Documentation=man:systemd-logind.service(8) man:logind.conf(5) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/logind 12 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/multiseat 13 | 14 | [BusName] 15 | Service=systemd-logind.service 16 | AllowWorld=talk 17 | -------------------------------------------------------------------------------- /units/systemd-user-sessions.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Permit User Sessions 10 | Documentation=man:systemd-user-sessions.service(8) 11 | After=remote-fs.target nss-user-lookup.target network.target 12 | 13 | [Service] 14 | Type=oneshot 15 | RemainAfterExit=yes 16 | ExecStart=@rootlibexecdir@/systemd-user-sessions start 17 | ExecStop=@rootlibexecdir@/systemd-user-sessions stop 18 | -------------------------------------------------------------------------------- /units/proc-sys-fs-binfmt_misc.mount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Arbitrary Executable File Formats File System 10 | Documentation=https://www.kernel.org/doc/Documentation/binfmt_misc.txt 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | DefaultDependencies=no 13 | 14 | [Mount] 15 | What=binfmt_misc 16 | Where=/proc/sys/fs/binfmt_misc 17 | Type=binfmt_misc 18 | -------------------------------------------------------------------------------- /units/systemd-networkd.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Network Service Netlink Socket 10 | Documentation=man:systemd-networkd.service(8) man:rtnetlink(7) 11 | ConditionCapability=CAP_NET_ADMIN 12 | DefaultDependencies=no 13 | Before=sockets.target 14 | 15 | [Socket] 16 | ReceiveBuffer=8M 17 | ListenNetlink=route 1361 18 | PassCredentials=yes 19 | 20 | [Install] 21 | WantedBy=sockets.target 22 | -------------------------------------------------------------------------------- /test/TEST-07-ISSUE-1981/test-segfault.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -x 4 | set -e 5 | 6 | >/failed 7 | 8 | cat <<'EOL' >/lib/systemd/system/my.service 9 | [Service] 10 | Type=oneshot 11 | ExecStart=/bin/echo Timer runs me 12 | EOL 13 | 14 | cat <<'EOL' >/lib/systemd/system/my.timer 15 | [Timer] 16 | OnBootSec=10s 17 | OnUnitInactiveSec=1h 18 | EOL 19 | 20 | systemctl unmask my.timer 21 | 22 | systemctl start my.timer 23 | 24 | mkdir -p /etc/systemd/system/my.timer.d/ 25 | cat <<'EOL' >/etc/systemd/system/my.timer.d/override.conf 26 | [Timer] 27 | OnBootSec=10s 28 | OnUnitInactiveSec=1h 29 | EOL 30 | 31 | systemctl daemon-reload 32 | 33 | systemctl mask my.timer 34 | 35 | touch /testok 36 | rm /failed 37 | -------------------------------------------------------------------------------- /tmpfiles.d/x11.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See tmpfiles.d(5) for details 9 | 10 | # Make sure these are created by default so that nobody else can 11 | d /tmp/.X11-unix 1777 root root 10d 12 | d /tmp/.ICE-unix 1777 root root 10d 13 | d /tmp/.XIM-unix 1777 root root 10d 14 | d /tmp/.font-unix 1777 root root 10d 15 | d /tmp/.Test-unix 1777 root root 10d 16 | 17 | # Unlink the X11 lock files 18 | r! /tmp/.X[0-9]*-lock 19 | -------------------------------------------------------------------------------- /units/kmod-static-nodes.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Create list of required static device nodes for the current kernel 10 | DefaultDependencies=no 11 | Before=sysinit.target systemd-tmpfiles-setup-dev.service 12 | ConditionCapability=CAP_SYS_MODULE 13 | 14 | [Service] 15 | Type=oneshot 16 | RemainAfterExit=yes 17 | ExecStart=@KMOD@ static-nodes --format=tmpfiles --output=/run/tmpfiles.d/kmod.conf 18 | -------------------------------------------------------------------------------- /units/systemd-journald-audit.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Journal Audit Socket 10 | Documentation=man:systemd-journald.service(8) man:journald.conf(5) 11 | DefaultDependencies=no 12 | Before=sockets.target 13 | ConditionSecurity=audit 14 | ConditionCapability=CAP_AUDIT_READ 15 | 16 | [Socket] 17 | Service=systemd-journald.service 18 | ReceiveBuffer=128M 19 | ListenNetlink=audit 1 20 | PassCredentials=yes 21 | -------------------------------------------------------------------------------- /units/systemd-rfkill.socket: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Load/Save RF Kill Switch Status /dev/rfkill Watch 10 | Documentation=man:systemd-rfkill.socket(8) 11 | DefaultDependencies=no 12 | BindsTo=sys-devices-virtual-misc-rfkill.device 13 | After=sys-devices-virtual-misc-rfkill.device 14 | Conflicts=shutdown.target 15 | Before=shutdown.target 16 | 17 | [Socket] 18 | ListenSpecial=/dev/rfkill 19 | Writable=yes 20 | -------------------------------------------------------------------------------- /units/systemd-tmpfiles-clean.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Cleanup of Temporary Directories 10 | Documentation=man:tmpfiles.d(5) man:systemd-tmpfiles(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=local-fs.target time-sync.target 14 | Before=shutdown.target 15 | 16 | [Service] 17 | Type=oneshot 18 | ExecStart=@rootbindir@/systemd-tmpfiles --clean 19 | IOSchedulingClass=idle 20 | -------------------------------------------------------------------------------- /src/coredump/coredump.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | # 8 | # Entries in this file show the compile time defaults. 9 | # You can change settings by editing this file. 10 | # Defaults can be restored by simply deleting this file. 11 | # 12 | # See coredump.conf(5) for details. 13 | 14 | [Coredump] 15 | #Storage=external 16 | #Compress=yes 17 | #ProcessSizeMax=2G 18 | #ExternalSizeMax=2G 19 | #JournalSizeMax=767M 20 | #MaxUse= 21 | #KeepFree= 22 | -------------------------------------------------------------------------------- /tmpfiles.d/tmp.conf: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See tmpfiles.d(5) for details 9 | 10 | # Clear tmp directories separately, to make them easier to override 11 | q /tmp 1777 root root 10d 12 | q /var/tmp 1777 root root 30d 13 | 14 | # Exclude namespace mountpoints created with PrivateTmp=yes 15 | x /tmp/systemd-private-%b-* 16 | X /tmp/systemd-private-%b-*/tmp 17 | x /var/tmp/systemd-private-%b-* 18 | X /var/tmp/systemd-private-%b-*/tmp 19 | -------------------------------------------------------------------------------- /units/dev-mqueue.mount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=POSIX Message Queue File System 10 | Documentation=man:mq_overview(7) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | DefaultDependencies=no 13 | Before=sysinit.target 14 | ConditionPathExists=/proc/sys/fs/mqueue 15 | ConditionCapability=CAP_SYS_ADMIN 16 | 17 | [Mount] 18 | What=mqueue 19 | Where=/dev/mqueue 20 | Type=mqueue 21 | -------------------------------------------------------------------------------- /units/systemd-quotacheck.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=File System Quota Check 10 | Documentation=man:systemd-quotacheck.service(8) 11 | DefaultDependencies=no 12 | After=systemd-remount-fs.service 13 | Before=local-fs.target shutdown.target 14 | ConditionPathExists=@QUOTACHECK@ 15 | 16 | [Service] 17 | Type=oneshot 18 | RemainAfterExit=yes 19 | ExecStart=@rootlibexecdir@/systemd-quotacheck 20 | TimeoutSec=0 21 | -------------------------------------------------------------------------------- /units/systemd-vconsole-setup.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Setup Virtual Console 10 | Documentation=man:systemd-vconsole-setup.service(8) man:vconsole.conf(5) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | Before=sysinit.target shutdown.target 14 | ConditionPathExists=/dev/tty0 15 | 16 | [Service] 17 | Type=oneshot 18 | RemainAfterExit=yes 19 | ExecStart=@rootlibexecdir@/systemd-vconsole-setup 20 | -------------------------------------------------------------------------------- /network/80-container-host0.network: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # This network file matches the container-side of the virtual Ethernet link 9 | # created by systemd-nspawn's --network-veth switch. See systemd-nspawn(1) for 10 | # details. 11 | 12 | [Match] 13 | Virtualization=container 14 | Name=host0 15 | 16 | [Network] 17 | DHCP=yes 18 | LinkLocalAddressing=yes 19 | LLDP=yes 20 | EmitLLDP=customer-bridge 21 | 22 | [DHCP] 23 | UseTimezone=yes 24 | -------------------------------------------------------------------------------- /units/initrd-cleanup.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Cleaning Up and Shutting Down Daemons 10 | DefaultDependencies=no 11 | ConditionPathExists=/etc/initrd-release 12 | OnFailure=emergency.target 13 | OnFailureJobMode=replace-irreversibly 14 | After=initrd-root-fs.target initrd-fs.target initrd.target 15 | 16 | [Service] 17 | Type=oneshot 18 | ExecStart=@rootbindir@/systemctl --no-block isolate initrd-switch-root.target 19 | -------------------------------------------------------------------------------- /units/systemd-fsck@.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=File System Check on %f 10 | Documentation=man:systemd-fsck@.service(8) 11 | DefaultDependencies=no 12 | BindsTo=%i.device 13 | After=%i.device systemd-fsck-root.service local-fs-pre.target 14 | Before=systemd-quotacheck.service shutdown.target 15 | 16 | [Service] 17 | Type=oneshot 18 | RemainAfterExit=yes 19 | ExecStart=@rootlibexecdir@/systemd-fsck %f 20 | TimeoutSec=0 21 | -------------------------------------------------------------------------------- /src/basic/siphash24.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | struct siphash { 9 | uint64_t v0; 10 | uint64_t v1; 11 | uint64_t v2; 12 | uint64_t v3; 13 | uint64_t padding; 14 | size_t inlen; 15 | }; 16 | 17 | void siphash24_init(struct siphash *state, const uint8_t k[16]); 18 | void siphash24_compress(const void *in, size_t inlen, struct siphash *state); 19 | #define siphash24_compress_byte(byte, state) siphash24_compress((const uint8_t[]) { (byte) }, 1, (state)) 20 | 21 | uint64_t siphash24_finalize(struct siphash *state); 22 | 23 | uint64_t siphash24(const void *in, size_t inlen, const uint8_t k[16]); 24 | -------------------------------------------------------------------------------- /src/nss-mymachines/nss-mymachines.sym: -------------------------------------------------------------------------------- 1 | /*** 2 | This file is part of systemd. 3 | 4 | systemd is free software; you can redistribute it and/or modify it 5 | under the terms of the GNU Lesser General Public License as published by 6 | the Free Software Foundation; either version 2.1 of the License, or 7 | (at your option) any later version. 8 | ***/ 9 | 10 | { 11 | global: 12 | _nss_mymachines_gethostbyname_r; 13 | _nss_mymachines_gethostbyname2_r; 14 | _nss_mymachines_gethostbyname3_r; 15 | _nss_mymachines_gethostbyname4_r; 16 | _nss_mymachines_getpwnam_r; 17 | _nss_mymachines_getpwuid_r; 18 | _nss_mymachines_getgrnam_r; 19 | _nss_mymachines_getgrgid_r; 20 | local: *; 21 | }; 22 | -------------------------------------------------------------------------------- /units/tmp.mount.m4: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Temporary Directory 10 | Documentation=man:hier(7) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | ConditionPathIsSymbolicLink=!/tmp 13 | DefaultDependencies=no 14 | Conflicts=umount.target 15 | Before=local-fs.target umount.target 16 | After=swap.target 17 | 18 | [Mount] 19 | What=tmpfs 20 | Where=/tmp 21 | Type=tmpfs 22 | Options=mode=1777,strictatime 23 | -------------------------------------------------------------------------------- /sysusers.d/systemd.conf.m4: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | g systemd-journal - - 9 | m4_ifdef(`ENABLE_NETWORKD', 10 | u systemd-network - "systemd Network Management" 11 | )m4_dnl 12 | m4_ifdef(`ENABLE_RESOLVED', 13 | u systemd-resolve - "systemd Resolver" 14 | )m4_dnl 15 | m4_ifdef(`ENABLE_TIMESYNCD', 16 | u systemd-timesync - "systemd Time Synchronization" 17 | )m4_dnl 18 | m4_ifdef(`ENABLE_COREDUMP', 19 | u systemd-coredump - "systemd Core Dumper" 20 | )m4_dnl 21 | -------------------------------------------------------------------------------- /units/ldconfig.service: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Rebuild Dynamic Linker Cache 10 | Documentation=man:ldconfig(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=local-fs.target 14 | Before=sysinit.target shutdown.target systemd-update-done.service 15 | ConditionNeedsUpdate=|/etc 16 | ConditionFileNotEmpty=|!/etc/ld.so.cache 17 | 18 | [Service] 19 | Type=oneshot 20 | RemainAfterExit=yes 21 | ExecStart=/sbin/ldconfig -X 22 | -------------------------------------------------------------------------------- /units/systemd-hibernate-resume@.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Resume from hibernation using device %f 10 | Documentation=man:systemd-hibernate-resume@.service(8) 11 | DefaultDependencies=no 12 | BindsTo=%i.device 13 | Wants=local-fs-pre.target 14 | After=%i.device 15 | Before=local-fs-pre.target 16 | ConditionPathExists=/etc/initrd-release 17 | 18 | [Service] 19 | Type=oneshot 20 | ExecStart=@rootlibexecdir@/systemd-hibernate-resume %f 21 | -------------------------------------------------------------------------------- /units/systemd-update-done.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Update is Completed 10 | Documentation=man:systemd-update-done.service(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=local-fs.target 14 | Before=sysinit.target shutdown.target 15 | ConditionNeedsUpdate=|/etc 16 | ConditionNeedsUpdate=|/var 17 | 18 | [Service] 19 | Type=oneshot 20 | RemainAfterExit=yes 21 | ExecStart=@rootlibexecdir@/systemd-update-done 22 | -------------------------------------------------------------------------------- /shell-completion/zsh/_kernel-install: -------------------------------------------------------------------------------- 1 | #compdef kernel-install 2 | 3 | _images(){ 4 | if [[ "$words[2]" == "remove" ]]; then 5 | _message 'No more options' 6 | else 7 | _path_files -W /boot/ -P /boot/ -g "vmlinuz-*" 8 | fi 9 | } 10 | 11 | _kernels(){ 12 | read _MACHINE_ID < /etc/machine-id 13 | _kernel=( /lib/modules/[0-9]* ) 14 | if [[ "$cmd" == "remove" && -n "$_MACHINE_ID" ]]; then 15 | _kernel=( "/boot/$_MACHINE_ID"/[0-9]* ) 16 | fi 17 | _kernel=( ${_kernel##*/} ) 18 | _describe "installed kernels" _kernel 19 | } 20 | 21 | _arguments \ 22 | '1::add or remove:(add remove)' \ 23 | '2::kernel versions:_kernels' \ 24 | '3::kernel images:_images' 25 | 26 | #vim: set ft=zsh sw=4 ts=4 et 27 | -------------------------------------------------------------------------------- /units/systemd-ask-password-console.path: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Dispatch Password Requests to Console Directory Watch 10 | Documentation=man:systemd-ask-password-console.service(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=plymouth-start.service 14 | Before=paths.target shutdown.target 15 | ConditionPathExists=!/run/plymouth/pid 16 | 17 | [Path] 18 | DirectoryNotEmpty=/run/systemd/ask-password 19 | MakeDirectory=yes 20 | -------------------------------------------------------------------------------- /units/initrd-switch-root.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Switch Root 10 | DefaultDependencies=no 11 | ConditionPathExists=/etc/initrd-release 12 | OnFailure=emergency.target 13 | OnFailureJobMode=replace-irreversibly 14 | AllowIsolate=yes 15 | 16 | [Service] 17 | Type=oneshot 18 | # we have to use "--force" here, otherwise systemd would umount /run 19 | ExecStart=@rootbindir@/systemctl --no-block --force switch-root /sysroot 20 | KillMode=none 21 | -------------------------------------------------------------------------------- /test/bus-policy/methods.conf: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /units/sys-kernel-debug.mount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Debug File System 10 | Documentation=https://www.kernel.org/doc/Documentation/filesystems/debugfs.txt 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | DefaultDependencies=no 13 | ConditionPathExists=/sys/kernel/debug 14 | ConditionCapability=CAP_SYS_RAWIO 15 | Before=sysinit.target 16 | 17 | [Mount] 18 | What=debugfs 19 | Where=/sys/kernel/debug 20 | Type=debugfs 21 | -------------------------------------------------------------------------------- /units/systemd-sysctl.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Apply Kernel Variables 10 | Documentation=man:systemd-sysctl.service(8) man:sysctl.d(5) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=systemd-modules-load.service 14 | Before=sysinit.target shutdown.target 15 | ConditionPathIsReadWrite=/proc/sys/ 16 | 17 | [Service] 18 | Type=oneshot 19 | RemainAfterExit=yes 20 | ExecStart=@rootlibexecdir@/systemd-sysctl 21 | TimeoutSec=90s 22 | -------------------------------------------------------------------------------- /units/dev-hugepages.mount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Huge Pages File System 10 | Documentation=https://www.kernel.org/doc/Documentation/vm/hugetlbpage.txt 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | DefaultDependencies=no 13 | Before=sysinit.target 14 | ConditionPathExists=/sys/kernel/mm/hugepages 15 | ConditionCapability=CAP_SYS_ADMIN 16 | 17 | [Mount] 18 | What=hugetlbfs 19 | Where=/dev/hugepages 20 | Type=hugetlbfs 21 | -------------------------------------------------------------------------------- /units/systemd-ask-password-console.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Dispatch Password Requests to Console 10 | Documentation=man:systemd-ask-password-console.service(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=plymouth-start.service systemd-vconsole-setup.service 14 | Before=shutdown.target 15 | ConditionPathExists=!/run/plymouth/pid 16 | 17 | [Service] 18 | ExecStart=@rootbindir@/systemd-tty-ask-password-agent --watch --console 19 | -------------------------------------------------------------------------------- /units/systemd-timedated.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Time & Date Service 10 | Documentation=man:systemd-timedated.service(8) man:localtime(5) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/timedated 12 | 13 | [Service] 14 | ExecStart=@rootlibexecdir@/systemd-timedated 15 | BusName=org.freedesktop.timedate1 16 | CapabilityBoundingSet=CAP_SYS_TIME 17 | WatchdogSec=3min 18 | PrivateTmp=yes 19 | ProtectSystem=yes 20 | ProtectHome=yes 21 | -------------------------------------------------------------------------------- /shell-completion/zsh/_systemd-tmpfiles: -------------------------------------------------------------------------------- 1 | #compdef systemd-tmpfiles 2 | 3 | _arguments \ 4 | {-h,--help}'[Show help]' \ 5 | '--version[Show package version]' \ 6 | '--create[Create, set ownership/permissions based on the config files.]' \ 7 | '--clean[Clean up all files and directories with an age parameter configured.]' \ 8 | '--remove[All files and directories marked with r, R in the configuration files are removed.]' \ 9 | '--boot[Execute actions only safe at boot]' \ 10 | '--prefix=[Only apply rules that apply to paths with the specified prefix.]' \ 11 | '--exclude-prefix=[Ignore rules that apply to paths with the specified prefix.]' \ 12 | '--root=[Operate on an alternate filesystem root]:directory:_directories' \ 13 | '*::files:_files' 14 | -------------------------------------------------------------------------------- /test/bus-policy/ownerships.conf: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /units/initrd-switch-root.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Switch Root 10 | ConditionPathExists=/etc/initrd-release 11 | DefaultDependencies=no 12 | Requires=initrd-switch-root.service 13 | Before=initrd-switch-root.service 14 | AllowIsolate=yes 15 | Wants=initrd-udevadm-cleanup-db.service initrd-root-fs.target initrd-fs.target systemd-journald.service 16 | After=initrd-udevadm-cleanup-db.service initrd-root-fs.target initrd-fs.target emergency.service emergency.target 17 | -------------------------------------------------------------------------------- /network/80-container-vz.network: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # This network file matches the bridge interface created by systemd-nspawn's 9 | # --network-zone= switch. See systemd-nspawn(1) for details. 10 | 11 | [Match] 12 | Name=vz-* 13 | Driver=bridge 14 | 15 | [Network] 16 | # Default to using a /24 prefix, giving up to 253 addresses per virtual network. 17 | Address=0.0.0.0/24 18 | LinkLocalAddressing=yes 19 | DHCPServer=yes 20 | IPMasquerade=yes 21 | LLDP=yes 22 | EmitLLDP=customer-bridge 23 | -------------------------------------------------------------------------------- /units/initrd-udevadm-cleanup-db.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Cleanup udevd DB 10 | DefaultDependencies=no 11 | ConditionPathExists=/etc/initrd-release 12 | Conflicts=systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket 13 | After=systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket 14 | Before=initrd-switch-root.target 15 | 16 | [Service] 17 | Type=oneshot 18 | ExecStart=-@rootbindir@/udevadm info --cleanup-db 19 | -------------------------------------------------------------------------------- /units/systemd-ask-password-wall.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Forward Password Requests to Wall 10 | Documentation=man:systemd-ask-password-console.service(8) 11 | After=systemd-user-sessions.service 12 | 13 | [Service] 14 | ExecStartPre=-@SYSTEMCTL@ stop systemd-ask-password-console.path systemd-ask-password-console.service systemd-ask-password-plymouth.path systemd-ask-password-plymouth.service 15 | ExecStart=@rootbindir@/systemd-tty-ask-password-agent --wall 16 | -------------------------------------------------------------------------------- /units/systemd-sysusers.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Create System Users 10 | Documentation=man:sysusers.d(5) man:systemd-sysusers.service(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=systemd-remount-fs.service 14 | Before=sysinit.target shutdown.target systemd-update-done.service 15 | ConditionNeedsUpdate=/etc 16 | 17 | [Service] 18 | Type=oneshot 19 | RemainAfterExit=yes 20 | ExecStart=@rootbindir@/systemd-sysusers 21 | TimeoutSec=90s 22 | -------------------------------------------------------------------------------- /src/boot/efi/disk.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This program is free software; you can redistribute it and/or modify it 3 | * under the terms of the GNU Lesser General Public License as published by 4 | * the Free Software Foundation; either version 2.1 of the License, or 5 | * (at your option) any later version. 6 | * 7 | * This program is distributed in the hope that it will be useful, but 8 | * WITHOUT ANY WARRANTY; without even the implied warranty of 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 10 | * Lesser General Public License for more details. 11 | * 12 | * Copyright (C) 2015 Kay Sievers 13 | */ 14 | 15 | #ifndef __SDBOOT_DISK_H 16 | #define __SDBOOT_DISK_H 17 | 18 | EFI_STATUS disk_get_part_uuid(EFI_HANDLE *handle, CHAR16 uuid[37]); 19 | #endif 20 | -------------------------------------------------------------------------------- /units/org.freedesktop.network1.busname: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Network Service Bus Name 10 | Documentation=man:systemd-networkd.service(8) 11 | 12 | # This is pulled in by systemd-networkd.service, since it cannot run 13 | # without its policy set. However, let's conditionalize this unit on 14 | # non-kdbus system. 15 | ConditionPathExists=/sys/fs/kdbus/0-system/ 16 | 17 | [BusName] 18 | Service=systemd-networkd.service 19 | AllowWorld=talk 20 | AllowUser=systemd-network own 21 | -------------------------------------------------------------------------------- /units/rc-local.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # This unit gets pulled automatically into multi-user.target by 9 | # systemd-rc-local-generator if @RC_LOCAL_SCRIPT_PATH_START@ is executable. 10 | [Unit] 11 | Description=@RC_LOCAL_SCRIPT_PATH_START@ Compatibility 12 | ConditionFileIsExecutable=@RC_LOCAL_SCRIPT_PATH_START@ 13 | After=network.target 14 | 15 | [Service] 16 | Type=forking 17 | ExecStart=@RC_LOCAL_SCRIPT_PATH_START@ start 18 | TimeoutSec=0 19 | RemainAfterExit=yes 20 | GuessMainPID=no 21 | -------------------------------------------------------------------------------- /units/systemd-tmpfiles-setup.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Create Volatile Files and Directories 10 | Documentation=man:tmpfiles.d(5) man:systemd-tmpfiles(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=local-fs.target systemd-sysusers.service 14 | Before=shutdown.target 15 | RefuseManualStop=yes 16 | 17 | [Service] 18 | Type=oneshot 19 | RemainAfterExit=yes 20 | ExecStart=@rootbindir@/systemd-tmpfiles --create --remove --boot --exclude-prefix=/dev 21 | -------------------------------------------------------------------------------- /units/proc-sys-fs-binfmt_misc.automount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Arbitrary Executable File Formats File System Automount Point 10 | Documentation=https://www.kernel.org/doc/Documentation/binfmt_misc.txt 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | DefaultDependencies=no 13 | Before=sysinit.target 14 | ConditionPathExists=/proc/sys/fs/binfmt_misc/ 15 | ConditionPathIsReadWrite=/proc/sys/ 16 | 17 | [Automount] 18 | Where=/proc/sys/fs/binfmt_misc 19 | -------------------------------------------------------------------------------- /network/80-container-ve.network: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # This network file matches the host-side of the virtual Ethernet link 9 | # created by systemd-nspawn's --network-veth switch. See systemd-nspawn(1) for 10 | # details. 11 | 12 | [Match] 13 | Name=ve-* 14 | Driver=veth 15 | 16 | [Network] 17 | # Default to using a /28 prefix, giving up to 13 addresses per container. 18 | Address=0.0.0.0/28 19 | LinkLocalAddressing=yes 20 | DHCPServer=yes 21 | IPMasquerade=yes 22 | LLDP=yes 23 | EmitLLDP=customer-bridge 24 | -------------------------------------------------------------------------------- /units/initrd.target: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Initrd Default Target 10 | Documentation=man:systemd.special(7) 11 | OnFailure=emergency.target 12 | OnFailureJobMode=replace-irreversibly 13 | ConditionPathExists=/etc/initrd-release 14 | Requires=basic.target 15 | Wants=initrd-root-fs.target initrd-root-device.target initrd-fs.target initrd-parse-etc.service 16 | After=initrd-root-fs.target initrd-root-device.target initrd-fs.target basic.target rescue.service rescue.target 17 | AllowIsolate=yes 18 | -------------------------------------------------------------------------------- /units/systemd-journal-catalog-update.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Rebuild Journal Catalog 10 | Documentation=man:systemd-journald.service(8) man:journald.conf(5) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | After=local-fs.target 14 | Before=sysinit.target shutdown.target systemd-update-done.service 15 | ConditionNeedsUpdate=/etc 16 | 17 | [Service] 18 | Type=oneshot 19 | RemainAfterExit=yes 20 | ExecStart=@rootbindir@/journalctl --update-catalog 21 | TimeoutSec=90s 22 | -------------------------------------------------------------------------------- /units/systemd-localed.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Locale Service 10 | Documentation=man:systemd-localed.service(8) man:locale.conf(5) man:vconsole.conf(5) 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/localed 12 | 13 | [Service] 14 | ExecStart=@rootlibexecdir@/systemd-localed 15 | BusName=org.freedesktop.locale1 16 | CapabilityBoundingSet= 17 | WatchdogSec=3min 18 | PrivateTmp=yes 19 | PrivateDevices=yes 20 | PrivateNetwork=yes 21 | ProtectSystem=yes 22 | ProtectHome=yes 23 | -------------------------------------------------------------------------------- /units/systemd-rfkill.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Load/Save RF Kill Switch Status 10 | Documentation=man:systemd-rfkill.service(8) 11 | DefaultDependencies=no 12 | RequiresMountsFor=/var/lib/systemd/rfkill 13 | BindsTo=sys-devices-virtual-misc-rfkill.device 14 | Conflicts=shutdown.target 15 | After=sys-devices-virtual-misc-rfkill.device systemd-remount-fs.service 16 | Before=shutdown.target 17 | 18 | [Service] 19 | Type=notify 20 | ExecStart=@rootlibexecdir@/systemd-rfkill 21 | TimeoutSec=30s 22 | -------------------------------------------------------------------------------- /rules/70-mouse.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | ACTION=="remove", GOTO="mouse_end" 4 | KERNEL!="event*", GOTO="mouse_end" 5 | ENV{ID_INPUT_MOUSE}=="", GOTO="mouse_end" 6 | 7 | # mouse::vp:name::* 8 | KERNELS=="input*", ENV{ID_BUS}=="usb", \ 9 | IMPORT{builtin}="hwdb 'mouse:$env{ID_BUS}:v$attr{id/vendor}p$attr{id/product}:name:$attr{name}:'", \ 10 | GOTO="mouse_end" 11 | KERNELS=="input*", ENV{ID_BUS}=="bluetooth", \ 12 | IMPORT{builtin}="hwdb 'mouse:$env{ID_BUS}:v$attr{id/vendor}p$attr{id/product}:name:$attr{name}:'", \ 13 | GOTO="mouse_end" 14 | DRIVERS=="psmouse", SUBSYSTEMS=="serio", \ 15 | IMPORT{builtin}="hwdb 'mouse:ps2::name:$attr{device/name}:'", \ 16 | GOTO="mouse_end" 17 | 18 | LABEL="mouse_end" 19 | -------------------------------------------------------------------------------- /src/journal/lookup3.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | #include "macro.h" 7 | 8 | uint32_t jenkins_hashword(const uint32_t *k, size_t length, uint32_t initval) _pure_; 9 | void jenkins_hashword2(const uint32_t *k, size_t length, uint32_t *pc, uint32_t *pb); 10 | 11 | uint32_t jenkins_hashlittle(const void *key, size_t length, uint32_t initval) _pure_; 12 | void jenkins_hashlittle2(const void *key, size_t length, uint32_t *pc, uint32_t *pb); 13 | 14 | uint32_t jenkins_hashbig(const void *key, size_t length, uint32_t initval) _pure_; 15 | 16 | static inline uint64_t hash64(const void *data, size_t length) { 17 | uint32_t a = 0, b = 0; 18 | 19 | jenkins_hashlittle2(data, length, &a, &b); 20 | 21 | return ((uint64_t) a << 32ULL) | (uint64_t) b; 22 | } 23 | -------------------------------------------------------------------------------- /units/systemd-networkd-wait-online.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Wait for Network to be Configured 10 | Documentation=man:systemd-networkd-wait-online.service(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | Requisite=systemd-networkd.service 14 | After=systemd-networkd.service 15 | Before=network-online.target 16 | 17 | [Service] 18 | Type=oneshot 19 | ExecStart=@rootlibexecdir@/systemd-networkd-wait-online 20 | RemainAfterExit=yes 21 | 22 | [Install] 23 | WantedBy=network-online.target 24 | -------------------------------------------------------------------------------- /rules/60-evdev.rules: -------------------------------------------------------------------------------- 1 | # do not edit this file, it will be overwritten on update 2 | 3 | ACTION=="remove", GOTO="evdev_end" 4 | KERNEL!="event*", GOTO="evdev_end" 5 | 6 | # skip later rules when we find something for this input device 7 | IMPORT{builtin}="hwdb --subsystem=input --lookup-prefix=evdev:", \ 8 | RUN{builtin}+="keyboard", GOTO="evdev_end" 9 | 10 | # AT keyboard matching by the machine's DMI data 11 | ENV{ID_INPUT_KEY}=="?*", DRIVERS=="atkbd", \ 12 | IMPORT{builtin}="hwdb 'evdev:atkbd:$attr{[dmi/id]modalias}'", \ 13 | RUN{builtin}+="keyboard", GOTO="evdev_end" 14 | 15 | # device matching the input device name and the machine's DMI data 16 | KERNELS=="input*", IMPORT{builtin}="hwdb 'evdev:name:$attr{name}:$attr{[dmi/id]modalias}'", \ 17 | RUN{builtin}+="keyboard", GOTO="evdev_end" 18 | 19 | LABEL="evdev_end" 20 | -------------------------------------------------------------------------------- /tmpfiles.d/etc.conf.m4: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | # See tmpfiles.d(5) for details 9 | 10 | L /etc/os-release - - - - ../usr/lib/os-release 11 | L /etc/localtime - - - - ../usr/share/zoneinfo/UTC 12 | L+ /etc/mtab - - - - ../proc/self/mounts 13 | m4_ifdef(`HAVE_SMACK_RUN_LABEL', 14 | t /etc/mtab - - - - security.SMACK64=_ 15 | )m4_dnl 16 | m4_ifdef(`ENABLE_RESOLVED', 17 | L! /etc/resolv.conf - - - - ../run/systemd/resolve/resolv.conf 18 | )m4_dnl 19 | C /etc/nsswitch.conf - - - - 20 | m4_ifdef(`HAVE_PAM', 21 | C /etc/pam.d - - - - 22 | )m4_dnl 23 | -------------------------------------------------------------------------------- /units/sys-fs-fuse-connections.mount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=FUSE Control File System 10 | Documentation=https://www.kernel.org/doc/Documentation/filesystems/fuse.txt 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | DefaultDependencies=no 13 | ConditionPathExists=/sys/fs/fuse/connections 14 | ConditionCapability=CAP_SYS_ADMIN 15 | After=systemd-modules-load.service 16 | Before=sysinit.target 17 | 18 | [Mount] 19 | What=fusectl 20 | Where=/sys/fs/fuse/connections 21 | Type=fusectl 22 | -------------------------------------------------------------------------------- /units/sys-kernel-config.mount: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Configuration File System 10 | Documentation=https://www.kernel.org/doc/Documentation/filesystems/configfs/configfs.txt 11 | Documentation=http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems 12 | DefaultDependencies=no 13 | ConditionPathExists=/sys/kernel/config 14 | ConditionCapability=CAP_SYS_RAWIO 15 | After=systemd-modules-load.service 16 | Before=sysinit.target 17 | 18 | [Mount] 19 | What=configfs 20 | Where=/sys/kernel/config 21 | Type=configfs 22 | -------------------------------------------------------------------------------- /units/systemd-machine-id-commit.service.in: -------------------------------------------------------------------------------- 1 | # This file is part of systemd. 2 | # 3 | # systemd is free software; you can redistribute it and/or modify it 4 | # under the terms of the GNU Lesser General Public License as published by 5 | # the Free Software Foundation; either version 2.1 of the License, or 6 | # (at your option) any later version. 7 | 8 | [Unit] 9 | Description=Commit a transient machine-id on disk 10 | Documentation=man:systemd-machine-id-commit.service(8) 11 | DefaultDependencies=no 12 | Conflicts=shutdown.target 13 | Before=sysinit.target shutdown.target 14 | After=local-fs.target 15 | ConditionPathIsReadWrite=/etc 16 | ConditionPathIsMountPoint=/etc/machine-id 17 | 18 | [Service] 19 | Type=oneshot 20 | RemainAfterExit=yes 21 | ExecStart=@rootbindir@/systemd-machine-id-setup --commit 22 | TimeoutSec=30s 23 | --------------------------------------------------------------------------------