[program: mongod]
command = / usr / local / bin / mongod --dbpath / Users / weixuan / Database / mongodbdata
autostart = true
startsecs = 3
autorestart = true
Basic use
After the Supervisord installation is complete, there are two command line supervisors and supervisorctl available
Common commands are as follows:
Command Description
Supervisord starts Supervisord initially, starts and manages the processes set in the configuration
supervisorctl stop programxxx Stop a certain process (programxxx), programxxx is the value configured in [program: chatdemon], this example is chatdemon
supervisorctl start programxxx start a process
supervisorctl restart programxxx restart a process
supervisorctl stop groupworker restarts all processes belonging to the group named groupworker (start and restart are the same)
supervisorctl stop all Stop all processes, note: start, restart, stop will not load the latest configuration file
supervisorctl reload Load the latest configuration file, stop the original process and start and manage all processes according to the new configuration
supervisorctl update According to the latest configuration file, start a new configuration or a process with changes. Processes without configuration changes will not be affected and restart. Note: Displaying the processes stopped by stop, using reload or update will not automatically restart common commands
supervisorctl tail programname View the log of programname
supervisorctl tail redis View log
error code
ERROR (abnormal termination)
Solution:
supervisorctl tail programname View specific log information of programname
Error: Another program is already listening on a port that one of our HTTP servers is configured to use. Shut this program down first before starting supervisord.
Solution:
sudo unlink /tmp/supervisor.sock
or
sudo unlink /var/run/supervisor.sock
gave up: redis entered FATAL state, too many start retries too quickly
Solution:
Modify daemonize of redis.conf to no
Redis installed by brew, the configuration file is in /usr/local/etc/redis.conf
Tip: vim search
# To search upward from the current cursor position
/ pattern
#pattern indicates the specific character sequence to be searched
# To search down from the current cursor position
? pattern
# Exact search
# To find a single place, type the word and add a space before and after it
/ place
other
Terminate mongodb
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.