<html><head>
<meta content="text/html; charset=ISO-8859-1" http-equiv="Content-Type">
</head><body style="font-family: Calibri; font-size: 11pt;"
bgcolor="#FFFFFF" text="#000000"><div style="font-size:
11pt;font-family: Calibri;"><span style="font-family: Calibri;">Ken,<br><br>I'm
not sure what I'm missing, but I've done pretty much all I know, but
still not getting any ware.<br>Here is info I can supply atm.<br><br><br><span
style="font-weight: bold;">SNMP:</span><br>ps aux | grep snmp<br>snmp
16011 0.0 0.0 49200 5520 ? S 22:13 0:00 /usr/sbin/snmpd
-Lsd -Lf /dev/null -u snmp -g snmp -I -smux -p /var/run/snmpd.pid<br><br><br><span
style="font-weight: bold;">SNMP.CONF</span><br>### ---- FreeSWITCH
Active Calls ----<br>extend .1.3.6.1.4.1.2021.8.1.101 curcalls
/usr/local/scripts/curcalls<br><br><br><span style="font-weight: bold;">USER:</span><br> id
snmp<br>uid=105(snmp) gid=106(snmp) groups=106(snmp),0(root),1(daemon)<br><br><br><span
style="font-weight: bold;">FS INIT:</span><br>/etc/init.d/freeswitch<br><br>FS_USER=freeswitch<br>FS_GROUP=daemon<br><br>#<br>#
Function that starts the daemon/service<br>#<br>do_start()<br>{<br> #
Set user to run as<br> if [ $FS_USER ] ; then<br>
DAEMON_ARGS="`echo $DAEMON_ARGS` -u $FS_USER"<br> fi<br> # Set
group to run as<br> if [ $FS_GROUP ] ; then<br>
DAEMON_ARGS="`echo $DAEMON_ARGS` -g $FS_GROUP"<br> fi<br><br><br><span
style="font-weight: bold;">FS_CLI:</span><br>-rwxrwxrwx 1 root
daemon 596002 Dec 10 08:42 fs_cli<br><br><br><span style="font-weight:
bold;">SCRIPT:</span><br>-rwxrwxrwx 1 root daemon 364 Jan 29 22:15
curcalls<br><br>#!/bin/bash<br>/usr/local/freeswitch/bin/fs_cli -x "show
calls count" | grep total | awk '{print $1}'<br><br><br><span
style="font-weight: bold;">SNMPWALK OUTPUT:</span><br>snmpwalk localhost
-c public -v2c .1.3.6.1.4.1.2021.8.1.101<br>iso.3.6.1.4.1.2021.8.1.101.1.0
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.2.1.2.8.99.117.114.99.97.108.108.115
= STRING: "/usr/local/scripts/curcalls"<br>iso.3.6.1.4.1.2021.8.1.101.2.1.3.8.99.117.114.99.97.108.108.115
= ""<br>iso.3.6.1.4.1.2021.8.1.101.2.1.4.8.99.117.114.99.97.108.108.115
= ""<br>iso.3.6.1.4.1.2021.8.1.101.2.1.5.8.99.117.114.99.97.108.108.115
= INTEGER: 5<br>iso.3.6.1.4.1.2021.8.1.101.2.1.6.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.2.1.7.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.2.1.20.8.99.117.114.99.97.108.108.115
= INTEGER: 4<br>iso.3.6.1.4.1.2021.8.1.101.2.1.21.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.3.1.1.8.99.117.114.99.97.108.108.115
= STRING: "/usr/local/scripts/curcalls: line 6:
/usr/local/freeswitch/bin/fs_cli: Permission denied"<br>iso.3.6.1.4.1.2021.8.1.101.3.1.2.8.99.117.114.99.97.108.108.115
= STRING: "/usr/local/scripts/curcalls: line 6:
/usr/local/freeswitch/bin/fs_cli: Permission denied"<br>iso.3.6.1.4.1.2021.8.1.101.3.1.3.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.3.1.4.8.99.117.114.99.97.108.108.115
= INTEGER: 0<br>iso.3.6.1.4.1.2021.8.1.101.4.1.2.8.99.117.114.99.97.108.108.115.1
= STRING: "/usr/local/scripts/curcalls: line 6:
/usr/local/freeswitch/bin/fs_cli: Permission denied"<br><br><br>Hope the
above provides enough information to find solution.<br><br>Thanks<br></span><div
class="moz-signature">-- <span><span style="background-color: rgba(255,
255, 255, 0);"><br>Deon</span></span><br></div><br><blockquote
style="border: 0px none;"
cite="mid:CF0E8E43.75DCA%25krice@freeswitch.org" type="cite"><div
style="margin:30px 25px 10px 25px;" class="__pbConvHr"><div
style="display:table;width:100%;border-top:1px solid
#EDEEF0;padding-top:5px">          <div
style="display:table-cell;white-space:nowrap;vertical-align:middle;width:100%">
        <a moz-do-not-send="true" href="mailto:krice@freeswitch.org"
style="color:#737F92
!important;padding-right:6px;font-weight:bold;text-decoration:none
!important;">Ken Rice</a></div> <div
style="display:table-cell;white-space:nowrap;vertical-align:middle;">
<font color="#9FA2A5"><span style="padding-left:6px">January 29, 2014
at 6:53 PM</span></font></div></div></div><div
style="color:#888888;margin-left:24px;margin-right:24px;"
__pbrmquotes="true" class="__pbConvBody">
<title>Re: [Freeswitch-users] SNMP fs_cli: Permission denied"</title>
<font face="Monaco, Courier New"><span style="font-size:11pt">The user
running snmpd does it have perms to execute fs_cli? Just because it can
exec the shell script doesn’t mean it has perms to exec fs_cli<br>
<br>
<br>
On 1/29/14 10:46 AM, "Deon Vermeulen" <<a moz-do-not-send="true"
href="vermeulen.deon@gmail.com">vermeulen.deon@gmail.com</a>> wrote:<br>
<br>
</span></font><span style="font-size:11pt"><font face="Calibri, Verdana,
Helvetica, Arial"><br>
</font><font face="Monaco, Courier New">-- <br>
Ken<br>
<font color="#0000FF"><u><a moz-do-not-send="true"
href="http://www.FreeSWITCH.org">http://www.FreeSWITCH.org</a><br>
<a moz-do-not-send="true" href="http://www.ClueCon.com">http://www.ClueCon.com</a><br>
<a moz-do-not-send="true" href="http://www.OSTAG.org">http://www.OSTAG.org</a><br>
</u></font>irc.freenode.net #freeswitch<br>
Twitter: @FreeSWITCH<br>
<br>
</font></span>
<div>_________________________________________________________________________<br>Professional
FreeSWITCH Consulting Services:<br><a class="moz-txt-link-abbreviated" href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br><a class="moz-txt-link-freetext" href="http://www.freeswitchsolutions.com">http://www.freeswitchsolutions.com</a><br><br>FreeSWITCH-powered
IP PBX: The CudaTel Communication Server<br><a class="moz-txt-link-freetext" href="http://www.cudatel.com">http://www.cudatel.com</a><br><br>Official
FreeSWITCH Sites<br><a class="moz-txt-link-freetext" href="http://www.freeswitch.org">http://www.freeswitch.org</a><br><a class="moz-txt-link-freetext" href="http://wiki.freeswitch.org">http://wiki.freeswitch.org</a><br><a class="moz-txt-link-freetext" href="http://www.cluecon.com">http://www.cluecon.com</a><br><br>FreeSWITCH-users
mailing list<br><a class="moz-txt-link-abbreviated" href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br><a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>UNSUBSCRIBE:<a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br><a class="moz-txt-link-freetext" href="http://www.freeswitch.org">http://www.freeswitch.org</a><br></div></div><div
style="margin:30px 25px 10px 25px;" class="__pbConvHr"><div
style="display:table;width:100%;border-top:1px solid
#EDEEF0;padding-top:5px">          <div
style="display:table-cell;white-space:nowrap;vertical-align:middle;width:100%">
        <a moz-do-not-send="true" href="mailto:vermeulen.deon@gmail.com"
style="color:#737F92
!important;padding-right:6px;font-weight:bold;text-decoration:none
!important;">Deon Vermeulen</a></div> <div
style="display:table-cell;white-space:nowrap;vertical-align:middle;">
<font color="#9FA2A5"><span style="padding-left:6px">January 29, 2014
at 6:46 PM</span></font></div></div></div><div
style="color:#888888;margin-left:24px;margin-right:24px;"
__pbrmquotes="true" class="__pbConvBody">
<meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
<div style="font-size: 11pt;font-family: Calibri;"><span
style="font-family: Calibri;">Hi<br><br>I'm trying to export calls count
into snmp for graphing with zenoss.<br>I used this post for cacti.
<a moz-do-not-send="true"
href="http://wiki.freeswitch.org/wiki/Snmp_Cacti"
class="moz-txt-link-freetext">http://wiki.freeswitch.org/wiki/Snmp_Cacti</a><br><br><br>Script:<br><br>#!/bin/bash<br>/usr/local/freeswitch/bin/fs_cli
-x "show calls count" | grep total | awk '{print $1}'<br><br><br>Permissions:<br><br>-rwxrwxrwx
1 root staff 295 Jan 29 17:01 curcalls<br><br><br>in snmpd.conf I have
following:<br><br>### ---- FreeSWITCH Active Calls ----<br>extend
.1.3.6.1.4.1.2021.8.1.101 curcalls /usr/local/scripts/curcalls<br><br><br>When
I run:<br><br>snmpwalk localhost -c public -v2c
.1.3.6.1.4.1.2021.8.1.101<br><br>I get following output:<br><br>iso.3.6.1.4.1.2021.8.1.101.1.0
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.2.1.2.8.99.117.114.99.97.108.108.115
= STRING: "/usr/local/freeswitch/bin/fs_cli -x 'show calls count' |
grep total | awk '{print $1}'"<br>iso.3.6.1.4.1.2021.8.1.101.2.1.3.8.99.117.114.99.97.108.108.115
= ""<br>iso.3.6.1.4.1.2021.8.1.101.2.1.4.8.99.117.114.99.97.108.108.115
= ""<br>iso.3.6.1.4.1.2021.8.1.101.2.1.5.8.99.117.114.99.97.108.108.115
= INTEGER: 5<br>iso.3.6.1.4.1.2021.8.1.101.2.1.6.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.2.1.7.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.2.1.20.8.99.117.114.99.97.108.108.115
= INTEGER: 4<br>iso.3.6.1.4.1.2021.8.1.101.2.1.21.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.3.1.1.8.99.117.114.99.97.108.108.115
= STRING: "/usr/local/freeswitch/bin/fs_cli: Permission denied"<br>iso.3.6.1.4.1.2021.8.1.101.3.1.2.8.99.117.114.99.97.108.108.115
= STRING: "/usr/local/freeswitch/bin/fs_cli: Permission denied"<br>iso.3.6.1.4.1.2021.8.1.101.3.1.3.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.3.1.4.8.99.117.114.99.97.108.108.115
= INTEGER: 1<br>iso.3.6.1.4.1.2021.8.1.101.4.1.2.8.99.117.114.99.97.108.108.115.1
= STRING: "/usr/local/freeswitch/bin/fs_cli: Permission denied"<br><br><br>I
run on Debian 6.0 with FreeSWITCH version:<br>FreeSWITCH Version
1.2.15+git~20131210T035405Z~b1288520bc~64bit (git b128852 2013-12-10
03:54:05Z 64bit)<br><br><br>Any input will be appreciated.<br><br><br>Thank
you<br></span>-- <br></div>
</div></blockquote></div></body></html>