gnu screen does not work in classic?

Oliver Grawert ogra at ubuntu.com
Tue Jan 3 10:11:18 UTC 2017


hi,
Am Dienstag, den 03.01.2017, 00:46 +0000 schrieb Nick Moffitt:
> Dan Kegel:
> > 
> > I tried to use 'screen' as usual to start a long-running job
> > inside classic, but it failed because /proc/self/fd/0 was
> > owned by root:
> As a workaround, you can use /usr/bin/script from the bsdutils
> package
> to give you a fresh pty that screen won't get upset about.  Something
> like this should do the trick:
> 
>     script -c 'screen -RAD' /dev/null
> 
if you look at /snap/classic/current/bin/classic you will notice that
we already do this:

...
# FIXME: workaround for https://bugs.launchpad.net/snappy/+bug/1611493
SCRIPT="script --quiet --return --command \"$SUDOCMD\" /dev/null"

CMD="$DEVPTS; $SCRIPT"

systemd-run --quiet --scope --unit=classic-$$.scope --
description="Classic shell" chroot "$ROOT" sh -c "$CMD"
...

i assume the "/dev/pts already mounted" error is the issue here, seems
systemd-run does not properly clean up on the stzop event and you keep
the former pts instance around.

i filed http://pad.lv/1653648 for this and will dig into it ...

ciao
	oli
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: This is a digitally signed message part
URL: <https://lists.ubuntu.com/archives/snapcraft/attachments/20170103/ca97d3d3/attachment.sig>


More information about the Snapcraft mailing list