今天早上因为要自建一个日志服务,需要停掉服务器的syslogd, 因为它占用了514端口。但停了好久没有停掉,
#ps -ef|grep syslogd
root 4954 1 0 11:06:10 ? 0:15 /usr/sbin/syslogd
root 5030 4989 0 11:26:30 pts/2 0:00 grep syslog
# /etc/init.d/syslog stop
bash: /etc/init.d/syslog: No such file or directory
最后查了一些资料,用以下命令解决了问题:
# svcadm disable system-log
# ps -ef|grep syslogd
root 5034 4989 0 11:27:25 pts/2 0:00 grep syslogd
附# svcadm
Usage: svcadm [-v] [cmd [args ... ]]
svcadm enable [-rst] ... - enable and online service(s)
svcadm disable [-st] ... - disable and offline service(s)
svcadm restart ... - restart specified service(s)
svcadm refresh ... - re-read service configuration
svcadm mark [-It] ... - set maintenance state
svcadm clear ... - clear maintenance state
svcadm milestone [-d] - advance to a service milestone
Services can be specified using an FMRI, abbreviation, or fnmatch(5)
pattern, as shown in these examples for svc:/network/smtp:sendmail
svcadm svc:/network/smtp:sendmail
svcadm network/smtp:sendmail
svcadm network/*mail
svcadm network/smtp
svcadm smtp:sendmail
svcadm smtp
svcadm sendmail
(文/狼窝)
如果给你带来帮助,欢迎微信或支付宝扫一扫,赞一下。