2

I'm basically looking for the equivalent of :

sudo apt-get install daemon

From Debian

I'm trying to configure a Solr daemon as outlined here https://stackoverflow.com/a/2150888/443779

SMTF
  • 165
  • 2
  • 6
  • 1
    You can write your own init script for solr like this one: http://stackoverflow.com/questions/4420127/daemon-for-solr – deagh Sep 26 '13 at 18:24
  • Another way is to use a tanuki-wrapper, that's available in the CentOS/RHEL repos, IIRC. – dawud Sep 26 '13 at 18:27
  • @deagh that is again a Debian style init script and won't work on CentOS. – faker Sep 26 '13 at 19:40

1 Answers1

7

I don't believe you can get the Debian style daemon to work in CentOS, in CentOS it is more common to source /etc/init.d/functions in your init script.
This will make the daemon function available to you - with totally different options than the example you posted!

For a simple example check out the crond init script at /etc/init.d/crond.

faker
  • 17,496
  • 2
  • 60
  • 70