New build path variable
[freeradius.git] / raddb / sql.conf
1 # -*- text -*-
2 ##
3 ## sql.conf -- SQL modules
4 ##
5 ##      $Id$
6
7 ######################################################################
8 #
9 #  Configuration for the SQL module
10 #
11 #  The database schemas and queries are located in subdirectories:
12 #
13 #       sql/DB/schema.sql       Schema
14 #       sql/DB/dialup.conf      Basic dialup (including policy) queries
15 #       sql/DB/counter.conf     counter
16 #       sql/DB/ippool.conf      IP Pools in SQL
17 #       sql/DB/ippool.sql       schema for IP pools.
18 #
19 #  Where "DB" is mysql, mssql, oracle, or postgresql.
20 #
21
22 sql {
23         #
24         #  Set the database to one of:
25         #
26         #       mysql, mssql, oracle, postgresql
27         #
28         database = "mysql"
29
30         #
31         #  Which FreeRADIUS driver to use.
32         #
33         driver = "rlm_sql_${database}"
34
35         # Connection info:
36         server = "localhost"
37         #port = 3306
38         login = "radius"
39         password = "radpass"
40
41         # Database table configuration for everything except Oracle
42         radius_db = "radius"
43         # If you are using Oracle then use this instead
44         # radius_db = "(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SID=your_sid)))"
45
46         # If you want both stop and start records logged to the
47         # same SQL table, leave this as is.  If you want them in
48         # different tables, put the start table in acct_table1
49         # and stop table in acct_table2
50         acct_table1 = "radacct"
51         acct_table2 = "radacct"
52
53         # Allow for storing data after authentication
54         postauth_table = "radpostauth"
55
56         authcheck_table = "radcheck"
57         authreply_table = "radreply"
58
59         groupcheck_table = "radgroupcheck"
60         groupreply_table = "radgroupreply"
61
62         # Table to keep group info
63         usergroup_table = "radusergroup"
64
65         # If set to 'yes' (default) we read the group tables
66         # If set to 'no' the user MUST have Fall-Through = Yes in the radreply table
67         # read_groups = yes
68
69         # Remove stale session if checkrad does not see a double login
70         deletestalesessions = yes
71
72         # Print all SQL statements when in debug mode (-x)
73         sqltrace = no
74         sqltracefile = ${logdir}/sqltrace.sql
75
76         # number of sql connections to make to server
77         num_sql_socks = 5
78
79         # number of seconds to dely retrying on a failed database
80         # connection (per_socket)
81         connect_failure_retry_delay = 60
82
83         # lifetime of an SQL socket.  If you are having network issues
84         # such as TCP sessions expiring, you may need to set the socket
85         # lifetime.  If set to non-zero, any open connections will be
86         # closed "lifetime" seconds after they were first opened.
87         lifetime = 0
88
89         # Maximum number of queries used by an SQL socket.  If you are
90         # having issues with SQL sockets lasting "too long", you can
91         # limit the number of queries performed over one socket.  After
92         # "max_qeuries", the socket will be closed.  Use 0 for "no limit".
93         max_queries = 0
94
95         # Set to 'yes' to read radius clients from the database ('nas' table)
96         # Clients will ONLY be read on server startup.  For performance
97         # and security reasons, finding clients via SQL queries CANNOT
98         # be done "live" while the server is running.
99         # 
100         #readclients = yes
101
102         # Table to keep radius client info
103         nas_table = "nas"
104
105         # Read driver-specific configuration
106         $INCLUDE sql/${database}/dialup.conf
107 }