Questions tagged [init.d]

The init.d directory contains a number of start/stop scripts for various services on a Linux system.

The init.d directory contains a number of start/stop scripts for various services on a Linux system.

288 questions
2
votes
2 answers

screen command process id

First of all sorry for my bad english and i am new at linux. When i do this, it can write process id to pid file start () { echo -n "Starting someserver.jar: " java -jar /home/someserver/someserver.jar & echo $! >…
C.T
  • 33
  • 1
  • 4
2
votes
1 answer

How to run an init.d script to run after $PATH is set

I created an init.d script that launches a system daemon. The daemon uses the system $PATH to launch other processes. The system path, however, does not include "/usr/local/bin" at the time the init.d loads the daemon. So, I have to stop/start the…
tahoar
  • 121
  • 1
2
votes
2 answers

Python Script portion failing to execute within init.d/ on RedHat 6.5, why?

I've created a init.d script called rmCluster which is supposed to execute a simple python script at shutdown which uses boto to shutdown a particular cluster of servers, with 755 perms, located in /etc/init.d/rmCluster written as: #!/bin/sh # #…
DefionsCode
  • 230
  • 3
  • 9
2
votes
1 answer

insserv: warning: script 'uwsgi' missing LSB tags and overrides

This is my code: #!/bin/bash daemon="$APPVENV/bin/uwsgi" args="--emperor $APPCONF/uwsgi/app.ini" pid="$APPDIR/emperor.pid" case "\$1" in start) echo "Starting uwsgi" start-stop-daemon -m -p \$pid --start --exec \$daemon --…
J.Zil
  • 1,103
  • 3
  • 20
  • 29
2
votes
0 answers

Naming convention for /var/lock/subsys on sysvinit with multiple pids

In this Tips and Tricks article from Red Hat, it is said: When a service is started through an init script, a file is touched in the /var/lock/subsys/ directory with the same name as the init script. When the service is stopped, this file is…
Ed I
  • 143
  • 5
2
votes
1 answer

/etc/init.d/nginx reload not working

My earlier problem revealed that reloading the config of my Debian GNU/Linux 6.0 nginx reverse proxy does not work, while restarting, or reloading directly through the binary does work. I have looked into the /etc/init.d/nginx file to see what…
logicBV
  • 33
  • 1
  • 2
  • 5
2
votes
2 answers

Apache2 and MySQL fail to restart after Server restart or apt-get update

Does anyone know of any reason why Apache2 and MySQL do not run after either a server reboot or apt-get update? I am currently running Ubuntu 12.04 LTS server There are the corresponding files in /etc/init.d/ for apache2 and mysql however they only…
Grant
  • 21
  • 2
2
votes
1 answer

mongodb 2.4.9 is crashing on wheezy when running as root

I installed mongodb-10gen v2.4.9 on a debian Wheezy, and I'm having this really weird behavior: if I run it as root I can't get it starts: root@xx:~# /etc/init.d/mongodb stop [ ok ] Stopping database: mongodb. root@xx:~# /etc/init.d/mongodb…
franck
  • 123
  • 4
2
votes
2 answers

Redhat init script on startup

I installed Redhat 6.4 and created a new init script which updates a project using SVN. I then configured the script in chkconfig. The problem is everytime i restart the server i lose ssh connectivity for some reason (connection refused after the…
Danny Valariola
  • 263
  • 3
  • 12
2
votes
1 answer

php-fpm unable to restart because of another FPM instance

/etc/init.d/php-fpm restart Stopping php-fpm: [FAILED] Starting php-fpm: [10-Oct-2013 21:24:37] ERROR: An another FPM instance seems to already listen on /home/php-fpm/sock/gosianozka.sock [10-Oct-2013…
Spacedust
  • 558
  • 5
  • 12
  • 28
2
votes
1 answer

Kibana /etc/init.d scripts

I am having a hard time adapting the init.d start up scripts I have found for Kibana on the internet. I am experienced with RedHat/Centos but we have standardized on Suse Enterpise Linux here at work. So I need to port the init.d scripts I have been…
user35861
2
votes
1 answer

init script terminating with ssh session

We need to run pt-stalk on a handful of servers to keep an eye on mySQL, and I was sick of manually starting it every time the server rebooted. A little googling turned up an init script for pt-stalk, and it seemed to work just fine. [my slightly…
Sammitch
  • 2,072
  • 1
  • 20
  • 34
2
votes
1 answer

Mysql with upstart not starting

After an update this morning we are having some strange problems. First of all apt-get upgrade fails during the configuration with the a message that it was unable to start the service. We then attempted dpkg-reconfigure, apt-get purge followed by…
cdecker
  • 431
  • 2
  • 5
  • 17
2
votes
2 answers

RHEL4 script on shutdown

I need to backup some files every time I shutdown a Red Hat Enterprise Linux 4. I thought about make it with a script in /etc/rc0.d but shutdown process should wait for my script to finish. So the only idea I have is to make the script run first of…
Abraham
  • 63
  • 1
  • 1
  • 13
2
votes
2 answers

How to set a binary to init on boot like Apache does (run as a service)

I am trying to setup PhantomJS to run as a service. I found the skeleton file in /etc/init.d and I am running on Ubuntu 12.10. In trying to figure this out I found the symlinks in the /etc/rc*.d directories and found that Apache runs at run levels 2…
Patrick
  • 190
  • 10