Justin Posted June 14, 2021 Report Share Posted June 14, 2021 I've been running a Plastic server in an Ubuntu based container for several years now and with the 10.x releases It has not been able to build. plastic-server-core gives this error: "System has not been booted with systemd as init system (PID 1). Can't operate." I've tried working around it a few different ways but nothings seems to work. Is containerization something that can/will be supported? I did this based off an old forum post but not sure if its still a relevant thing for Plastic? Thanks Link to comment Share on other sites More sharing options...
calbzam Posted June 15, 2021 Report Share Posted June 15, 2021 Hi, Regarding your error: 'System has not been booted with systemd as init system (PID 1). Can't operate.'- We decided by default to start the Plastic netcore server via "systemctl" and we tested that it works in multiple distros with no problems. But I can see we already detected the following limitation during our development: You need to do this in a VM, since WSL doesn't support systemd (https://github.com/MicrosoftDocs/WSL/issues/457) I think your are facing the same limitation when using Docker/Kubernetes.https://success.docker.com/article/using-systemd-to-control-the-docker-daemon Normally when you run a container you aren’t running an init system. systemctl is a process that communicates with systemd over dbus. If you aren’t running dbus or systemd, I would expect systemctl to fail. - So in summary, the default process to start the Plastic netcore server is not working in a Docker container so you may need to manually start the server after the installation. The following article may be useful to run systemd in a container:https://developers.redhat.com/blog/2019/04/24/how-to-run-systemd-in-a-container/ - You should be able to still install the "plastic-server-core" using the tar.gz installer instead of the packages: https://blog.plasticscm.com/2020/02/plastic-scm-server-runs-net-core.html Regards, Carlos. Link to comment Share on other sites More sharing options...
Justin Posted June 15, 2021 Author Report Share Posted June 15, 2021 Carlos, I was able to get the service started using a systemd-ubuntu image as a base and your guide to use the tar.gz installer for plastic-server-core. It doesn't seem to be serving out port 8087 though and I'm not sure why. Here's the status of the service root@b6e1bd62e65c:/opt/plasticscm5/server# systemctl status plasticscm-server * plasticscm-server.service - Plastic SCM Server Loaded: loaded (/etc/systemd/system/plasticscm-server.service; enabled; vendor preset: enabled) Active: active (running) since Tue 2021-06-15 12:35:23 UTC; 11min ago Docs: https://www.plasticscm.com/documentation/administration/plastic-scm-version-control-administrator-guide Main PID: 576 (plasticd) Tasks: 26 (limit: 614) Memory: 133.0M CGroup: /system.slice/docker-b6e1bd62e65c7f486d6a8fd3d9476430b8f607fa61c3a477ed30915ea9bd8418.scope/system.slice/plasticscm-server.service `-576 /opt/plasticscm5/server/plasticd --daemon Jun 15 12:35:23 b6e1bd62e65c systemd[1]: Starting Plastic SCM Server... Jun 15 12:35:23 b6e1bd62e65c plasticd[576]: plasticd daemon up. 10.0.16.5622 558 ms startup time Jun 15 12:35:23 b6e1bd62e65c systemd[1]: Started Plastic SCM Server. Jun 15 12:35:24 b6e1bd62e65c plasticd[576]: Hosting environment: Production Jun 15 12:35:24 b6e1bd62e65c plasticd[576]: Content root path: /opt/plasticscm5/server/webadmin Jun 15 12:35:24 b6e1bd62e65c plasticd[576]: Now listening on: http://127.0.0.1:7178 Jun 15 12:35:24 b6e1bd62e65c plasticd[576]: Now listening on: http://127.0.0.1:7111 Port 7111 seems to reference WebSocketServerPort in the server.conf. I'm not sure why it isn't listening on 8087 for the client though? I've got this running in AWS with the container's 8087 mapped to 18087 on the host because our production Plastic instance is already using 8087. I ran a port-checker to ensure I could telnet to it from my laptop and that worked but when I spun up the plastic container I couldn't get that port to connect again. Thanks! Link to comment Share on other sites More sharing options...
calbzam Posted June 15, 2021 Report Share Posted June 15, 2021 Hi, The server listens on the ports defined in the "network.conf". If you are not able to connect via the 8087 port, we will need to review the plastic.debug log. Regards, Carlos. Link to comment Share on other sites More sharing options...
Justin Posted June 15, 2021 Author Report Share Posted June 15, 2021 Carlos, There is no network.conf in the plasticscm-server-core tar.gz as far as I can tell. The plastic.debug.log.txt file has this line in it and if need be I can post the entire thing. 2021-06-15 16:08:53,717 Main-1 DEBUG NetworkConfiguration - Can't find network configuration file: '/opt/plasticscm5/server/network.conf' Thanks Link to comment Share on other sites More sharing options...
calbzam Posted June 15, 2021 Report Share Posted June 15, 2021 Could you manually copy one from the "config_samples" folder? Regards, Carlos. Link to comment Share on other sites More sharing options...
Justin Posted June 15, 2021 Author Report Share Posted June 15, 2021 Carlos, I didn't know that was there.....my bad. Just using the one in there seemed to fix my issues and I'm now able to connect to the server. I've re-created it several times and its working as expected again. Thanks for your help with this. -Justin 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now