<div dir="ltr"> sqlcounter counter_octets_daily {<br> sql_module_instance = "sql"<br> key = "User-Name"<br> query = "SELECT IFNULL((SUM(AcctInputOctets + AcctOutputOctets)),0) FROM radacct WHERE UserName='%{%k}' AND UNIX_TIMESTAMP(AcctStartTime) + AcctSessionTime > '%b'"<br>
reset = "daily"<br> counter_name = "ChilliSpot-Max-Total-Octets-Daily"<br> check_name = "CS-Total-Octets-Daily"<br> reply_name = "ChilliSpot-Max-Total-Octets"<br>
}<br>/etc/raddb/mods-enabled/sql_counter[1]: Configuration item 'reply_name' cannot be a VSA<br>/etc/raddb/mods-enabled/sql_counter[1]: Instantiation failed for module "counter_octets_daily"<br><br></div>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Sun, Dec 1, 2013 at 2:24 AM, Arran Cudbard-Bell <span dir="ltr"><<a href="mailto:a.cudbardb@freeradius.org" target="_blank">a.cudbardb@freeradius.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im"><br>
On 1 Dec 2013, at 03:24, Jed Gainer <<a href="mailto:jedgainer@gmail.com">jedgainer@gmail.com</a>> wrote:<br>
<br>
> I did a system upgrade and my silly disto upgraded FreeRADIUS to 3.0.0 so I am reconfiguring it from scratch because of the changes. I have managed to get SQL up and running but am having troubles getting my sqlcounters to work.<br>
><br>
> After putting the following in /etc/raddb/mods-config/sql/counter/mysql/queries.conf<br>
><br>
> sqlcounter counter_octets_daily {<br>
> sql_module_instance = sql<br>
><br>
> counter_name = ChilliSpot-Max-Total-Octets-Daily<br>
> check_name = CS-Total-Octets-Daily<br>
> reply-name = ChilliSpot-Max-Total-Octets<br>
><br>
> key = User-Name<br>
> reset = daily<br>
> query = "SELECT IFNULL((SUM(AcctInputOctets + AcctOutputOctets)),0) FROM radacct WHERE UserName='%{%k}' AND UNIX_TIMESTAMP(AcctStartTime) + AcctSessionTime > '%b'"<br>
> }<br>
<br>
</div>The examples are wrong, they got accidentally moved into that folder during the reorganisation, most likely because of the incorrect header lines.<br>
<div class="im"><br>
> I put "counter_octets_daily" in the authorize{} block after "sql" in /etc/raddb/sites-available/default<br>
><br>
> but when I try and boot radiusd I get:<br>
<br>
</div>Make a file in /etc/raddb/mods-available/sql_counter move that section in there, link it to /etc/raddb/mods-enabled/sql_counter.<br>
<br>
-Arran<br>
<br>
Arran Cudbard-Bell <<a href="mailto:a.cudbardb@freeradius.org">a.cudbardb@freeradius.org</a>><br>
FreeRADIUS Development Team<br>
<br>
-<br>
List info/subscribe/unsubscribe? See <a href="http://www.freeradius.org/list/users.html" target="_blank">http://www.freeradius.org/list/users.html</a><br>
</blockquote></div><br></div>