Re: Double radius accounting

Lorenzo Milesi <[email protected]> Thu, 14 Nov 2013 11:29:13 +0100 (CET)
Newsgroups gmane.network.poptop
Message-ID <[email protected]>
> I don't remember seeing this symptom, but I speculate that it may be
> caused by two requests for the plugins in options files or command
> line to pppd.  You can do an audit of the options that pppd processes,
> by adding the option "dump".  See man pppd to see the explanation of
> the option.

You're probably right:

Nov 14 11:06:45 hotspotserver-dev pptpd[29274]: CTRL: Client 100.70.2.234 control connection started
Nov 14 11:06:46 hotspotserver-dev pptpd[29274]: CTRL: Starting call (launching pppd, opening GRE)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: Plugin radius.so loaded.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: RADIUS plugin initialized.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: Plugin radattr.so loaded.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: RADATTR plugin initialized.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: Plugin radius.so loaded.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: RADIUS plugin initialized.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: Plugin radattr.so loaded.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: RADATTR plugin initialized.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: Plugin /usr/lib/pptpd/pptpd-logwtmp.so loaded.
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: pppd options in effect:
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: dump#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: plugin radius.so#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: plugin radattr.so#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: plugin radius.so#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: plugin radattr.so#011#011# (from command line)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: plugin /usr/lib/pptpd/pptpd-logwtmp.so#011#011# (from command line)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: require-mschap-v2#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: refuse-pap#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: refuse-chap#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: refuse-mschap#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: name pptpd#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: pptpd-original-ip 100.70.2.234#011#011# (from command line)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: 115200#011#011# (from command line)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: lock#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: crtscts#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: modem#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: asyncmap 0#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: mru 1490#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: mtu 1490#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: lcp-echo-failure 4#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: lcp-echo-interval 30#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: lcp-max-configure 30#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: hide-password#011#011# (from /etc/ppp/options)
Nov 14 11:06:46 hotspotserver-dev pppd[29275]: ipparam 100.70.2.234#011#011# (from command line)


> However, given that the problem is intermittent, this is not a
> satisfying explanation.

I was mistaken, this happen on EVERY established connection.


I tried removing 
plugin radattr.so 
from my "options" file, the accounting is still done, and still with dupes. The radius.so plugin remains loaded twice, but compared to the above log one is from config and one from command line:
Nov 14 11:15:26 hotspotserver-dev pppd[29434]: plugin radius.so#011#011# (from /etc/ppp/options)
Nov 14 11:15:26 hotspotserver-dev pppd[29434]: plugin radius.so#011#011# (from command line)

I don't understand how and from where the command and its parameters are generated.


Thanks for your help.
-- 
Lorenzo Milesi - [email protected]

YetOpen S.r.l. - http://www.yetopen.it/

------------------------------------------------------------------------------
DreamFactory - Open Source REST & JSON Services for HTML5 & Native Apps
OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
Free app hosting. Or install the open source package on any LAMP server.
Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native!
http://pubads.g.doubleclick.net/gampad/clk?id=63469471&iu=/4140/ostg.clktrk