8000 rkt stopped working as service with systemd 234 · Issue #3750 · rkt/rkt · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Feb 24, 2020. It is now read-only.

rkt stopped working as service with systemd 234 #3750

Closed
uzytkownik opened this issue Jul 26, 2017 · 6 comments
Closed

rkt stopped working as service with systemd 234 #3750

uzytkownik opened this issue Jul 26, 2017 · 6 comments

Comments

@uzytkownik
Copy link

Environment

Environment after downgrade:

appc Version: 0.8.10
Go Version: go1.8.3
Go OS/Arch: linux/amd64
Features: +TPM +SDJOURNAL
--
Linux 4.9.18-hardened x86_64
--
NAME=Gentoo
ID=gentoo
PRETTY_NAME="Gentoo/Linux"
ANSI_COLOR="1;32"
HOME_URL="https://www.gentoo.org/"
SUPPORT_URL="https://www.gentoo.org/support/"
BUG_REPORT_URL="https://bugs.gentoo.org/"
--
systemd 233
+PAM -AUDIT -SELINUX +IMA -APPARMOR +SMACK -SYSVINIT +UTMP -LIBCRYPTSETUP +GCRYPT -GNUTLS +ACL -XZ +LZ4 +SECCOMP +BLKID -ELFUTILS +KMOD -IDN default-hierarchy=hybrid

What did you do?
Start service
What did you expect to see?

What did you see instead?

Jul 26 14:48:24 <HOSTNAME> rkt[5960]: networking: loading network <NETWORD> with type bridge
Jul 26 14:48:24 <HOSTNAME> rkt[5960]: stage1: canMachinedRegister true
Jul 26 14:48:24 <HOSTNAME> rkt[5960]: stage1: cannot get environment
Jul 26 14:48:24 <HOSTNAME> rkt[5960]:   └─error determining if we're running from a system service
Jul 26 14:48:24 <HOSTNAME> rkt[5960]:     └─error calling sd_pid_get_owner_uid: no data available
Jul 26 14:48:24 <HOSTNAME> systemd[1]: <SERVICE>.service: Main process exited, code=exited, status=254/n/a
@youtux
Copy link
youtux commented Jul 30, 2017

Same problem here with Arch:

Jul 30 17:38:18 nuke systemd[1]: Started UBNT Unifi Controller.                                                                        │~
Jul 30 17:38:36 nuke rkt[31706]: stage1: cannot get environment: error calling sd_pid_get_owner_uid: no data available                 │~
Jul 30 17:38:36 nuke systemd[1]: ubnt-unifi-controller.service: Main process exited, code=exited, status=254/n/a                       │~
Jul 30 17:38:36 nuke rkt[32289]: gc: moving pod "c3e9c9eb-4158-4758-8e56-0b67c341a9d6" to garbage                                      │~
Jul 30 17:38:36 nuke systemd[1]: ubnt-unifi-controller.service: Unit entered failed state.                                             │~
Jul 30 17:38:36 nuke systemd[1]: ubnt-unifi-controller.service: Failed with result 'exit-code'.                                        │~
Jul 30 17:38:36 nuke systemd[1]: ubnt-unifi-controller.service: Service hold-off time over, scheduling restart.                        │~
Jul 30 17:38:36 nuke systemd[1]: Stopped UBNT Unifi Controller.                                                                        │~
Jul 30 17:38:36 nuke systemd[1]: Started UBNT Unifi Controller.
$ rkt version
rkt Version: 1.27.0
appc Version: 0.8.10
Go Version: go1.8.3
Go OS/Arch: linux/amd64
Features: -TPM +SDJOURNAL

$ 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

This is my unit file:

$ cat /lib/systemd/system/ubnt-unifi-controller.service
[Unit]
Description=UBNT Unifi Controller
Requires=network-online.target
After=network-online.target

[Service]
Slice=machine.slice
MemoryLimit=512M
TasksMax=infinity
ExecStart=/usr/bin/rkt run \
    --insecure-options=image \
    --volume data,kind=host,source=/usr/local/lib/unifi/data/,readOnly=false \
    --volume logs,kind=host,source=/usr/local/lib/unifi/logs,readOnly=false \
    --port=http:8080 --port=https:8443 --port=portal-http:8880 --port=portal-https:8843 --port=stun:3478 \
    /usr/local/lib/unifi/ubnt-unifi-controller.aci
ExecStopPost=/usr/bin/rkt gc --mark-only
Restart=always

[Install]
WantedBy=multi-user.target

@iaguis
Copy link
Member
iaguis commented Jul 31, 2017

Reported on go-systemd: coreos/go-systemd#236
Fix: coreos/go-systemd#237

@youtux
Copy link
youtux commented Jul 31, 2017

Thank for the very quick fix @iaguis. Is there any workaround to make it work for the time being?

@iaguis
Copy link
Member
iaguis commented Aug 1, 2017

Thank for the very quick fix @iaguis. Is there any workaround to make it work for the time being?

I can't think of any workarounds.

You can compile rkt with #3759 and use that though.

@youtux
Copy link
youtux commented Aug 1, 2017

I temporarily solved it using fly as stage1:
rkt run --stage1-name=coreos.com/rkt/stage1-fly:1.28.0 ...

@lucab
Copy link
Member
lucab commented Aug 1, 2017

Closed via #3759. I'm going to tag a 1.28.1 today/tomorrow, this will be part of it.

@lucab lucab closed this as completed Aug 1, 2017
clchiou added a commit to clchiou/garage that referenced this issue Mar 17, 2018
systemd 234 "breaks" rkt as reported in:
rkt/rkt#3750
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants
0