Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

rwcommunity in snmpd.conf ignored by snmpd ("unknown token" in

1,010 views
Skip to first unread message

Paul Cerqua

unread,
Apr 13, 2008, 7:24:44 PM4/13/08
to
--===============1588298369==
Content-Type: multipart/alternative;
boundary="_88ce8e27-d88f-4db7-a3ef-059f1c620628_"

--_88ce8e27-d88f-4db7-a3ef-059f1c620628_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hello, all.

I've developed a couple of SNMP subagents over the last few months using ne=
t-snmp with good results. I've bumped into an issue involving rwcommunity =
that I don't quite understand and am hoping that somebody can give me an "A=
HA!" insight.

I'm using version 5.3.1 and only supporting V1 and V2c. I have two copies =
of snmpd running on a single system, each listening on different interfaces=
. One of these is the "master" and has its snmpd.conf file in a non-standa=
rd directory (I've defined the location using SNMPCONFPATH).

The issue here is that this snmpd master process appears to be ignoring the=
rwcommunity definition in its snmpd.conf file. I can specify any communit=
y on an snmpwalk and have it "succeed" when accessing this system.

The only hint I have as to what might be going on is something I noticed wh=
en turning on full debugging using -DALL. =20
The rwcommunity token is accessed twice by the snmpd master process; it rec=
ognizes it the first time, but not the second time ("unknown token"). This=
is true whether or not I prefix rwcommunity with [snmpd]. Also, I tried s=
pecifying the community via --rwcommunity=3D"prince" and had the same resul=
ts.

Here are some snippets from the debug log file:

read_config: config path used for
snmpd:/etc/snmp/master:/usr/share/snmp:/usr/lib/snmp:/root/.snmp (persisten=
t
path:/var/net-snmp)

=20

=20

read_config:
Reading configuration /etc/snmp/master/snmpd.conf

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:70 examining: master agentx

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:75 examining: agentuser root

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:86 examining: agentxsocket localhost:722

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:87 examining: smuxsocket 1.0.0.0

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:126 examining: rwcommunity prince

.

.

.

trace:
netsnmp_ds_set_string(): default_store.c, 283:

netsnmp_ds_set_string:
Setting APP:5 =3D "1.0.0.0"

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:126 examining: rwcommunity prince

/etc/snmp/master/snmpd.conf:
line 126: Warning: Unknown token: rwcommunity.

=20

Here are similar snippets using [snmpd] and using --rwcommunity:


=20

=20

trace:
read_config(): read_config.c, 756:

read_config:
Switching to new context: (this line only) snmpd

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:126 examining: [snmpd] rwcommunity prince

.

.

trace:
read_config(): read_config.c, 779:

read_config:
/etc/snmp/master/snmpd.conf:126 examining: [snmpd] rwcommunity prince

/etc/snmp/master/snmpd.conf:
line 126: Warning: Unknown token: rwcommunity.

=20

**

=20

=20

trace:
netsnmp_config_process_memory_list(): read_config.c, 631:

read_config:
processing memory: rwcommunity prince

.

.

.

=20

trace:
netsnmp_config_process_memory_list(): read_config.c, 631:

read_config:
processing memory: rwcommunity prince

: line 0:
Warning: Unknown token: rwcommunity.

=20

=20

Is there anything obvious here that I'm missing?

Thanks,
Paul

_________________________________________________________________
More immediate than e-mail? Get instant access with Windows Live Messenger.
http://www.windowslive.com/messenger/overview.html?ocid=3DTXT_TAGLM_WL_Refr=
esh_instantaccess_042008=

--_88ce8e27-d88f-4db7-a3ef-059f1c620628_
Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class=3D'hmmessage'>
<br>Hello, all.<br><br>I've developed a couple of SNMP subagents over the l=
ast few months using net-snmp with good results.&nbsp; I've bumped into an =
issue involving rwcommunity that I don't quite understand and am hoping tha=
t somebody can give me an "AHA!" insight.<br><br>I'm using version 5.3.1 an=
d only supporting V1 and V2c.&nbsp; I have two copies of snmpd running on a=
single system, each listening on different interfaces.&nbsp; One of these =
is the "master" and has its snmpd.conf file in a non-standard directory (I'=
ve defined the location using SNMPCONFPATH).<br><br>The issue here is that =
this snmpd master process appears to be ignoring the rwcommunity definition=
in its snmpd.conf file.&nbsp; I can specify any community on an snmpwalk a=
nd have it "succeed" when accessing this system.<br><br>The only hint I hav=
e as to what might be going on is something I noticed when turning on full =
debugging using -DALL.&nbsp; <br>The rwcommunity token is accessed twice by=
the snmpd master process; it recognizes it the first time, but not the sec=
ond time ("unknown token").&nbsp; This is true whether or not I prefix rwco=
mmunity with [snmpd].&nbsp; Also, I tried specifying the community via --rw=
community=3D"prince" and had the same results.<br><br>Here are some snippet=
s from the debug log file:<br><br>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:<span style=3D"">&nbsp; </span>config path used for
snmpd:/etc/snmp/master:/usr/share/snmp:/usr/lib/snmp:/root/.snmp (persisten=
t
path:/var/net-snmp)<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
Reading configuration /etc/snmp/master/snmpd.conf<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:70 examining: master<span style=3D"">&nbsp; </s=
pan>agentx<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:75 examining: agentuser<span style=3D"">&nbsp; =
</span>root<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:86 examining: agentxsocket<span style=3D"">&nbs=
p; </span>localhost:722<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:87 examining: smuxsocket 1.0.0.0<o:p></o:p></sp=
an></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:126 examining: rwcommunity prince<o:p></o:p></s=
pan></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
netsnmp_ds_set_string(): default_store.c, 283:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>netsnmp_ds_set_string:
Setting APP:5 =3D "1.0.0.0"<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:126 examining: rwcommunity prince<o:p></o:p></s=
pan></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>/etc/snmp/master/snmpd.conf:
line 126: Warning: Unknown token: rwcommunity.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

Here are similar snippets using [snmpd] and using --rwcommunity:<br><br><br=
>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 756:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
Switching to new context: (this line only) snmpd<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:126 examining: [snmpd]<span style=3D"">&nbsp; <=
/span>rwcommunity prince<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
read_config(): read_config.c, 779:<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
/etc/snmp/master/snmpd.conf:126 examining: [snmpd]<span style=3D"">&nbsp; <=
/span>rwcommunity prince<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>/etc/snmp/master/snmpd.conf:
line 126: Warning: Unknown token: rwcommunity.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>**<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
netsnmp_config_process_memory_list(): read_config.c, 631:<o:p></o:p></span>=
</p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
processing memory: rwcommunity prince<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>trace:
netsnmp_config_process_memory_list(): read_config.c, 631:<o:p></o:p></span>=
</p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>read_config:
processing memory: rwcommunity prince<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
>: line 0:
Warning: Unknown token: rwcommunity.<o:p></o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>

<p class=3D"MsoNormal"><span style=3D"font-size: 10pt; font-family: Arial;"=
><o:p>&nbsp;</o:p></span></p>Is there anything obvious here that I'm missin=
g?<br><br>&nbsp;&nbsp;&nbsp; Thanks,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Paul=
<br><br><br><br /><hr />More immediate than e-mail? <a href=3D'http://www.w=
indowslive.com/messenger/overview.html?ocid=3DTXT_TAGLM_WL_Refresh_instanta=
ccess_042008' target=3D'_new'>Get instant access with Windows Live Messenge=
r.</a></body>
</html>=

--_88ce8e27-d88f-4db7-a3ef-059f1c620628_--


--===============1588298369==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
--===============1588298369==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Net-snmp-users mailing list
Net-snm...@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

--===============1588298369==--

Thomas Anders

unread,
Apr 13, 2008, 11:54:40 PM4/13/08
to
Paul Cerqua wrote:
> read_config: /etc/snmp/master/snmpd.conf:126 examining: rwcommunity prince
>
> /etc/snmp/master/snmpd.conf: line 126: Warning: Unknown token: rwcommunity.

What's the output of:

- net-snmp-config --configure-options
- net-snmp-config --snmpd-module-list | tr " " "\n"
- /path/to/snmpd -H 2>&1 | grep community


+Thomas

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

Paul Cerqua

unread,
Apr 14, 2008, 9:44:28 AM4/14/08
to
--===============0102937689==
Content-Type: multipart/alternative;
boundary="_986a9a21-3bcd-4c89-944d-1a4ee4df5c23_"

--_986a9a21-3bcd-4c89-944d-1a4ee4df5c23_


Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Thanks for the reply, Thomas.

Here's the info you requested:

net-snmp-config --configure-options

'--build=3Di686-redhat-linux-gnu' '--host=3Di686-redhat-linux-gnu' '--targe=
t=3Di386-redhat-linux-gnu' '--program-prefix=3D' '--prefix=3D/usr' '--exec-=
prefix=3D/usr' '--bindir=3D/usr/bin' '--sbindir=3D/usr/sbin' '--datadir=3D/=
usr/share' '--includedir=3D/usr/include/net-snmp' '--libdir=3D/usr/lib' '--=
libexecdir=3D/usr/libexec' '--localstatedir=3D/var' '--sharedstatedir=3D/us=
r/com' '--mandir=3D/usr/share/man' '--infodir=3D/usr/share/info' '--enable-=
static' '--enable-shared' '--with-cflags=3D-O2 -g -pipe -Wall -Wp,-D_FORTIF=
Y_SOURCE=3D2 -fexceptions -fstack-protector --param=3Dssp-buffer-size=3D4 -=
m32 -march=3Di386 -mtune=3Dgeneric -fasynchronous-unwind-tables -lcrypto' '=
--with-ldflags=3D' '--with-sys-location=3DUnknown' '--with-logfile=3D/var/l=
og/snmpd.log' '--with-persistent-directory=3D/var/net-snmp' '--with-mib-mod=
ules=3Dhost agentx smux ucd-snmp/lmSensors ucd-snmp/diskio disman/event-=
mib tcp-mib udp-mib mibII/mta_sendmail' '--with-libwrap=3D/usr/lib' '--sysc=
onfdir=3D/etc' '--enable-ipv6' '--enable-ucd-snmp-compatibility' '--with-op=
enssl' '--with-pic' '--enable-embedded-perl' '--enable-mfd-rewrites' '--ena=
ble-local-smux' '--with-sys-contact=3Droot@localhost' 'CFLAGS=3D-O2 -g -pip=
e -Wall -Wp,-D_FORTIFY_SOURCE=3D2 -fexceptions -fstack-protector --param=3D=
ssp-buffer-size=3D4 -m32 -march=3Di386 -mtune=3Dgeneric -fasynchronous-unwi=
nd-tables' 'build_alias=3Di686-redhat-linux-gnu' 'host_alias=3Di686-redhat-=
linux-gnu' 'target_alias=3Di386-redhat-linux-gnu'

net-snmp-config --snmpd-module-list | tr " " "\n"

ucd-snmp/lmSensors
ucd-snmp/diskio
mibII/mta_sendmail
mibII/ipv6
mibII/system_mib
mibII/sysORTable
mibII/at
mibII/ip
mibII/snmp_mib
mibII/tcp
mibII/icmp
mibII/udp
mibII/vacm_vars
mibII/setSerialNo
ucd-snmp/memory
ucd-snmp/vmstat
ucd-snmp/proc
ucd-snmp/versioninfo
ucd-snmp/pass
ucd-snmp/pass_persist
ucd-snmp/disk
ucd-snmp/loadave
ucd-snmp/extensible
agent/extend
ucd-snmp/errormib
ucd-snmp/file
ucd-snmp/dlmod
ucd-snmp/proxy
ucd-snmp/logmatch
snmpv3/snmpEngine
snmpv3/snmpMPDStats
snmpv3/usmStats
snmpv3/usmConf
snmpv3/usmUser
notification/snmpNotifyTable
notification/snmpNotifyFilterProfileTable
notification-log-mib/notification_log
target/snmpTargetAddrEntry
target/snmpTargetParamsEntry
target/target
target/target_counters
agent/nsTransactionTable
agent/nsModuleTable
agent/nsDebug
agent/nsCache
agent/nsLogging
agentx/master
agentx/subagent
disman/schedule/schedCore
disman/schedule/schedConf
disman/schedule/schedTable
utilities/override
utilities/execute
utilities/iquery
host/hr_system
host/hr_storage
host/hr_device
host/hr_other
host/hr_proc
host/hr_network
host/hr_print
host/hr_disk
host/hr_partition
host/hr_filesys
host/hr_swrun
host/hr_swinst
smux/smux
util_funcs
mibII/var_route
mibII/route_write
mibII/kernel_linux
mibII/ipAddr
mibII/tcpTable
mibII/udpTable
mibII/vacm_context
mibII/vacm_conf
ip-mib/ip_scalars
header_complex
snmp-notification-mib/snmpNotifyFilterTable/snmpNotifyFilterTable
agentx/protocol
agentx/client
agentx/master_admin
agentx/agentx_config
disman/event/mteScalars
disman/event/mteTrigger
disman/event/mteTriggerTable
disman/event/mteTriggerDeltaTable
disman/event/mteTriggerExistenceTable
disman/event/mteTriggerBooleanTable
disman/event/mteTriggerThresholdTable
disman/event/mteTriggerConf
disman/event/mteEvent
disman/event/mteEventTable
disman/event/mteEventSetTable
disman/event/mteEventNotificationTable
disman/event/mteEventConf
disman/event/mteObjects
disman/event/mteObjectsTable
disman/event/mteObjectsConf
tcp-mib/tcpConnectionTable/tcpConnectionTable
tcp-mib/tcpListenerTable/tcpListenerTable
udp-mib/udpEndpointTable/udpEndpointTable
if-mib/ifTable/ifTable
ip-mib/ipAddressTable/ipAddressTable
ip-mib/inetNetToMediaTable/inetNetToMediaTable
ip-mib/inetNetToMediaTable/inetNetToMediaTable_interface
ip-mib/inetNetToMediaTable/inetNetToMediaTable_data_access
ip-mib/ipSystemStatsTable/ipSystemStatsTable
ip-mib/ipSystemStatsTable/ipSystemStatsTable_interface
ip-mib/ipSystemStatsTable/ipSystemStatsTable_data_access
if-mib/ifXTable/ifXTable
ip-forward-mib/ipCidrRouteTable/ipCidrRouteTable
ip-forward-mib/inetCidrRouteTable/inetCidrRouteTable
hardware/memory/memory_linux
hardware/memory/hw_mem
hardware/cpu/cpu_linux
hardware/cpu/cpu
snmp-notification-mib/snmpNotifyFilterTable/snmpNotifyFilterTable_interface
snmp-notification-mib/snmpNotifyFilterTable/snmpNotifyFilterTable_data_acce=
ss
tcp-mib/data_access/tcpConn_common
tcp-mib/data_access/tcpConn_linux
tcp-mib/tcpConnectionTable/tcpConnectionTable_interface
tcp-mib/tcpConnectionTable/tcpConnectionTable_data_access
tcp-mib/tcpListenerTable/tcpListenerTable_interface
tcp-mib/tcpListenerTable/tcpListenerTable_data_access
udp-mib/udpEndpointTable/udpEndpointTable_interface
udp-mib/udpEndpointTable/udpEndpointTable_data_access
if-mib/data_access/interface
if-mib/ifTable/ifTable_interface
if-mib/ifTable/ifTable_data_access
ip-mib/ipAddressTable/ipAddressTable_interface
ip-mib/ipAddressTable/ipAddressTable_data_access
ip-mib/data_access/arp_common
ip-mib/data_access/arp_linux
ip-mib/data_access/systemstats_common
ip-mib/data_access/systemstats_linux
ip-mib/data_access/scalars_linux
if-mib/ifXTable/ifXTable_interface
if-mib/ifXTable/ifXTable_data_access
ip-forward-mib/ipCidrRouteTable/ipCidrRouteTable_interface
ip-forward-mib/ipCidrRouteTable/ipCidrRouteTable_data_access
ip-forward-mib/inetCidrRouteTable/inetCidrRouteTable_interface
ip-forward-mib/inetCidrRouteTable/inetCidrRouteTable_data_access
udp-mib/data_access/udp_endpoint_common
udp-mib/data_access/udp_endpoint_linux
if-mib/data_access/interface_linux
if-mib/data_access/interface_ioctl
ip-mib/data_access/ipaddress_common
ip-mib/data_access/ipaddress_linux
ip-forward-mib/data_access/route_common
ip-forward-mib/data_access/route_linux
ip-forward-mib/data_access/route_ioctl
ip-mib/data_access/ipaddress_ioctl

/path/to/snmpd -H 2>&1 | grep community

trapsink host [community] [port]
trap2sink host [community] [port]
informsink host [community] [port]
trapcommunity community-string
com2sec [-Cn CONTEXT] secName IPv4-network-address[/ne=
tmask] community
com2sec6 [-Cn CONTEXT] secName IPv6-network-address[/ne=
tmask] community
com2secunix [-Cn CONTEXT] secName sockpath community
authcommunity authtype1,authtype2 community [default|hostnam=
e|network/bits [oid|-V view]]
rwcommunity community [default|hostname|network/bits [oid]=
]
rocommunity community [default|hostname|network/bits [oid]=
]
rwcommunity6 community [default|hostname|network/bits [oid]=
]
rocommunity6 community [default|hostname|network/bits [oid]=
]

> Date: Mon, 14 Apr 2008 05:57:41 +0200
> From: thomas...@blue-cable.de
> To: paulc...@hotmail.com
> Subject: Re: rwcommunity in snmpd.conf ignored by snmpd ("unknown token" =
in debug output)
> CC: net-snm...@lists.sourceforge.net
>=20
> Paul Cerqua wrote:
> > read_config: /etc/snmp/master/snmpd.conf:126 examining: rwcommunity pri=
nce
> >=20
> > /etc/snmp/master/snmpd.conf: line 126: Warning: Unknown token: rwcommun=
ity.
>=20


> What's the output of:

>=20


> - net-snmp-config --configure-options
> - net-snmp-config --snmpd-module-list | tr " " "\n"
> - /path/to/snmpd -H 2>&1 | grep community

>=20
>=20
> +Thomas
>=20
> -------------------------------------------------------------------------
> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference=20
> Don't miss this year's exciting event. There's still time to save $100.=20
> Use priority code J8TL2D2.=20
> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/ja=


vaone
> _______________________________________________
> Net-snmp-users mailing list
> Net-snm...@lists.sourceforge.net
> Please see the following page to unsubscribe or change other options:
> https://lists.sourceforge.net/lists/listinfo/net-snmp-users

>=20

_________________________________________________________________
Use video conversation to talk face-to-face with Windows Live Messenger.
http://www.windowslive.com/messenger/connect_your_way.html?ocid=3DTXT_TAGLM=
_WL_Refresh_messenger_video_042008=

--_986a9a21-3bcd-4c89-944d-1a4ee4df5c23_


Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class=3D'hmmessage'>

<br>Thanks for the reply, Thomas.<br><br>Here's the info you requested:<br>=
<br>net-snmp-config --configure-options<br><br>'--build=3Di686-redhat-linux=
-gnu' '--host=3Di686-redhat-linux-gnu' '--target=3Di386-redhat-linux-gnu' '=
--program-prefix=3D' '--prefix=3D/usr' '--exec-prefix=3D/usr' '--bindir=3D/=
usr/bin' '--sbindir=3D/usr/sbin' '--datadir=3D/usr/share' '--includedir=3D/=
usr/include/net-snmp' '--libdir=3D/usr/lib' '--libexecdir=3D/usr/libexec' '=
--localstatedir=3D/var' '--sharedstatedir=3D/usr/com' '--mandir=3D/usr/shar=
e/man' '--infodir=3D/usr/share/info' '--enable-static' '--enable-shared' '-=
-with-cflags=3D-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=3D2 -fexceptions -f=
stack-protector --param=3Dssp-buffer-size=3D4 -m32 -march=3Di386 -mtune=3Dg=
eneric -fasynchronous-unwind-tables -lcrypto' '--with-ldflags=3D' '--with-s=
ys-location=3DUnknown' '--with-logfile=3D/var/log/snmpd.log' '--with-persis=
tent-directory=3D/var/net-snmp' '--with-mib-modules=3Dhost agentx smux ucd-=
snmp/lmSensors&nbsp;&nbsp;&nbsp; ucd-snmp/diskio disman/event-mib tcp-mib u=
dp-mib mibII/mta_sendmail' '--with-libwrap=3D/usr/lib' '--sysconfdir=3D/etc=
' '--enable-ipv6' '--enable-ucd-snmp-compatibility' '--with-openssl' '--wit=
h-pic' '--enable-embedded-perl' '--enable-mfd-rewrites' '--enable-local-smu=
x' '--with-sys-contact=3Droot@localhost' 'CFLAGS=3D-O2 -g -pipe -Wall -Wp,-=
D_FORTIFY_SOURCE=3D2 -fexceptions -fstack-protector --param=3Dssp-buffer-si=
ze=3D4 -m32 -march=3Di386 -mtune=3Dgeneric -fasynchronous-unwind-tables' 'b=
uild_alias=3Di686-redhat-linux-gnu' 'host_alias=3Di686-redhat-linux-gnu' 't=
arget_alias=3Di386-redhat-linux-gnu'<br><br><br><br>net-snmp-config --snmpd=
-module-list | tr " " "\n"<br><br>ucd-snmp/lmSensors<br>ucd-snmp/diskio<br>=
mibII/mta_sendmail<br>mibII/ipv6<br>mibII/system_mib<br>mibII/sysORTable<br=
>mibII/at<br>mibII/ip<br>mibII/snmp_mib<br>mibII/tcp<br>mibII/icmp<br>mibII=
/udp<br>mibII/vacm_vars<br>mibII/setSerialNo<br>ucd-snmp/memory<br>ucd-snmp=
/vmstat<br>ucd-snmp/proc<br>ucd-snmp/versioninfo<br>ucd-snmp/pass<br>ucd-sn=
mp/pass_persist<br>ucd-snmp/disk<br>ucd-snmp/loadave<br>ucd-snmp/extensible=
<br>agent/extend<br>ucd-snmp/errormib<br>ucd-snmp/file<br>ucd-snmp/dlmod<br=
>ucd-snmp/proxy<br>ucd-snmp/logmatch<br>snmpv3/snmpEngine<br>snmpv3/snmpMPD=
Stats<br>snmpv3/usmStats<br>snmpv3/usmConf<br>snmpv3/usmUser<br>notificatio=
n/snmpNotifyTable<br>notification/snmpNotifyFilterProfileTable<br>notificat=
ion-log-mib/notification_log<br>target/snmpTargetAddrEntry<br>target/snmpTa=
rgetParamsEntry<br>target/target<br>target/target_counters<br>agent/nsTrans=
actionTable<br>agent/nsModuleTable<br>agent/nsDebug<br>agent/nsCache<br>age=
nt/nsLogging<br>agentx/master<br>agentx/subagent<br>disman/schedule/schedCo=
re<br>disman/schedule/schedConf<br>disman/schedule/schedTable<br>utilities/=
override<br>utilities/execute<br>utilities/iquery<br>host/hr_system<br>host=
/hr_storage<br>host/hr_device<br>host/hr_other<br>host/hr_proc<br>host/hr_n=
etwork<br>host/hr_print<br>host/hr_disk<br>host/hr_partition<br>host/hr_fil=
esys<br>host/hr_swrun<br>host/hr_swinst<br>smux/smux<br>util_funcs<br>mibII=
/var_route<br>mibII/route_write<br>mibII/kernel_linux<br>mibII/ipAddr<br>mi=
bII/tcpTable<br>mibII/udpTable<br>mibII/vacm_context<br>mibII/vacm_conf<br>=
ip-mib/ip_scalars<br>header_complex<br>snmp-notification-mib/snmpNotifyFilt=
erTable/snmpNotifyFilterTable<br>agentx/protocol<br>agentx/client<br>agentx=
/master_admin<br>agentx/agentx_config<br>disman/event/mteScalars<br>disman/=
event/mteTrigger<br>disman/event/mteTriggerTable<br>disman/event/mteTrigger=
DeltaTable<br>disman/event/mteTriggerExistenceTable<br>disman/event/mteTrig=
gerBooleanTable<br>disman/event/mteTriggerThresholdTable<br>disman/event/mt=
eTriggerConf<br>disman/event/mteEvent<br>disman/event/mteEventTable<br>dism=
an/event/mteEventSetTable<br>disman/event/mteEventNotificationTable<br>dism=
an/event/mteEventConf<br>disman/event/mteObjects<br>disman/event/mteObjects=
Table<br>disman/event/mteObjectsConf<br>tcp-mib/tcpConnectionTable/tcpConne=
ctionTable<br>tcp-mib/tcpListenerTable/tcpListenerTable<br>udp-mib/udpEndpo=
intTable/udpEndpointTable<br>if-mib/ifTable/ifTable<br>ip-mib/ipAddressTabl=
e/ipAddressTable<br>ip-mib/inetNetToMediaTable/inetNetToMediaTable<br>ip-mi=
b/inetNetToMediaTable/inetNetToMediaTable_interface<br>ip-mib/inetNetToMedi=
aTable/inetNetToMediaTable_data_access<br>ip-mib/ipSystemStatsTable/ipSyste=
mStatsTable<br>ip-mib/ipSystemStatsTable/ipSystemStatsTable_interface<br>ip=
-mib/ipSystemStatsTable/ipSystemStatsTable_data_access<br>if-mib/ifXTable/i=
fXTable<br>ip-forward-mib/ipCidrRouteTable/ipCidrRouteTable<br>ip-forward-m=
ib/inetCidrRouteTable/inetCidrRouteTable<br>hardware/memory/memory_linux<br=
>hardware/memory/hw_mem<br>hardware/cpu/cpu_linux<br>hardware/cpu/cpu<br>sn=
mp-notification-mib/snmpNotifyFilterTable/snmpNotifyFilterTable_interface<b=
r>snmp-notification-mib/snmpNotifyFilterTable/snmpNotifyFilterTable_data_ac=
cess<br>tcp-mib/data_access/tcpConn_common<br>tcp-mib/data_access/tcpConn_l=
inux<br>tcp-mib/tcpConnectionTable/tcpConnectionTable_interface<br>tcp-mib/=
tcpConnectionTable/tcpConnectionTable_data_access<br>tcp-mib/tcpListenerTab=
le/tcpListenerTable_interface<br>tcp-mib/tcpListenerTable/tcpListenerTable_=
data_access<br>udp-mib/udpEndpointTable/udpEndpointTable_interface<br>udp-m=
ib/udpEndpointTable/udpEndpointTable_data_access<br>if-mib/data_access/inte=
rface<br>if-mib/ifTable/ifTable_interface<br>if-mib/ifTable/ifTable_data_ac=
cess<br>ip-mib/ipAddressTable/ipAddressTable_interface<br>ip-mib/ipAddressT=
able/ipAddressTable_data_access<br>ip-mib/data_access/arp_common<br>ip-mib/=
data_access/arp_linux<br>ip-mib/data_access/systemstats_common<br>ip-mib/da=
ta_access/systemstats_linux<br>ip-mib/data_access/scalars_linux<br>if-mib/i=
fXTable/ifXTable_interface<br>if-mib/ifXTable/ifXTable_data_access<br>ip-fo=
rward-mib/ipCidrRouteTable/ipCidrRouteTable_interface<br>ip-forward-mib/ipC=
idrRouteTable/ipCidrRouteTable_data_access<br>ip-forward-mib/inetCidrRouteT=
able/inetCidrRouteTable_interface<br>ip-forward-mib/inetCidrRouteTable/inet=
CidrRouteTable_data_access<br>udp-mib/data_access/udp_endpoint_common<br>ud=
p-mib/data_access/udp_endpoint_linux<br>if-mib/data_access/interface_linux<=
br>if-mib/data_access/interface_ioctl<br>ip-mib/data_access/ipaddress_commo=
n<br>ip-mib/data_access/ipaddress_linux<br>ip-forward-mib/data_access/route=
_common<br>ip-forward-mib/data_access/route_linux<br>ip-forward-mib/data_ac=
cess/route_ioctl<br>ip-mib/data_access/ipaddress_ioctl<br><br><br><br>/path=
/to/snmpd -H 2&gt;&amp;1 | grep community<br><br>&nbsp;&nbsp;&nbsp; trapsin=
k&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp; host [community] [port]<br>&nbsp;&nbsp;&nbsp; trap2s=
ink&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp; host [community] [port]<br>&nbsp;&nbsp;&nbsp; informsink=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp; host [community] [port]<br>&nbsp;&nbsp;&nbsp; trapcommunity&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; community-stri=
ng<br>&nbsp;&nbsp;&nbsp; com2sec&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&=
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [-Cn CONTEXT] s=
ecName IPv4-network-address[/netmask] community<br>&nbsp;&nbsp;&nbsp; com2s=
ec6&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp; [-Cn CONTEXT] secName IPv6-network-address[/netmas=
k] community<br>&nbsp;&nbsp;&nbsp; com2secunix&nbsp;&nbsp;&nbsp;&nbsp;&nbsp=
;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [-Cn CONTEXT] secName soc=
kpath community<br>&nbsp;&nbsp;&nbsp; authcommunity&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; authtype1,authtype2 community [d=
efault|hostname|network/bits [oid|-V view]]<br>&nbsp;&nbsp;&nbsp; rwcommuni=
ty&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&=
nbsp; community [default|hostname|network/bits [oid]]<br>&nbsp;&nbsp;&nbsp;=
rocommunity&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp; community [default|hostname|network/bits [oid]]<br>&nbsp;&n=
bsp;&nbsp; rwcommunity6&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;&nbsp; community [default|hostname|network/bits [oid]]<br>&nb=
sp;&nbsp;&nbsp; rocommunity6&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp=
;&nbsp;&nbsp;&nbsp;&nbsp; community [default|hostname|network/bits [oid]]<b=
r><br><br><br>&gt; Date: Mon, 14 Apr 2008 05:57:41 +0200<br>&gt; From: thom=
as.a...@blue-cable.de<br>&gt; To: paulc...@hotmail.com<br>&gt; Subject:=
Re: rwcommunity in snmpd.conf ignored by snmpd ("unknown token" in debug o=
utput)<br>&gt; CC: net-snm...@lists.sourceforge.net<br>&gt; <br>&gt; Pa=
ul Cerqua wrote:<br>&gt; &gt; read_config: /etc/snmp/master/snmpd.conf:126 =
examining: rwcommunity prince<br>&gt; &gt; <br>&gt; &gt; /etc/snmp/master/s=
nmpd.conf: line 126: Warning: Unknown token: rwcommunity.<br>&gt; <br>&gt; =
What's the output of:<br>&gt; <br>&gt; - net-snmp-config --configure-option=
s<br>&gt; - net-snmp-config --snmpd-module-list | tr " " "\n"<br>&gt; - /pa=
th/to/snmpd -H 2&gt;&amp;1 | grep community<br>&gt; <br>&gt; <br>&gt; +Thom=
as<br>&gt; <br>&gt; -------------------------------------------------------=
------------------<br>&gt; This SF.net email is sponsored by the 2008 JavaO=
ne(SM) Conference <br>&gt; Don't miss this year's exciting event. There's s=
till time to save $100. <br>&gt; Use priority code J8TL2D2. <br>&gt; http:/=
/ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone<br=
>&gt; _______________________________________________<br>&gt; Net-snmp-user=
s mailing list<br>&gt; Net-snm...@lists.sourceforge.net<br>&gt; Please =
see the following page to unsubscribe or change other options:<br>&gt; http=
s://lists.sourceforge.net/lists/listinfo/net-snmp-users<br>&gt; <br><br /><=
hr />Use video conversation to talk face-to-face with Windows Live Messenge=
r. <a href=3D'http://www.windowslive.com/messenger/connect_your_way.html?oc=
id=3DTXT_TAGLM_WL_Refresh_messenger_video_042008' target=3D'_new'>Get start=
ed!</a></body>
</html>=

--_986a9a21-3bcd-4c89-944d-1a4ee4df5c23_--


--===============0102937689==


Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

-------------------------------------------------------------------------


This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

--===============0102937689==


Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________


Net-snmp-users mailing list
Net-snm...@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

--===============0102937689==--

Dave Shield

unread,
Apr 14, 2008, 10:10:21 AM4/14/08
to
On 14/04/2008, Paul Cerqua <paulc...@hotmail.com> wrote:
> The rwcommunity token is accessed twice by the snmpd master process; it
> recognizes it the first time, but not the second time ("unknown token").
> This is true whether or not I prefix rwcommunity with [snmpd]. Also, I
> tried specifying the community via --rwcommunity="prince" and had the same
> results.

This is a bit of a long-shot, but it's worth checking whether there might
be some non-printing characters in the config file, that are confusing
the config parsing code.

What does the command

sed -n 126p /etc/snmp/master/snmpd.conf | cat -vte

display?

Also, how are you starting the agent?
What's the exact command that you invoke?

Dave

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

Paul Cerqua

unread,
Apr 14, 2008, 10:33:29 AM4/14/08
to
--===============1288622838==
Content-Type: multipart/alternative;
boundary="_7b762034-c88e-420c-9fe9-2e8a3c7f43e6_"

--_7b762034-c88e-420c-9fe9-2e8a3c7f43e6_


Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Thanks, Dave.

I thought about the unprintable characters, too; does it make sense that I =
would get similar messages (except that they reference "memory") when using=
--rwcommunity=3D"prince" on the command line?

> What does the command
>=20


> sed -n 126p /etc/snmp/master/snmpd.conf | cat -vte

>=20
> display?

rwcommunity prince$

[In the snmpd.conf file, that line looks like: rwcommunity prince <-- =
no $.]


>=20


> Also, how are you starting the agent?
> What's the exact command that you invoke?
>

Including the debug info, it looks like:

daemon /usr/sbin/snmpd -DALL -Lf /var/log/snmpdmaster.log $OPTIONS $IPADDR:=
161

where:

OPTIONS=3D"-LS 3 d -Lf /dev/null -p /var/run/snmpdmaster -a -I smux"

and:

$IPADDR is the sole IP address over which I wish to accept SNMP requests.

Hmmm.... You may have hit on something here. I'm suspicious of that "-I s=
mux"; I added that months ago and I can't remember why. I think I was tryi=
ng to make it forget about all the MIBs it knows about (since I'm servicing=
them another way).

- Paul


> Date: Mon, 14 Apr 2008 15:07:48 +0100
> From: D.T.S...@liverpool.ac.uk


> To: paulc...@hotmail.com
> Subject: Re: rwcommunity in snmpd.conf ignored by snmpd ("unknown token" =
in debug output)
> CC: net-snm...@lists.sourceforge.net
>=20

> On 14/04/2008, Paul Cerqua <paulc...@hotmail.com> wrote:
> > The rwcommunity token is accessed twice by the snmpd master process; it

> > recognizes it the first time, but not the second time ("unknown token")=


.
> > This is true whether or not I prefix rwcommunity with [snmpd]. Also, I

> > tried specifying the community via --rwcommunity=3D"prince" and had the=
same
> > results.
>=20


> This is a bit of a long-shot, but it's worth checking whether there might
> be some non-printing characters in the config file, that are confusing
> the config parsing code.

>=20
> What does the command
>=20


> sed -n 126p /etc/snmp/master/snmpd.conf | cat -vte

>=20
> display?
>=20


> Also, how are you starting the agent?
> What's the exact command that you invoke?

>=20
> Dave

_________________________________________________________________
Use video conversation to talk face-to-face with Windows Live Messenger.
http://www.windowslive.com/messenger/connect_your_way.html?ocid=3DTXT_TAGLM=
_WL_Refresh_messenger_video_042008=

--_7b762034-c88e-420c-9fe9-2e8a3c7f43e6_


Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class=3D'hmmessage'>

<br>Thanks, Dave.<br><br>I thought about the unprintable characters, too; d=
oes it make sense that I would get similar messages (except that they refer=
ence "memory") when using --rwcommunity=3D"prince" on the command line?<br>=
<br>&gt; What does the command<br>&gt; <br>&gt; sed -n 126p /etc/snmp/ma=
ster/snmpd.conf | cat -vte<br>&gt; <br>&gt; display?<br><br>rwcommunity&nbs=
p; prince$<br><br>[In the snmpd.conf file, that line looks like:&nbsp;&nbsp=
; rwcommunity&nbsp; prince&nbsp;&nbsp; &lt;-- no $.]<br><br><br>&gt; <br>&g=
t; Also, how are you starting the agent?<br>&gt; What's the exact command t=
hat you invoke?<br>&gt;<br><br>Including the debug info, it looks like:<br>=
<br>daemon /usr/sbin/snmpd -DALL -Lf /var/log/snmpdmaster.log $OPTIONS $IPA=
DDR:161<br><br>where:<br><br>OPTIONS=3D"-LS 3 d -Lf /dev/null -p /var/run/s=
nmpdmaster -a -I smux"<br><br>and:<br><br>$IPADDR is the sole IP address ov=
er which I wish to accept SNMP requests.<br><br>Hmmm....&nbsp; You may have=
hit on something here.&nbsp; I'm suspicious of that "-I smux"; I added tha=
t months ago and I can't remember why.&nbsp; I think I was trying to make i=
t forget about all the MIBs it knows about (since I'm servicing them anothe=
r way).<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; - Paul<br><br><br><br><=
br><br><br>&gt; Date: Mon, 14 Apr 2008 15:07:48 +0100<br>&gt; From: D.T.Shi=
e...@liverpool.ac.uk<br>&gt; To: paulc...@hotmail.com<br>&gt; Subject: Re:=
rwcommunity in snmpd.conf ignored by snmpd ("unknown token" in debug outpu=
t)<br>&gt; CC: net-snm...@lists.sourceforge.net<br>&gt; <br>&gt; On 14/=
04/2008, Paul Cerqua &lt;paulc...@hotmail.com&gt; wrote:<br>&gt; &gt; The=
rwcommunity token is accessed twice by the snmpd master process; it<br>&gt=
; &gt; recognizes it the first time, but not the second time ("unknown toke=
n").<br>&gt; &gt; This is true whether or not I prefix rwcommunity with [sn=
mpd]. Also, I<br>&gt; &gt; tried specifying the community via --rwcommunit=
y=3D"prince" and had the same<br>&gt; &gt; results.<br>&gt; <br>&gt; This i=
s a bit of a long-shot, but it's worth checking whether there might<br>&gt;=
be some non-printing characters in the config file, that are confusing<br>=
&gt; the config parsing code.<br>&gt; <br>&gt; What does the command<br>&gt=
; <br>&gt; sed -n 126p /etc/snmp/master/snmpd.conf | cat -vte<br>&gt; <b=
r>&gt; display?<br>&gt; <br>&gt; Also, how are you starting the agent?<br>&=
gt; What's the exact command that you invoke?<br>&gt; <br>&gt; Dave<br><br =
/><hr />Use video conversation to talk face-to-face with Windows Live Messe=
nger. <a href=3D'http://www.windowslive.com/messenger/connect_your_way.html=
?ocid=3DTXT_TAGLM_WL_Refresh_messenger_video_042008' target=3D'_new'>Get st=
arted!</a></body>
</html>=

--_7b762034-c88e-420c-9fe9-2e8a3c7f43e6_--


--===============1288622838==


Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

-------------------------------------------------------------------------


This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

--===============1288622838==


Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________


Net-snmp-users mailing list
Net-snm...@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

--===============1288622838==--

Dave Shield

unread,
Apr 14, 2008, 10:44:58 AM4/14/08
to
On 14/04/2008, Paul Cerqua <paulc...@hotmail.com> wrote:
> I thought about the unprintable characters, too; does it make sense that I
> would get similar messages (except that they reference "memory") when using
> --rwcommunity="prince" on the command line?

No :-(


> > What does the command


> >
> > sed -n 126p /etc/snmp/master/snmpd.conf | cat -vte
> >

> > display?
>
> rwcommunity prince$

That looks right.


> [In the snmpd.conf file, that line looks like: rwcommunity prince <--

> no $.]

Yup - that's the effect of "cat -e" - it marks the end of the line.
(So you can spot trailing whitespace)

> > Also, how are you starting the agent?
> > What's the exact command that you invoke?
> >
>
> Including the debug info, it looks like:
>
> daemon /usr/sbin/snmpd -DALL -Lf /var/log/snmpdmaster.log $OPTIONS

> $IPADDR:161
>
> where:
>
> OPTIONS="-LS 3 d -Lf /dev/null -p /var/run/snmpdmaster -a -I smux"


> Hmmm.... You may have hit on something here. I'm suspicious of that "-I

> smux";

That would probably break things, yes.
The "-I" flag says "initialise the specified modules (and no others)".

So "-I smux" means "initialise SMUX support, but nothing else",
and will therefore turn off *all* the access control settings.

(This probably isn't sensible, and we may need to review how the
"core" agent functionality is handled. But that's how it works)

I added that months ago and I can't remember why. I think I was

> trying to make it forget about all the MIBs it knows about (since I'm
> servicing them another way).

The safest approach would probably be to build a minimal agent
(plus SMUX support) - i.e. turning off the unwanted MIBs at
compile time, rather than run-time.

Dave

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

Paul Cerqua

unread,
Apr 14, 2008, 11:09:00 AM4/14/08
to
--===============0854660547==
Content-Type: multipart/alternative;
boundary="_c01e60e3-ac14-4ffa-8580-c2c5b4258996_"

--_c01e60e3-ac14-4ffa-8580-c2c5b4258996_


Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Thanks, Dave. I added "-I vacm_conf" to my command line and I now get the =
community behavior that I expect! (I removed the reference to smux; we're =
an AgentX shop now :-) )

I'll look into the minimal agent approach as well.

- Paul

> Date: Mon, 14 Apr 2008 15:44:06 +0100


> From: D.T.S...@liverpool.ac.uk
> To: paulc...@hotmail.com
> Subject: Re: rwcommunity in snmpd.conf ignored by snmpd ("unknown token" =
in debug output)
> CC: net-snm...@lists.sourceforge.net
>=20

> On 14/04/2008, Paul Cerqua <paulc...@hotmail.com> wrote:

> > I thought about the unprintable characters, too; does it make sense tha=
t I
> > would get similar messages (except that they reference "memory") when u=
sing
> > --rwcommunity=3D"prince" on the command line?
>=20
> No :-(
>=20
>=20


> > > What does the command
> > >
> > > sed -n 126p /etc/snmp/master/snmpd.conf | cat -vte
> > >
> > > display?
> >
> > rwcommunity prince$

>=20
> That looks right.
>=20
>=20
> > [In the snmpd.conf file, that line looks like: rwcommunity prince =
<--
> > no $.]
>=20


> Yup - that's the effect of "cat -e" - it marks the end of the line.
> (So you can spot trailing whitespace)

>=20
>=20
>=20


> > > Also, how are you starting the agent?
> > > What's the exact command that you invoke?
> > >
> >
> > Including the debug info, it looks like:
> >
> > daemon /usr/sbin/snmpd -DALL -Lf /var/log/snmpdmaster.log $OPTIONS
> > $IPADDR:161
> >
> > where:
> >

> > OPTIONS=3D"-LS 3 d -Lf /dev/null -p /var/run/snmpdmaster -a -I smux"
>=20
>=20
> > Hmmm.... You may have hit on something here. I'm suspicious of that "=
-I
> > smux";
>=20


> That would probably break things, yes.
> The "-I" flag says "initialise the specified modules (and no others)".

>=20


> So "-I smux" means "initialise SMUX support, but nothing else",
> and will therefore turn off *all* the access control settings.

>=20


> (This probably isn't sensible, and we may need to review how the
> "core" agent functionality is handled. But that's how it works)

>=20


> I added that months ago and I can't remember why. I think I was
> > trying to make it forget about all the MIBs it knows about (since I'm
> > servicing them another way).

>=20


> The safest approach would probably be to build a minimal agent
> (plus SMUX support) - i.e. turning off the unwanted MIBs at
> compile time, rather than run-time.

>=20
> Dave
>=20
> -------------------------------------------------------------------------


> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference=20
> Don't miss this year's exciting event. There's still time to save $100.=20
> Use priority code J8TL2D2.=20

> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/ja=


vaone
> _______________________________________________
> Net-snmp-users mailing list
> Net-snm...@lists.sourceforge.net
> Please see the following page to unsubscribe or change other options:
> https://lists.sourceforge.net/lists/listinfo/net-snmp-users

>=20

_________________________________________________________________
Use video conversation to talk face-to-face with Windows Live Messenger.
http://www.windowslive.com/messenger/connect_your_way.html?ocid=3DTXT_TAGLM=
_WL_Refresh_messenger_video_042008=

--_c01e60e3-ac14-4ffa-8580-c2c5b4258996_


Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class=3D'hmmessage'>

<br>Thanks, Dave.&nbsp; I added "-I vacm_conf" to my command line and I now=
get the community behavior that I expect!&nbsp; (I removed the reference t=
o smux; we're an AgentX shop now&nbsp; :-) )<br><br>I'll look into the mini=
mal agent approach as well.<br><br>&nbsp;&nbsp; - Paul<br><br><br><br>&gt; =
Date: Mon, 14 Apr 2008 15:44:06 +0100<br>&gt; From: D.T.S...@liverpool.ac=
.uk<br>&gt; To: paulc...@hotmail.com<br>&gt; Subject: Re: rwcommunity in =
snmpd.conf ignored by snmpd ("unknown token" in debug output)<br>&gt; CC: n=
et-snm...@lists.sourceforge.net<br>&gt; <br>&gt; On 14/04/2008, Paul Ce=
rqua &lt;paulc...@hotmail.com&gt; wrote:<br>&gt; &gt; I thought about the=
unprintable characters, too; does it make sense that I<br>&gt; &gt; would =
get similar messages (except that they reference "memory") when using<br>&g=
t; &gt; --rwcommunity=3D"prince" on the command line?<br>&gt; <br>&gt; No :=
-(<br>&gt; <br>&gt; <br>&gt; &gt; &gt; What does the command<br>&gt; &gt; &=
gt;<br>&gt; &gt; &gt; sed -n 126p /etc/snmp/master/snmpd.conf | cat -vte<br=
>&gt; &gt; &gt;<br>&gt; &gt; &gt; display?<br>&gt; &gt;<br>&gt; &gt; rwcomm=
unity prince$<br>&gt; <br>&gt; That looks right.<br>&gt; <br>&gt; <br>&gt;=
&gt; [In the snmpd.conf file, that line looks like: rwcommunity prince =
&lt;--<br>&gt; &gt; no $.]<br>&gt; <br>&gt; Yup - that's the effect of "c=
at -e" - it marks the end of the line.<br>&gt; (So you can spot trailing wh=
itespace)<br>&gt; <br>&gt; <br>&gt; <br>&gt; &gt; &gt; Also, how are you st=
arting the agent?<br>&gt; &gt; &gt; What's the exact command that you invok=
e?<br>&gt; &gt; &gt;<br>&gt; &gt;<br>&gt; &gt; Including the debug info, it=
looks like:<br>&gt; &gt;<br>&gt; &gt; daemon /usr/sbin/snmpd -DALL -Lf /va=
r/log/snmpdmaster.log $OPTIONS<br>&gt; &gt; $IPADDR:161<br>&gt; &gt;<br>&gt=
; &gt; where:<br>&gt; &gt;<br>&gt; &gt; OPTIONS=3D"-LS 3 d -Lf /dev/null -p=
/var/run/snmpdmaster -a -I smux"<br>&gt; <br>&gt; <br>&gt; &gt; Hmmm.... =
You may have hit on something here. I'm suspicious of that "-I<br>&gt; &gt=
; smux";<br>&gt; <br>&gt; That would probably break things, yes.<br>&gt; Th=
e "-I" flag says "initialise the specified modules (and no others)".<br>&g=
t; <br>&gt; So "-I smux" means "initialise SMUX support, but nothing else"=
,<br>&gt; and will therefore turn off *all* the access control settings.<br=
>&gt; <br>&gt; (This probably isn't sensible, and we may need to review how=
the<br>&gt; "core" agent functionality is handled. But that's how it wor=
ks)<br>&gt; <br>&gt; I added that months ago and I can't remember why. I =
think I was<br>&gt; &gt; trying to make it forget about all the MIBs it kno=
ws about (since I'm<br>&gt; &gt; servicing them another way).<br>&gt; <br>&=
gt; The safest approach would probably be to build a minimal agent<br>&gt; =
(plus SMUX support) - i.e. turning off the unwanted MIBs at<br>&gt; compile=
time, rather than run-time.<br>&gt; <br>&gt; Dave<br>&gt; <br>&gt; -------=
------------------------------------------------------------------<br>&gt; =
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference <br>&gt; =
Don't miss this year's exciting event. There's still time to save $100. <br=
>&gt; Use priority code J8TL2D2. <br>&gt; http://ad.doubleclick.net/clk;198=
757673;13503038;p?http://java.sun.com/javaone<br>&gt; _____________________=
__________________________<br>&gt; Net-snmp-users mailing list<br>&gt; Net-=
snmp-...@lists.sourceforge.net<br>&gt; Please see the following page to u=
nsubscribe or change other options:<br>&gt; https://lists.sourceforge.net/l=
ists/listinfo/net-snmp-users<br>&gt; <br><br /><hr />Use video conversation=
to talk face-to-face with Windows Live Messenger. <a href=3D'http://www.wi=
ndowslive.com/messenger/connect_your_way.html?ocid=3DTXT_TAGLM_WL_Refresh_m=
essenger_video_042008' target=3D'_new'>Get started!</a></body>
</html>=

--_c01e60e3-ac14-4ffa-8580-c2c5b4258996_--


--===============0854660547==


Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

-------------------------------------------------------------------------


This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone

--===============0854660547==


Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________


Net-snmp-users mailing list
Net-snm...@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

--===============0854660547==--

0 new messages