Alan DeKok aland at deployingradius.com
Tue Jan 13 02:02:10 CET 2015

On Jan 12, 2015, at 6:14 PM, Keith Olsen <keith.r.olsen at gmail.com> wrote:
> Just looking for some documentation/assistance with using VMPS with SQL. I have this working with the mac2vlan flat file, but SQL will make for a more eloquent solution.


> 1. I do not see any fields in the schemas that come with Freeradius for the mac address, simple enough to add somewhere, but wanted to make sure I’m not missing anything.

  There aren’t any.  It should be simple.

> 2. I have a very simple requirement, as I only need to map mac to vlan, can I just create/use a DB that only has these 2 columns (mac, vlan)?

  Yes.  Then write a SELECT statement:

	update reply {
		VMPS-VLAN-Name := “%{sql: SELECT clan from mac2vlan where mac = %{VMPS-Cookie}}"

  Something like that should work, presuming you have a simple table with simple names.

> 3. What is the variable that sends back the vlan in the reply?


> from the VMPS virtual server config, I see %{VMPS-Cookie} for the MAC, but nothing for the vlan.

  See the configuration for the mac2vlan module.  It talks about VMPS-VLAN-Name.

>  In the VMPS-VLAN-Name = , I have put the default vlan id, which provides a vlan, where there is not one matched to the mac in the mac2vlan file (I assume this is the way it’s supposed to work).


  Alan DeKok.

More information about the Freeradius-Users mailing list