MySQL 데이터베이스 프로세스 pidfile 파일은 어디에 있습니까?쿼리 MySQL pidfile 명령

리눅스 시스템 에서 MySQL 프로세스가 가끔씩 충돌하는 경우가 있는데 , MONIT 모니터링 프로그램을 설치하고 구성하려면 MySQL 시스템 프로세스의 pidfile 에 접근해야 합니다 . 하지만 이 pidfile을 어디서 어떻게 찾는지 아는 사람이 거의 없어서 이 정보를 공유합니다!

다음 두 SSH 명령은 mysql 프로세스를 볼 수 있습니다.

ps -ef|grep mysqld

watch -n 1 "ps -ef | grep mysql"

SSH는 다음과 같이 쿼리 결과를 반환합니다.

root 6206 1 0 16:19 ? 00:00:00 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-file=/var/lib/mysql/centos-ufo.pid
mysql 6280 6206 3 16:19 ? 00:00:22 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin --user=mysql --log-error=/var/lib/mysql/centos-ufo.err --pid-file=/var/lib/mysql/centos-ufo.pid
root 6691 1844 0 16:29 pts/0 00:00:00 grep mysqld

发表 评论

您的邮箱地址不会被公开。必填项已用*标注

위쪽으로 스크롤