People who code: we want your input. Take the Survey

Questions tagged [systemd-unit]

For questions about the design of systemd units, the relationships between units, and writing [Unit] and [Install] sections of systemd unit files. It can also be used for questions about units which do not have their own tag such as systemd targets.

20 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
3
votes
1answer
217 views

Systemd: Start lots of services one after the other without specific depencies

I have a system composed of about 15 services. They have no inter-dependencies (i.e. no service require another to start) and they notify systemd when there start-up is finished (i.e. Type=notify). ...
2
votes
0answers
97 views

Stopping broken systemd service on init

I wanted to make a service that can shutdown the server every day at 9:30 pm. But I accidently set it up so the shutdown service runs on boot. So whenever I turn on the server, it shuts itself down ...
1
vote
0answers
10 views

Does systemd “After=” check if services in it are started without failures before starting the service?

example: bar.service: [Unit] After=foo.service if foo.service isn't started correctly, will bar.service start? and what about if foo.service isn't a dependency of anything and will never start?
1
vote
0answers
77 views

How to conditionally execute two different ExecStart commands in one systemd unit file?

I want to conditionally execute either one of (or both of) these commands in a single systemd unit file: ExecStart=/usr/bin/ssh-keygen -t rsa -b 4096 ExecStart=/usr/bin/ssh-keygen -t ed25519 -a 32 ...
1
vote
1answer
234 views

Why does systemd display certain service units that do not have an associated unit-file?

I have been reading up and investigating systemd and systemctl on Debian 8 Jessie. When running $ sudo systemctl list-units --all --type=service a few services appear in the list that have no unit-...
1
vote
0answers
154 views

Initialize postgresql 11 with custom datadir on fedora 31

According to what I learn so far, I should create a new systemd unit file with the provided script. Then I should initialize the datadir. These are the commands I ran: $ sudo /usr/sbin/postgresql-new-...
1
vote
0answers
1k views

Working with systemd unit file override, can it have multiple sections of the same name like [service]

I am interested in trying to override the CPU utilisation of a systemd service. So that I don't lockup the machine on some CPU heavey process that I run periodically. After running systemctl edit ...
1
vote
0answers
308 views

How systemd Type option affects starting other units?

The man page systemd.service(5) explains the Type options for services: Type= Configures the process start-up type for this service unit. One of simple, forking, oneshot, dbus, notify or ...
0
votes
0answers
13 views

Systemd file for gunicorn. share dynamic OS environment variables before launching workers

I have a flask app running on Ubuntu, using gunicorn with 12 sync workers. I have an environment file .env in which I set some secrets in the wsgi. I get those secrets through an API, but that API has ...
0
votes
0answers
26 views

starting wsgi as a service fails on startup

I am trying to deploy a flask application inside my WSGI container. I have tried to deploy it by symply executing the same commands within [Service] tags in the unit declaration; this means that I ...
0
votes
0answers
15 views

Systemd wait for specific docker container before running unit

I have to wait for a service before starting a program. That's my actual unit: [Unit] Description = Tempgraph Service After = network.target [Service] Type = simple ExecStart = /opt/Go-...
0
votes
1answer
32 views

Multiple Instances of Unit= in Path or Timer Unit?

Can multiple instances of Unit= exist in a systemd.path or systemd.timer unit? Or, must one instead specify multiple instances of the path or timer unit, each with a single instance of Unit=? I ...
0
votes
1answer
61 views

Enable service for specific user Only (UBUNTU)

Currently writing a service unit file in Ubuntu, i want the service to be enabled for one user UserA only. The service will run automatically when UserA login but not for other users. How can I do ...
0
votes
0answers
75 views

Stop systemd from running user unit for user jenkins

I just installed jenkins on my pop-os following the instruction and install several plugins in jenkins when I found that several gnome user unit is started for user jenkins I tried restarting my ...
0
votes
0answers
39 views

systemd unit triggered on network interface

I'm new to systemd and unit files and I'm trying to find a way to have my unit running only when a network interface exist. My unit file starts a web server and I only want it active when wlan1 exist....
0
votes
1answer
39 views

How do I find out which system unit is causing nologin not to be removed?

My machine is not booting and I have tracked it down to GDM not starting because is says there is a nologin file. How can I find out what is causing this to not be deleted? All systemd units have ...
0
votes
0answers
807 views

systemd unit indirect status

I wonder how can I check which unit activates another with status indirect? I run Arch with Gnome and a Debian server. On my Debian machine I can see that output for systemctl list-unit-files --type=...
0
votes
1answer
76 views

Inverse Requsite= dependency / stronger Conflicts= in a systemd unit file

I have two systemd units A and B, which should not be running simultaneously. Both provide access to the same resource, but in different ways, and one handles being stopped 'from outside' less ...
0
votes
1answer
147 views

systemd start Service B only after Service A has finished

I've been searching around for an hour or two but cannot seem to find the correct solution. Here's the situation: I have multiple services. I start up Service A, which runs a docker container. That ...
0
votes
0answers
630 views

systemd pathexists not triggered when booting

I tried to configure my trackpoint sensitivity on my ArchLinux using the systemd path unit as described here: https://wiki.archlinux.org/index.php/TrackPoint#systemd.path_unit My files look like this:...