Bug#948710: openssh-server: Fail to upgrade "ssh.service: Unit -.mount is masked"

2020-01-15 Thread Michael Biebl
Hi Phillip

Am 15.01.20 um 17:08 schrieb Phillip Susi:
> 
> I brought this up on systemd-devel the other day and Lennart agreed that
> it is a bug in systemd that it refuses to start services that depend on
> masked mount units when the mount is active.  He advised me to file a
> bug report on github, but github insisted on emailing me before allowing
> me to log in even though I know my login and password, and they seem to
> still have my no longer existing ubuntu email address, and so I am
> locked out.
I filed such a bug report in the mean time
https://github.com/systemd/systemd/issues/14550



signature.asc
Description: OpenPGP digital signature


Bug#948710: openssh-server: Fail to upgrade "ssh.service: Unit -.mount is masked"

2020-01-15 Thread Phillip Susi


I brought this up on systemd-devel the other day and Lennart agreed that
it is a bug in systemd that it refuses to start services that depend on
masked mount units when the mount is active.  He advised me to file a
bug report on github, but github insisted on emailing me before allowing
me to log in even though I know my login and password, and they seem to
still have my no longer existing ubuntu email address, and so I am
locked out.  Their contact us page also does not seem to work nor have
they replied to my attempts to email support@, so I am unable to file
the upstream bug.

He also advised that gparted should be using a bsd file lock instead of
masking mount units.  Curtis Gedack wasn't sure about making the change
at least for the upcoming release of gparted.  Perhaps after that.



Bug#948710: openssh-server: Fail to upgrade "ssh.service: Unit -.mount is masked"

2020-01-13 Thread Christian Marillat
On 12 janv. 2020 19:32, Michael Biebl  wrote:

[...]

> The ssh.service is doing nothing wrong.
>
> I'd say we have two bugs here:
>
> a/ a package or user doing something stupid like masking _.mount
> b/ systemd not handling that case more gracefully.
>
>
> I quickly checked the gparted sources and noticed that it still does
> mask all .mount units.
>
> gparted.in: | grep -v masked | cut -f1 -d' ' \
> gparted.in:   systemctl --runtime mask --quiet -- $MOUNTLIST
> gparted.in:   systemctl --runtime unmask --quiet -- $MOUNTLIST

I agree. I was using gparetd working with SD card and .iso files
before I did an upgrade and see this bug.

Christian



Bug#948710: openssh-server: Fail to upgrade "ssh.service: Unit -.mount is masked"

2020-01-12 Thread Michael Biebl
Control: clone -1 -2
Control: reassign -2 gparted 0.32.0-2
Control: retitle -2 gparted should not mask .mount units
Control: retitle -1 handle masked .mount unit more gracefully
Control: severity -1 important


On Sun, 12 Jan 2020 18:06:41 + Colin Watson  wrote:
> The OpenSSH units don't make any reference to a -.mount unit (explicitly
> or implicitly, as far as I can tell),

That's not quite true. ssh.service (and the vast majority of services)
uses DefaultDependencies=yes (as it is the default behaviour).


This will generate a dependency on various .mount units, depending on
your /etc/fstab.

$ systemctl show ssh.service -p Requires -p After
Requires=system.slice -.mount sysinit.target
After=auditd.service system.slice basic.target systemd-journald.socket
network.target sysinit.target -.mount

 so I can only assume that this is
> some kind of bug in systemd itself; reassigning over there.  Feel free
> to reassign back if it seems that this is a bug in ssh.service after
> all, but in that case I'd appreciate some kind of specific advice on> what 
> it's doing wrong.

The ssh.service is doing nothing wrong.

I'd say we have two bugs here:

a/ a package or user doing something stupid like masking _.mount
b/ systemd not handling that case more gracefully.


I quickly checked the gparted sources and noticed that it still does
mask all .mount units.

gparted.in:   | grep -v masked | cut -f1 -d' ' \
gparted.in: systemctl --runtime mask --quiet -- $MOUNTLIST
gparted.in: systemctl --runtime unmask --quiet -- $MOUNTLIST


So cloning and re-assinging the bug report.


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?





signature.asc
Description: OpenPGP digital signature


Bug#948710: openssh-server: Fail to upgrade "ssh.service: Unit -.mount is masked"

2020-01-12 Thread Michael Biebl
Hi Colin,

please CC the package on reassign.


On Sun, 12 Jan 2020 18:06:41 + Colin Watson  wrote:
> Control: reassign -1 systemd 244-3
> 
> On Sun, Jan 12, 2020 at 02:48:39PM +0100, Christian Marillat wrote:
> > Setting up openssh-server (1:8.1p1-5) ...
> > rescue-ssh.target is a disabled or a static unit, not starting it.
> > Failed to restart ssh.service: Unit -.mount is masked.
> > invoke-rc.d: initscript ssh, action "restart" failed.
> > * ssh.service - OpenBSD Secure Shell server
> >  Loaded: loaded (/lib/systemd/system/ssh.service; enabled; vendor 
> > preset: enabled)
> >  Active: active (running) since Sat 2020-01-11 08:26:51 CET; 1 day 6h 
> > ago
> >Docs: man:sshd(8)
> >  man:sshd_config(5)
> >Main PID: 1119 (sshd)
> >  Memory: 3.7M
> >  CGroup: /system.slice/ssh.service
> >  `-1119 /usr/sbin/sshd -D
> 
> The OpenSSH units don't make any reference to a -.mount unit (explicitly
> or implicitly, as far as I can tell), so I can only assume that this is
> some kind of bug in systemd itself; reassigning over there.  Feel free
> to reassign back if it seems that this is a bug in ssh.service after
> all, but in that case I'd appreciate some kind of specific advice on
> what it's doing wrong.
> 

The bug is, that someone or something has masked _.mount unit, which you
shouldn't do.

My guess is on gparted, which has done that in the past and I'm not sure
if it still does.

Christian, have you run/used gparted prior/while running the openssh
upgrade?

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#948710: openssh-server: Fail to upgrade "ssh.service: Unit -.mount is masked"

2020-01-12 Thread Colin Watson
Control: reassign -1 systemd 244-3

On Sun, Jan 12, 2020 at 02:48:39PM +0100, Christian Marillat wrote:
> Setting up openssh-server (1:8.1p1-5) ...
> rescue-ssh.target is a disabled or a static unit, not starting it.
> Failed to restart ssh.service: Unit -.mount is masked.
> invoke-rc.d: initscript ssh, action "restart" failed.
> * ssh.service - OpenBSD Secure Shell server
>  Loaded: loaded (/lib/systemd/system/ssh.service; enabled; vendor preset: 
> enabled)
>  Active: active (running) since Sat 2020-01-11 08:26:51 CET; 1 day 6h ago
>Docs: man:sshd(8)
>  man:sshd_config(5)
>Main PID: 1119 (sshd)
>  Memory: 3.7M
>  CGroup: /system.slice/ssh.service
>  `-1119 /usr/sbin/sshd -D

The OpenSSH units don't make any reference to a -.mount unit (explicitly
or implicitly, as far as I can tell), so I can only assume that this is
some kind of bug in systemd itself; reassigning over there.  Feel free
to reassign back if it seems that this is a bug in ssh.service after
all, but in that case I'd appreciate some kind of specific advice on
what it's doing wrong.

(I upgraded a test system that I deliberately keep in a clean state for
this sort of thing, and it worked fine for me.)

-- 
Colin Watson   [cjwat...@debian.org]



Bug#948710: openssh-server: Fail to upgrade "ssh.service: Unit -.mount is masked"

2020-01-12 Thread Christian Marillat
Package: openssh-server
Version: 1:8.1p1-5
Severity: serious

Dear Maintainer,

Fail to upgrade with this error :

Setting up openssh-server (1:8.1p1-5) ...
rescue-ssh.target is a disabled or a static unit, not starting it.
Failed to restart ssh.service: Unit -.mount is masked.
invoke-rc.d: initscript ssh, action "restart" failed.
* ssh.service - OpenBSD Secure Shell server
 Loaded: loaded (/lib/systemd/system/ssh.service; enabled; vendor preset: 
enabled)
 Active: active (running) since Sat 2020-01-11 08:26:51 CET; 1 day 6h ago
   Docs: man:sshd(8)
 man:sshd_config(5)
   Main PID: 1119 (sshd)
 Memory: 3.7M
 CGroup: /system.slice/ssh.service
 `-1119 /usr/sbin/sshd -D

Christian

-- System Information:
Debian Release: bullseye/sid
  APT prefers buildd-unstable
  APT policy: (500, 'buildd-unstable'), (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.19.93 (SMP w/8 CPU cores)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_WARN, TAINT_OOT_MODULE
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), 
LANGUAGE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages openssh-server depends on:
ii  adduser3.118
ii  debconf [debconf-2.0]  1.5.73
ii  dpkg   1.19.7
ii  libaudit1  1:2.8.5-2+b1
ii  libc6  2.29-9
ii  libcom-err21.45.5-2
ii  libcrypt1  1:4.4.10-10
ii  libgssapi-krb5-2   1.17-6
ii  libkrb5-3  1.17-6
ii  libpam-modules 1.3.1-5
ii  libpam-runtime 1.3.1-5
ii  libpam0g   1.3.1-5
ii  libselinux13.0-1
ii  libssl1.1  1.1.1d-2
ii  libsystemd0244-3
ii  libwrap0   7.6.q-30
ii  lsb-base   11.1.0
ii  openssh-client 1:8.1p1-5
ii  openssh-sftp-server1:8.1p1-5
ii  procps 2:3.3.15-2+b1
ii  runit-helper   2.8.14
ii  ucf3.0038+nmu1
ii  zlib1g 1:1.2.11.dfsg-1+b1

Versions of packages openssh-server recommends:
ii  libpam-systemd [logind]  244-3
ii  ncurses-term 6.1+20191019-1
ii  xauth1:1.0.10-1

Versions of packages openssh-server suggests:
pn  molly-guard   
pn  monkeysphere  
pn  ssh-askpass   
pn  ufw   

-- debconf information excluded