Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [daemon]

On linux an unix-like systems is demon the designation of processes running in the background and providing certain services. Direct user intaractions with demons are not intended.

0
votes
0answers
14 views

Failed to get properties: No such interface '' in Ubuntu 16.04.3 LTS [duplicate]

I Created this Unit file tdk-api.service in the /etc/systemd/system folder with this permissions: -rwxr-xr-x with this content: [Unit] Description = tdk API daemon [Service] Type = simple ExecStart ...
0
votes
1answer
32 views

OpenVPN exits when network connectivity is restored

I'm using OpenVPN as a daemon and when I lose the internet connection, OpenVPN waits for 2 minutes before it tries to restart each 5 seconds. This is as I want it to behave. However when the internet ...
1
vote
0answers
26 views

Sending different signals for system shutdown and manual stops in supervisord

I have a set of auto-scaled EC2 instances that run a daemon managed by supervisord on each instance. I want to differentiate the clean-up behavior for the following cases: when shutting down ...
0
votes
0answers
75 views

Clamav has an error when checking system status

I have an error when checking the status of clamav-daemon ● clamav-daemon.service - Clam AntiVirus userspace daemon Loaded: loaded (/lib/systemd/system/clamav-daemon.service; enabled; vendor ...
0
votes
1answer
32 views

Java daemon keeps failing due to FileInputStreamException for config files outside its jar package

I want to implement a Java application as a daemon / service that runs on my Raspberry Pi with standard Debian Stretch (Kernel version 4.9). The java application starts but then throws an exeption ...
0
votes
0answers
219 views

Daemon service made with systemd that runs a PHP script is stopped but keep running

I made a daemon with PHP based on this answer I stopped it but I'm logging it and I can see is still running. I found this behavior in a searh of a bug, because I can see some updates to the DB that ...
0
votes
1answer
26 views

linux, daemon startup, determine if launched by initd or user

in my /etc/init.d/blabla script, which is the correct way to determine if the system is booting or the user root is runnig the script ? I am thinking about * parent pid * euid * terminal... pts ?
0
votes
1answer
212 views

Rsync with rsync daemon is not preserving owners or groups

I am setting up a new internal backup strategy where multiple hosts on my LAN will be backed up to a single host running the rsync daemon. I am still in the early stages of this, backing up a ...
1
vote
1answer
344 views

How to start git-daemon at boot?

I've created scripts to control starting, stopping, etc. of my git-daemon on Fedora28. I'm now attempting to link these scripts to a systemd service so git-daemon will be available after reboot. The ...
0
votes
1answer
236 views

Haproxy two processes are created by systemd

I have just compiled the latest Haproxy. [root@proxy system]# haproxy -v HA-Proxy version 1.8.8 2018/04/19 Copyright 2000-2018 Willy Tarreau <willy@haproxy.org> My service file looks as ...
0
votes
1answer
198 views

Autostart/restart program simply with daemontools in debian 9 [closed]

For example make vlc start and play a video full screen on boot. After working this out here it is:
0
votes
0answers
517 views

How to kill rsync daemon that keeps respawning

How do I kill these rsync daemons that keep respawning root@que2 ~ # ps aux | grep rsync root 9660 0.0 0.0 19928 2844 ? S 13:35 0:00 rsync -rlptD --progress --delete --exclude=server/...
0
votes
1answer
419 views

How to hide a password from ps, if it's given to a process via script or command line

So I have a certain program, which is running almost 24/7. I have a start script I've written in bash which simply does: ./app --user XXX --pass YYY There are a few more options, but they are ...
0
votes
1answer
145 views

journalctl only refreshing after restarting systemd service?

I have a systemd service with gunicorn. I have a print statement in a function.Problem is that, journalctl does not show the print output when i call the function but it shows the output after ...
1
vote
0answers
487 views

How to run linux daemon in container linked to another container with docker-compose?

Disclaimer: I'm posting this here because people started to vote to close this question on SO as "off-topic". Although some people believe Docker questions should be posted on SO as opposed to SF, ...
0
votes
0answers
77 views

Run nscd in multiple network namespaces

How to run an instance of nscd daemon per network namespace? I did the following: ip netns exec <network_namespace> /usr/sbin/nscd However, it threw output /usr/sbin/nscd: already running ...
1
vote
1answer
104 views

How to turn a script into a daemon? So that upon a random script failure it is restarted by the kernel?

I have a script which streams important logs from another system. Unfortunately the machines are separated by a large distance which means that the connection between them can be poor. How to deal ...
0
votes
2answers
125 views

How to capture details of an aborted process into a logfile

A daemon is started and running under Debian until it randomly crashes. I found out that it sometimes aborts due to an assertion which is shown if the process is running in foreground, like: /usr/...
-1
votes
1answer
66 views

Is it safe to give ownership of files to “daemon”?

I was having trouble uploading files using my CMS (Drupal). When I put more restrictive file permissions on, I could not upload anything. Then I changed the owner of the upload directory and all sub-...
0
votes
2answers
760 views

Setting a domain as primary for the mailer daemon in postfix/dovecot

I currently have two domains set on my server on two different IPs. One is set on the domain's primary IP, and the second on a failover IP. Let's say I have domain1.com and domain2.com Currently, the ...
0
votes
3answers
437 views

nohup daemon process dies when terminal is close

I'm trying to copy the contents of a remote server to my local computer. Here is the command that I'm using: nohup rsync -chavP -e 'ssh -p 23' --stats user@ipaddress:~/great/stuff /volume1/code > ~...
2
votes
0answers
194 views

How can I troubleshoot a systemctl maintained daemon, on Oracle Linux 7, when it dies immediately after being spawned?

I'm trying to run jenkins, via systemctl, and it keeps dying immediately after being started. There is nothing in the "systemctl status" nor in "journalctl". Jenkins logs also show nothing. I've ...
3
votes
1answer
807 views

HostKeyAlgorithms in sshd config on debian - daemon reload fail

I have a Debian Jessie Server and I would like to verify the fingerprint of the ssh keys on the server about a DNS SSHFP record. This works fine, but if a client connect over ssh to the server, the ...
11
votes
3answers
42k views

Authentication is required to manage system services or units.

I have a strange issue whenever trying to stop/start a daemon as a regular user, it asks to authenticate with the credentials of another regular user - for example: [bob@server ~]$ systemctl stop ...
-2
votes
1answer
1k views

Killing a Perl process in Linux

I started a perl process that runs a script and I want to end it, but not the rest of perl scripts. How do I target it and not the rest?
1
vote
2answers
784 views

systemd restart jobs on condition

I have a Windows-only daemon running on a linux box with wine and Xvfb. Due to this quite experimental setup, the daemon crashes periodically and i'd like to implement some kind of mechanism to ...
1
vote
1answer
316 views

How do I run multiple on-going python scripts that might be changed in the future?

In a prod environment, I want to run some python scripts that run on start-up and never stop. Currently I am trying to run them as daemon processes, i.e. something like this in systemd: #!/bin/bash ...
1
vote
0answers
203 views

Debian 8/init.d: start daemon after “$named” is ready

I am trying to start a init.d daemon on Debian 8 after network and DNS is up and running. That's the script I am using: ### BEGIN INIT INFO # Provides: local_daemon # Required-Start: $all ...
2
votes
1answer
1k views

Uptime for individual service

I am running multiple unicorn processes on my production server. Now I want to check the individual service uptime of my services. For instance if any unicorn process restart automatically, it should ...
8
votes
1answer
15k views

Systemd : Run a Python Script At Startup (virtualenv)

I have a python script that I normally run it with this command: (environment) python run.py I want to run this script at start. (I'm using ubuntu) Here is my service: [Unit] Description=My Script ...
0
votes
0answers
1k views

SNMP Traphandler in Centos - permission issues while writing content to a file

I've set up an SNMP Trap receiver in a Centos machine using NET-SNMP. I can see that it works perfectly fine and traps are received. I made some addition to this, by adding a simple script to ...
0
votes
1answer
63 views

How to launch let'schat (nodejs app) as deamon?

I have installed "let's chat" on my server. In the documentation, they say to launch the application with npm start from the directory where the application is installed. But i'm unable to launch ...
12
votes
4answers
29k views

Configuring Systemd Service to run with root access

I have a service in the form of a node.js application set up with Systemd on Raspbian Jessie and it is using its own user account. However, I am finding that the service does not run correctly because ...
2
votes
1answer
416 views

Why would one use “stop; exit 1” in an Upstart script rather than just “exit 1” in case of an error?

I am maintaining an Upstart script (version 0.6.5) and in the pre-start script, there's a test to terminate the service if a precondition is not met: pre-start script if [ ! -f $REQUIRED_FILE ]; ...
1
vote
2answers
702 views

Parent bash script not receiving 'trap' despite process still running

What I'm actually trying to achieve: I'm trying to get a custom daemon working on a system that uses SysVinit. I have the bootstrapper /etc/init.d/xyz script already, which calls my daemon, but it ...
0
votes
1answer
260 views

how to get rid of awstat www-data daemon?

I have successfully installed awstats on my webserver. I have created a cron job that runs as root every third hour. And it works perfectly, but i keep receiving "mails" every 10 minutes saying that ...
0
votes
1answer
64 views

Appropriate systemd unit location for software not installed using a package manager

According to https://www.freedesktop.org/software/systemd/man/systemd.unit.html, the default unit path is… /etc/systemd/system: Local configuration /run/systemd/system: Runtime units /usr/lib/systemd/...
0
votes
3answers
852 views

How to check to see if daemon is running

I have a simple bash script I'd like to run as a daemon... #!/bin/bash while true; do crontab cron sleep 58m done I run this as a daemon using this command... setsid copy_cron.sh >/dev/null 2>...
0
votes
1answer
326 views

PHP websocket script running as daemon stops working after a while

I start my websocket script like so: nohup php server.php & and I close the ssh client and it seems to be working fine for a while, but after say half an hour or so it stops working, any idea ...
10
votes
4answers
59k views

Create daemon on ubuntu 16.04

I developed a crawler in PHP that parse an URL with specific headers and put all URLs of content in the queue. It works fine. I developed this code in a ubuntu 14.04 and I put a .conf file in /etc/...
22
votes
2answers
15k views

Create a directory under /var/run at boot

I had a daemon that needed its own dir in /var/run for its PID file with write permission granted to the daemon's user. I found I could create this dir with these commands: # mkdir /var/run/mydaemon ...
2
votes
1answer
5k views

PHP script with systemd

I'm new to systemd and I've got issue with script my colleague gave me. This script worked as background process in Debian 7 but doesn't in Debian 8. I decided to rewrite it to systemd. I have this ...
2
votes
1answer
169 views

Adding local docker-deamon to docker-machine?

I have just installed an Ubuntu machine with a docker-daemon and I am able to run docker containers, after that I installed docker-machine and provisioned an ESX machine with docker2boot and I see ...
1
vote
1answer
67 views

How can I create a log for an existing daemon?

I have a deamon running (that I did not create) and I need to be able to read its logs. Unfortunately, it does not have a log file. Is there a way to pipe the daemon's output into a file, and have it ...
0
votes
1answer
534 views

postgresql - How to deamonize postgres server process for ordinary user

I'm trying to set up a PostgreSQL cluster in my home directory on Debian. EDIT: There are a couple of reasons why I think this a good idea: I don't use Postgres frequently so I don't currently have ...
0
votes
2answers
946 views

Auto-restart commandline process in screen every day

I have a queue script that finds new jobs from the db every second and handles them. Sometimes it doesn't do anything for 10 hours, and sometimes it receives 1000 new jobs in 3 min. The queue works ...
0
votes
0answers
111 views

Upstart - how to convert ubuntu daemon to centos?

On Ubuntu this upstart service did a brilliant job at making sure the app always stayed running (and logged) start on started mountall respawn respawn limit unlimited exec node /var/sentora/hostdata/...
1
vote
1answer
50 views

How to do remote calls from server A to B to create virtual machines

This is my first question on serverfault so I hope I'm doing this right as I'm usually on Stackoverflow :-) I have two Ubuntu 14.04 LTS servers, server A and B. Server A runs the web server where ...
5
votes
1answer
5k views

systemd ignores return code while starting service

I ran into this problem while writing unit-file for one simple daemon. When daemon returns '1' on startup systemd just ignores it, and it looks like daemon was started successfully while it's actually ...
0
votes
0answers
723 views

Multiple Gunicorn daemons for Django projects with Nginx result in 502 Bad Gateway for one

I want to run two Django applications on the same server, with Nginx and Gunicorn. I can run them separately, but not both at the same time: When I try, one is OK, but for the other one I receive 502. ...