Questions tagged [systemctl]

systemctl is the main command to control and introspect the systemd Linux init system.

systemd is a system and service manager in Linux. More information about switches and arguments can be found here.

228 questions
0
votes
1 answer

StartExecPost calling the service itself

I have a service defined as bellow: Unit] Description=My Service After=network.target [Service] ExecStart=/usr/local/bin/myservice KillMode=process Restart=on-failure ExecStartPost=/usr/local/bin/script.sh [Install] WantedBy=multi-user.target and…
iAmoric
  • 121
  • 1
  • 4
0
votes
1 answer

SELinux policys keeping Tomcat from starting

On a newly built Oracle Linux 8 server i added a drive and file system, then put put Apache Tomcat on that file system via the tarball. Now when starting Tomcat via a services file, I get an error saying Tomcat has not started, and my journalctl…
Eric W
  • 31
  • 2
  • 4
0
votes
0 answers

Trouble starting by service: Linux 3.10.0-1160.62.1.el7.x86_64 #1 SMP Wed Mar 23 09:04:02 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

Linux XXXXXXXX 3.10.0-1160.62.1.el7.x86_64 #1 SMP Wed Mar 23 09:04:02 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux cat -vetn rc.service 1 [Unit]$ 2 Description=Script Daemon$ 3 $ 4 [Service]$ 5 Type=simple$ 6 …
0
votes
1 answer

Can't connect to mysql after managing systemctl (Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock')

I needed to run a program (just a compiled c++ program, not script, i.e., like /var/programname) on startup on CentOS 7. I followed this guide https://www.howtogeek.com/687970/how-to-run-a-linux-program-at-startup-with-systemd/ Rebooted via reboot…
0
votes
1 answer

Nginx sometimes crash

Sometimes nginx randomly crashes (once every few months) Here's the log I got when I ran systemctl status nginx nginx.service - A high performance web server and a reverse proxy server Loaded: loaded (/lib/systemd/system/nginx.service;…
0
votes
0 answers

failed to create bus connection: no such file or directory

Virtualbox with ubuntu 22.04 [root@container www]# systemctl start NetworkManager Failed to get D-Bus connection: No such file or directory Virtualbox with ubuntu 20.04 docker run --privileged -d -ti dev:centos7 drsr@ubuntu2004:~$ docker exec…
0
votes
0 answers

how to use systemctl with pem file for remote commands

I am wondering an anyone tell me how to use a pem file with the systemctl command in order to be able to issue a remote command whilst logging in using the pem? I am running it on Ubuntu 22.04 systemctl -H abc@xyz -I mykey.pem status command.service…
Thomas
  • 1
  • 1
0
votes
1 answer

What is the easiest way to shut down Kubeadm on Ubuntu?

I have just installed kubeadm, kubelet, kubectl, docker, docker-ce on Ubuntu 22.04 and they all are working fine. I am wondering how I shut them all down without making them corrupted? Also how can I start them all up again? Furthermore I like to…
best_of_man
  • 367
  • 1
  • 3
  • 12
0
votes
0 answers

How to start up GPD for Palo Alto Network in Headless Ubuntu Server?

Trying to install and work with GlobalProtect from Palo Alto Networks on an Amazon Ec2 . headless machine (runs Ubuntu 22.04). I just installed Globalprotect alright, but it is not working. From some reading, I came to believe the GPD service is not…
Della
  • 175
  • 1
  • 1
  • 5
0
votes
0 answers

How to get information about an instantiated systemd service after it exited

For regular systemd services it is possible to retrieve information about the most recent run via systemctl show .... I'm interested in state change time stamps (mainly when started and stopped). This works fine: $ systemctl show -p…
Oben Sonne
  • 101
  • 2
0
votes
0 answers

kube-apiserver.service failing after complete reinstall of kubernetes and kubectl plugins

I'm having an issue where kube-apiserver.service will always fail on my local Fedora 36. Getting the namespaces from a context I was experiencing certificate issues that prevented me from succeeding. I was using kubens and getting the error: >…
0
votes
0 answers

Jboss as a service failing on OS Reboot RHEL8

0 I am facing some issues while running Jboss as a service on RHEL8 servers. The setup of service is done in a standard way as per the RHEL…
Amiy
  • 1
0
votes
1 answer

rsyslog: action suspended, next retry is

I'm trying to configure rsyslog to receive logs sent from other devices on port 3100 (my manager chose that port and I will get him to change it to 514 later), and save (append) those logs in local files. So I created /etc/rsyslog.d/remote.conf…
0
votes
0 answers

Redirect systemd service logs to /dev/kmsg for all running services

Currently systemd service files will redirect the logs to journal buffer by default. But I need to get all the userspace services logs as part of /dev/kmsg buffer. I was able to add StandardOutput=file:/dev/kmsg to a service file and that works only…
Rckzz
  • 1
0
votes
1 answer

Dynamic NVM node path for service unit file

I recently migrated from using node installed on my Ubuntu server to using NVM to manage my node, but the issue is the application I use on this server uses a .service file that executes with the path of the locally installed node, usr/bin/node. I…
cphill
  • 197
  • 1
  • 1
  • 12