sytemd managed services are controlled using systemctl.
To start|stop a service:
sudo systemctl start|stop servicename
To set a service to start on boot:
sudo systemctl enable servicename
More examples and details in this article.
Articles, notes and random thoughts on Software Development and Technology
sytemd managed services are controlled using systemctl.
To start|stop a service:
sudo systemctl start|stop servicename
To set a service to start on boot:
sudo systemctl enable servicename
More examples and details in this article.
Using curl by default will return the response of a request as-is. If the response is a redirect, you can tell curl to follow the redirect with the -L option, e.g.
curl -L http://some.site
To use curl to download a file, use the -O option.
In a minimal CentOS 7 install, there’s no ifconfig to check your network settings. Instead use
ip addr
More info here.
Following the instructions to install the Openshift Origin binary from here, on first attempt to start it up I got this error:
failed to run Kubelet: failed to create kubelet:
misconfiguration: kubelet cgroup driver: "systemd" is different from docker cgroup driver: "cgroupfs"
Per instructions in this issue ticket, to verify which cgroup drivers docker is using I used:
$ sudo docker info |grep -i cgroup Cgroup Driver: cgroupfs
Unfortunately the steps to check the cgroup driver for kubernetes don’t match with my install because I’m guessing the single binary Openshift Origin has it packaged all in one, so there is no corresponding systemd config for it.
This article suggested to configure the cgroups driver for Docker so it matches kubernetes, but it looks like the yum install for docker-ce doesn’t configure systemd for it either.
Ok, to the docs. Per the Docker docs for configuring systemd here, it suggests to pull to preconfigured files from a git repo and place them in /etc/systemd/system
Now I have the systemd files for Docker in place, this articles says to add this arg to the end of the ExecStart line in docker.service:
--exec-opt native.cgroupdriver=systemd
Now reload my config and restart the docker service:
sudo systemctl daemon-reload sudo systemctl restart docker
and let’s check again what cgroups driver we’re using with:
$ sudo docker info |grep -i cgroup Cgroup Driver: systemd
… and now we’ve switched to systemd.
Ok, starting up Openshift again, this issue is resolved, there’s a lot of log output as the server starts up. After opening up the firewall ports for 8443, my Openshift Console is now up!