Skip to content
This repository was archived by the owner on May 12, 2021. It is now read-only.

docs: Add installation guide for SLES #114

Merged
merged 1 commit into from
Aug 15, 2018

Conversation

GabyCT
Copy link
Collaborator

@GabyCT GabyCT commented May 21, 2018

This will add the installation guide for SLES.

Fixes #85

Signed-off-by: Gabriela Cervantes [email protected]

@GabyCT
Copy link
Collaborator Author

GabyCT commented May 21, 2018

Currently this is blocked by kata-containers/packaging#39

@chavafg
Copy link
Contributor

chavafg commented May 21, 2018

added DNM flag as per @GabyCT request.

```bash
$ sudo zypper -n install libcgroup1
$ curl -OkL https://yum.dockerproject.org/repo/main/opensuse/13.2/Packages/docker-engine-17.05.0.ce-1.x86_64.rpm
$ sudo rpm -ivh docker-engine-17.05.0.ce-1.x86_64.rpm
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jodh-intel , there is an issue with SLES when we installed docker with

$ zypper -n install docker

This will install docker version 17.09.1-ce, build f4ffd2511ce9. However, after doing the installation of kata-runtime, kata-proxy, etc which is done correctly and trying to do the following

$ sudo systemctl daemon-reload
$ sudo systemctl restart docker

We have the following error

-- Subject: Unit docker.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit docker.service has begun starting up.
may 22 18:33:44 gaby-sles dockerd[20809]: time="2018-05-22T18:33:44Z" level=info msg="SUSE:secrets :: enabled"
may 22 18:33:44 gaby-sles dockerd[20809]: time="2018-05-22T18:33:44.722479100Z" level=debug msg="Listener created for HTTP on unix (/var/run/docker.sock)"
may 22 18:33:44 gaby-sles dockerd[20809]: Failed to connect to containerd. Please make sure containerd is installed in your PATH or you have specified the correct address. Got error: exec: "docker-containerd": executable file not found in $PATH
may 22 18:33:44 gaby-sles systemd[1]: docker.service: Main process exited, code=exited, status=1/FAILURE
may 22 18:33:44 gaby-sles systemd[1]: Failed to start Docker Application Container Engine.
-- Subject: Unit docker.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit docker.service has failed.

Now containerd is being installed by SLES.
containerd version 0.2.3 commit: 06b9cb35161009dcb7123345749fef02f7cea8e0

And docker-containerd does not exist

$ zypper search docker*
Loading repository data...
Reading installed packages...
i+ | docker                   
    | docker                      
    | docker-distribution       
    | docker-distribution-registry 
    | docker-image-migrator  
    | docker-img-store-setup 
i   | docker-libnetwork      
i   | docker-runc                 

However, this error did not happen when I am trying to manually installed and OpenSuSE package on SLES.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the configuration that I am using

$ cat /etc/os-release
NAME="SLES"
VERSION="12-SP3"
VERSION_ID="12.3"
PRETTY_NAME="SUSE Linux Enterprise Server 12 SP3"
ID="sles"
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:suse:sles:12:sp3"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @ajaeger - do you have any input on this SLES issue?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @GabyCT, @jodh-intel,

I am co-maintaing the Docker packages at SUSE and @ajaeger asked me to have a look at the SLES issue.

However, this error did not happen when I am trying to manually installed and OpenSuSE package on SLES.

Can you elaborate a bit more which setup is working and which not? In theory, a zypper install docker and systemctl start docker should always lead to a running Docker daemon on our supported systems (i..e, latest SLES and openSUSE).

And docker-containerd does not exist

That's correct as we ship it in the containerd package, both on SLES and openSUSE.

may 22 18:33:44 gaby-sles dockerd[20809]: Failed to connect to containerd. Please make sure containerd is installed in your PATH or you have specified the correct address. Got error: exec: "docker-containerd": executable file not found in $PATH

The error log shows that dockerd tries to start docker-containerd and I understand the confusion as we don't ship a docker-containerd binary but only a containerd one. The reasoning behind is that we manage our services via systemd to avoid containerd being a subprocess of dockerd. We consider this setup to a bit cleaner but it is has no functional impact.

@GabyCT If possible, could you upload the logs of docker and containerd (journalctl -u docker and journalctl -u containerd)? Can you try to start containerd (systemctl start containerd) and check if it's running (systemctl status containerd)? Did you change any systemd service files for either docker or containerd?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@GabyCT Are you using the docker and containerd packages provided by SUSE? It's just a wild guess, but maybe there were some packages left in your test environment that did not come from SUSE (i.e., zypper in docker).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @GabyCT - sorry, but I don't have a SLES license.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vrothberg, I just did the zypper -n install docker

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@chavafg could you please help me to reproduce this error? I want to see if it is something from my environment or you also hit the same error thanks

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@GabyCT
I tried today and I could start the docker daemon with this config:

fuentess@sles-kata:~> cat /etc/systemd/system/docker.service.d/kata-containers.conf
[Service]
ExecStart=
ExecStart=/usr/bin/dockerd -D --containerd /run/containerd/containerd.sock --add-runtime kata-runtime=/usr/bin/kata-runtime --default-runtime=kata-runtime

I think that @vrothberg approach should also work, but you'll would need to delete the /etc/systemd/system/docker.service.d/kata-containers.conf

I used the docker that is provided by SUSE. Version is: 17.09.1-ce

@jodh-intel jodh-intel added the high-priority Very urgent issue (resolve quickly) label Jul 30, 2018

```bash
$ sudo zypper -n install libcgroup1
$ curl -OkL https://yum.dockerproject.org/repo/main/opensuse/13.2/Packages/docker-engine-17.05.0.ce-1.x86_64.rpm
Copy link
Contributor

@chavafg chavafg Aug 10, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should remove the steps of adding this repo and install docker-engine. This docker version is 17.05, which is older than the one that SUSE provides, which is 17.09

$ cat <<EOF | sudo tee /etc/systemd/system/docker.service.d/kata-containers.conf
[Service]
ExecStart=
ExecStart=/usr/bin/dockerd -D --add-runtime kata-runtime=/usr/bin/kata-runtime --default-runtime=kata-runtime
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add --containerd /run/containerd/containerd.sock or change to use /etc/sysconfig/docker instead of the docker service config file.

@GabyCT GabyCT force-pushed the topic/addsles branch 2 times, most recently from 833aed1 to 032619f Compare August 10, 2018 19:28
@GabyCT
Copy link
Collaborator Author

GabyCT commented Aug 10, 2018

@chavafg changes applied

@GabyCT
Copy link
Collaborator Author

GabyCT commented Aug 10, 2018

@vrothberg the changes were applied and now docker is working thank you.

@GabyCT
Copy link
Collaborator Author

GabyCT commented Aug 10, 2018

@jodh-intel , I applied all the changes that are required however this is still blocked by issue kata-containers/packaging#39

@vrothberg
Copy link

@vrothberg the changes were applied and now docker is working thank you.

That's wonderful news :) Thanks a lot, @GabyCT!

@GabyCT GabyCT force-pushed the topic/addsles branch 3 times, most recently from 75749e6 to f5a2606 Compare August 10, 2018 20:43
@chavafg
Copy link
Contributor

chavafg commented Aug 10, 2018

@GabyCT, @jodh-intel, @egernst

about the kata-containers/packaging#39,
should we add a workaround to the document for the moment?

I know that this won't be elegant, but will allow us to have the documentation for SLES.

This will add the installation guide for SLES.

Fixes kata-containers#85

Signed-off-by: Gabriela Cervantes <[email protected]>
@jodh-intel
Copy link
Contributor

Hi @chavafg - I've asked @GabyCT to comment on a possible fix on kata-containers/packaging#39. However, if we really can't get this to work I guess we could consider adding something like the following to install/sles-installation-guide.md:

$ sudo mkdir -p /usr/libexec/kata-containers
$ sudo ln -s /usr/lib64/kata-containers/kata-proxy /usr/libexec/kata-containers/kata-proxy
$ sudo ln -s /usr/lib64/kata-containers/kata-shim /usr/libexec/kata-containers/kata-shim

@GabyCT GabyCT force-pushed the topic/addsles branch 2 times, most recently from 38da7f2 to 2341d75 Compare August 13, 2018 15:24
@GabyCT
Copy link
Collaborator Author

GabyCT commented Aug 13, 2018

@jodh-intel changes applied

@jodh-intel
Copy link
Contributor

Thanks @GabyCT - I think the workaround should be fine until we get a chance to update and re-test the packaging for SuSE.

@jodh-intel
Copy link
Contributor

Ping @chavafg, @kata-containers/documentation.

@caoruidong
Copy link
Member

caoruidong commented Aug 14, 2018

lgtm

Approved with PullApprove Approved with PullApprove

@bergwolf
Copy link
Member

@chavafg PTAL.

@chavafg chavafg merged commit aa90d94 into kata-containers:master Aug 15, 2018
devimc pushed a commit to devimc/kata-documentation that referenced this pull request Sep 2, 2019
…pdate

tests: Update kata-manager command
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
high-priority Very urgent issue (resolve quickly)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants