I've got RadiusDesk and FreeRADIUS running on a hosted Ubuntu server, and starting to add a few test NAS devices running CoovaChilli which are redirecting to Dynamic Login Pages as expected and authentication apppears to be working perfectly, etc. etc.
I can see accounting data (graphs) for users on the system, when these users access via on of the NAS devices (via Dynamic Radius Clients). I can see them in the correct Realm. I can even see Activity Monitor logging when they have an active session or not.
However, no usage data appears for the Realm or the NAS on which that user is connected. 0kb in, 0kb out no matter what.
Any idea how this is possible, or what I might need to sort out in my configuration to make it work as expected?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
What I don't understand is the WHERE UserStat.username = 37 part. If left out, this query returns results as expected. But why is it looking for results with a username? Surely that doesn't apply? (I think username 37 is actually the ID of the realm Magnesium in this case, but that doesn't make any sense either.) Help!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Is this a bug? Surely ('activity_viewer') would always evaluate to true no matter what, which is why the query keeps adding the username piece regardless of query type?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Whoo hoo Realms and NAS data now showing up as expected.
I don't know Sourceforge very well though - how do I submit a ticket (is that like an Issue on Github?) or Pull Request (or whatever is the equivalent in SVN)?
Last edit: Stephen Buchanan 2016-07-20
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I've got RadiusDesk and FreeRADIUS running on a hosted Ubuntu server, and starting to add a few test NAS devices running CoovaChilli which are redirecting to Dynamic Login Pages as expected and authentication apppears to be working perfectly, etc. etc.
I can see accounting data (graphs) for users on the system, when these users access via on of the NAS devices (via Dynamic Radius Clients). I can see them in the correct Realm. I can even see Activity Monitor logging when they have an active session or not.
However, no usage data appears for the Realm or the NAS on which that user is connected. 0kb in, 0kb out no matter what.
Any idea how this is possible, or what I might need to sort out in my configuration to make it work as expected?
Some further clarification, after poking around the database and logging SQL queries...
It seems that when RadiusDesk is requesting the accounting data for the Realm, it is doing a query like this:
(The realm name is "Magnesium").
What I don't understand is the
WHERE UserStat.username = 37
part. If left out, this query returns results as expected. But why is it looking for results with a username? Surely that doesn't apply? (I think username 37 is actually the ID of the realm Magnesium in this case, but that doesn't make any sense either.) Help!And now I fixed it.
In Controllers/UserStatsController.php, line 213:
I changed that to:
Is this a bug? Surely
('activity_viewer')
would always evaluate to true no matter what, which is why the query keeps adding the username piece regardless of query type?Whoo hoo Realms and NAS data now showing up as expected.
I don't know Sourceforge very well though - how do I submit a ticket (is that like an Issue on Github?) or Pull Request (or whatever is the equivalent in SVN)?
Last edit: Stephen Buchanan 2016-07-20
Your fix will be checked for compliance and implemented soon!
Writing the issue here (and even providing a fix) is the correct way to do this
Thank you for your time and effort
Steven