Test UserParameter, system.run[] command with user zabbix

Zabbix Agent or Zabbix Server are running by user zabbix. Sometimes I need to test the remote command or UserParameter before I continue to integrete it in server/agent configuration.

By default zabbix user has now shell configured. This information can be determined with:
grep zabbix /etc/passwd
This will show:
zabbix:x:997:994:Zabbix Monitoring System:/var/lib/zabbix:/sbin/nologin
I can configure the shell for zabbix user by setting "/etc/passwd" like this:
zabbix:x:997:994:Zabbix Monitoring System:/var/lib/zabbix:/bin/bash
But there is another way to execute bash for user zabbix:
su -s /bin/bash zabbix

No comments: