This does not appear to affect Artful and systemd 234. Example session:
~# cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=17.10 DISTRIB_CODENAME=artful DISTRIB_DESCRIPTION="Ubuntu 17.10"
~# uname -a Linux ip-100-65-137-86 4.13.0-36-generic #40-Ubuntu SMP Fri Feb 16 20:07:48 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
~# systemctl --version systemd 234 +PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD -IDN2 +IDN default-hierarchy=hybrid
~# systemctl daemon-reload
~# systemctl list-unit-files test-mask.service
0 unit files listed.
~# cat <<EOF > /lib/systemd/system/test-mask.service > [Unit] > Description=dummy service > > [Service] > Type=oneshot > ExecStart=/bin/true > > [Install] > WantedBy=multi-user.target > > EOF
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service UNIT FILE STATE test-mask.service disabled
1 unit files listed. ** disabled ** ● test-mask.service - dummy service Loaded: loaded (/lib/systemd/system/test-mask.service; disabled; vendor preset: enabled) Active: inactive (dead)
~# systemctl enable test-mask.service Created symlink /etc/systemd/system/multi-user.target.wants/test-mask.service → /lib/systemd/system/test-mask.service.
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service UNIT FILE STATE test-mask.service enabled
1 unit files listed. ** enabled ** ● test-mask.service - dummy service Loaded: loaded (/lib/systemd/system/test-mask.service; enabled; vendor preset: enabled) Active: inactive (dead)
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service UNIT FILE STATE test-mask.service masked
1 unit files listed. ** masked ** ● test-mask.service Loaded: masked (/dev/null; bad) Active: inactive (dead)
~# systemctl unmask test-mask.service Removed /etc/systemd/system/test-mask.service.
~# mkdir -p /etc/systemd/system/test-mask.service.d
~# cat <<EOF > /etc/systemd/system/test-mask.service.d/override.conf > # Arbitrary override for the sake of demonstration > [Unit] > After=ssh.service > > EOF
~# systemctl cat test-mask.service # /lib/systemd/system/test-mask.service [Unit] Description=dummy service
[Service] Type=oneshot ExecStart=/bin/true
[Install] WantedBy=multi-user.target
# /etc/systemd/system/test-mask.service.d/override.conf # Arbitrary override for the sake of demonstration [Unit] After=ssh.service
1 unit files listed. ** enabled ** ● test-mask.service - dummy service Loaded: loaded (/lib/systemd/system/test-mask.service; enabled; vendor preset: enabled) Drop-In: /etc/systemd/system/test-mask.service.d └─override.conf Active: inactive (dead)
~# systemctl mask test-mask.service Created symlink /etc/systemd/system/test-mask.service → /dev/null.
1 unit files listed. ** masked ** Warning: test-mask.service changed on disk. Run 'systemctl daemon-reload' to reload units. ● test-mask.service Loaded: masked (/dev/null; bad) Active: inactive (dead)
This does not appear to affect Artful and systemd 234. Example session:
~# cat /etc/lsb-release RELEASE= 17.10 CODENAME= artful DESCRIPTION= "Ubuntu 17.10"
DISTRIB_ID=Ubuntu
DISTRIB_
DISTRIB_
DISTRIB_
~# uname -a
Linux ip-100-65-137-86 4.13.0-36-generic #40-Ubuntu SMP Fri Feb 16 20:07:48 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
~# systemctl --version hierarchy= hybrid
systemd 234
+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD -IDN2 +IDN default-
~# systemctl daemon-reload
~# systemctl list-unit-files test-mask.service
0 unit files listed.
~# cat <<EOF > /lib/systemd/ system/ test-mask. service multi-user. target
> [Unit]
> Description=dummy service
>
> [Service]
> Type=oneshot
> ExecStart=/bin/true
>
> [Install]
> WantedBy=
>
> EOF
~# systemctl daemon-reload
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service
UNIT FILE STATE
test-mask.service disabled
1 unit files listed. system/ test-mask. service; disabled; vendor preset: enabled)
**
disabled
**
● test-mask.service - dummy service
Loaded: loaded (/lib/systemd/
Active: inactive (dead)
~# systemctl enable test-mask.service system/ multi-user. target. wants/test- mask.service → /lib/systemd/ system/ test-mask. service.
Created symlink /etc/systemd/
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service
UNIT FILE STATE
test-mask.service enabled
1 unit files listed. system/ test-mask. service; enabled; vendor preset: enabled)
**
enabled
**
● test-mask.service - dummy service
Loaded: loaded (/lib/systemd/
Active: inactive (dead)
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service
UNIT FILE STATE
test-mask.service masked
1 unit files listed.
**
masked
**
● test-mask.service
Loaded: masked (/dev/null; bad)
Active: inactive (dead)
~# systemctl unmask test-mask.service system/ test-mask. service.
Removed /etc/systemd/
~# mkdir -p /etc/systemd/ system/ test-mask. service. d
~# cat <<EOF > /etc/systemd/ system/ test-mask. service. d/override. conf
> # Arbitrary override for the sake of demonstration
> [Unit]
> After=ssh.service
>
> EOF
~# systemctl daemon-reload
~# systemctl cat test-mask.service system/ test-mask. service
# /lib/systemd/
[Unit]
Description=dummy service
[Service]
Type=oneshot
ExecStart=/bin/true
[Install] multi-user. target
WantedBy=
# /etc/systemd/ system/ test-mask. service. d/override. conf
# Arbitrary override for the sake of demonstration
[Unit]
After=ssh.service
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service
UNIT FILE STATE
test-mask.service enabled
1 unit files listed. system/ test-mask. service; enabled; vendor preset: enabled) system/ test-mask. service. d
└─override. conf
**
enabled
**
● test-mask.service - dummy service
Loaded: loaded (/lib/systemd/
Drop-In: /etc/systemd/
Active: inactive (dead)
~# systemctl mask test-mask.service system/ test-mask. service → /dev/null.
Created symlink /etc/systemd/
~# systemctl list-unit-files test-mask.service; echo '**'; systemctl is-enabled test-mask.service; echo '**'; systemctl status test-mask.service
UNIT FILE STATE
test-mask.service masked
1 unit files listed.
**
masked
**
Warning: test-mask.service changed on disk. Run 'systemctl daemon-reload' to reload units.
● test-mask.service
Loaded: masked (/dev/null; bad)
Active: inactive (dead)