postgresql daemons installed. How can make them start automatically every time server is started?
I think to add
sudo service nginx start sudo service postgresql start
~/.profile but not sure if it's a good practice.
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
First list the service using
[root@localhost ~]# chkconfig --list | grep -i postgresql postgresql-8.4 0:off 1:off 2:on 3:on 4:on 5:off 6:off
Suppose if you want to run
postgresql automatically every time server is started
Then Try this command
[root@localhost ~]# chkconfig --level 5 postgresql-8.4 on
--level means in which runlevel you want to start(on) the service in my case it's runlevel 5
Do the same for other service also
After doing this servcie will automatically start when system boots.
Try doing this :
cd /etc/init vim nginx*.conf
init (5) - Upstart init daemon job configuration init (7) - Upstart process management daemon init (8) - Upstart process management daemon
I mean :
man 5 init; man 7 init; man 8 init
found with :
man -k init | grep -o '^init (\w)' init (5) init (7) init (8)