If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to REGISTER before you can post. To start viewing messages, select the forum that you want to visit from the selection below.
Ad Widget
Collapse
what is the parameter used for finding the dead mails
be careful with mailq, it have to be run with superuser account, on other case it will only display the user's mail
the agent run under the zabbix user, you may have to use sudo too
the following commands can be useful for UserParam :
grep
cut
wc -l (to return the number of lines)
tr -d " " (to remove the unneeded spaces before using cut)
see the man for more details
just an example :
mysqladmin -uroot extended-status | grep Questions | cut -d \| -f 3 --output-delimiter="" | tr -d " "
mysqladmin -uroot extended-status : is quite explicit
grep Questions : select the line with the total number of questions since mysql restart
cut -d \| -f 3 --output-delimiter="" : returns the 3rd column (the number of questions), each column separated by a "|" (which have to be escaped with a "\")
and tr -d " " : which removes some head and trail spaces
i can't help you with mailq command, i don't use it
hope it can help you btw
Comment