memcached nevar atrast pid failu? CentOS 7 norādiet memcache pid

CentOS 7 ir jākonfigurē memcached Uzraudzīt uzraudzībuProgrammējot es saskāros ar problēmu, ka memcached nevarēja atrast pid failu...

memcached nevar atrast pid failu? CentOS 7 norādiet memcache pid

Visas konfigurācijas, ko varam atrast Google meklēšanā, satur šo rindiņu:

check process memcached with pidfile /var/run/memcached/memcached.pid

bet,/var/run nē iekšā memcached.pid failu, un Nr /var/run/memcached mapi.

izrakstījies /usr/lib/systemd/system/memcached.service

[Service]
Type=simple
EnvironmentFile=-/etc/sysconfig/memcached
ExecStart=/usr/bin/memcached -u $USER -p $PORT -m $CACHESIZE -c $MAXCONN $OPTIONS
  • Tāpēc nav ceļa uz .pid failu.
  • Kā pārbaudīt memcached bez .pid faila?
  • Vai arī šis .pid fails var atrasties citā vietā?

Kā CentOS 7 norāda memcache pid faila atrašanās vietas adresi?

Risinājums ir norādīt memcache pid faila adresi, ko norādījāt Monitor uzraudzības konfigurācijā ▼

check process memcached with pidfile /var/run/memcached/memcached.pid

Aizstāt ar tālāk norādītā atmiņā saglabātā pid▼ faila adresi

check process memcached with match memcached

Mūsu memcached konfigurācija:

check process memcached with match memcached
start program = "/usr/bin/systemctl start memcached"
stop program = "/usr/bin/systemctl stop memcached"
if failed host 127.0.0.1 port 11211 protocol MEMCACHE then restart
if cpu > 70% for 2 cycles then alert
if cpu > 98% for 5 cycles then restart
if 2 restarts within 3 cycles then timeout

Lai uzzinātu par Centos 7 Monit monitoringa 5.14 instalēšanas metodi, lūdzu, skatiet šo pamācību▼

发表 评论

Jūsu e-pasta adrese netiks publicēta. 必填 项 已 用 * Etiķete

Ritiniet uz augšu