Support Support Downloads Knowledge Base Juniper Support Portal Community

Knowledge Base

Search our Knowledge Base sites to find answers to your questions.

Ask All Knowledge Base Sites All Knowledge Base Sites JunosE Defect (KA)Knowledge BaseSecurity AdvisoriesTechnical BulletinsTechnotes Sign in to display secure content and recently viewed articles

How to configure Steel-Belted Radius to use Microsoft JDBC 2.0 driver under Solaris and Linux

0

0

Article ID: KB15530 KB Last Updated: 03 Mar 2017Version: 3.0
Summary:

This document shows how to configure Steel-Belted Radius (SBR) to use the Microsoft SQL JDBC 2.0 driver. This driver supports SQL Server 2000 and adds native support for SQL Server 2005 and SQL Server 2008.

Symptoms:

A Microsoft SQL Server is needed for authentication and/or accounting, and SBR is running on a Solaris or Linux platform where no native ODBC drivers are available.

Cause:

SBR is running on a Solaris or Linux platform where no native ODBC drivers are available.

Solution:

Install a JDBC driver provided by Microsoft for this situation, then configure the SBR.

Download and Install the Driver

Note: You must download the driver from Microsoft. Be sure to download the Unix version of the driver (a tar.gz file).

1. Download the driver from here: http://msdn.microsoft.com/en-us/data/aa937724.aspx

For this example, the file used is sqljdbc_2.0.1803.100_enu.tar.gz.

2. Copy the file to your server.

3. Use the gunzip and tar utilities to extract the libraries.

For example, copy the file to the /tmp directory and then issue the commands below to extract the files:

gunzip sqljdbc_2.0.1803.100_enu.tar.gz

tar xvf sqljdbc_2.0.1803.100_enu.tar

These commands create a directory structure under the /tmp/sqljdbc_2.0 directory.

4. Navigate to the /tmp/sqljdbc_2.0/enu/ directory.

5. Copy the two .jar files (sqljdbc.jar and sqljdbc4.jar) to /opt/JNRPsbr/radius/jre/lib/ext.

6. Set the file permissions so that root has read/write/execute access to the files.


Configure the SBR

1. Configure the Driver line and the Connect line in either the radsqljdbc.aut file or the radsqljdbc.acc file.

These lines are located under the [Settings] section.

Configure the Driver line as follows:

Driver=com/microsoft/sqlserver/jdbc/SQLServerDriver

Configure the Connect line so that it is similar to the one below. (You must modify the IP address of your SQL server and the username and password used to connect to the server.)

Connect=DSN=jdbc:sqlserver://172.28.80.104:1433;UID=sbr;PWD=sbr;

Note that the format of this URL is different from that used by earlier Microsoft SQL JDBC drivers: The MICROSOFT parameter is now omitted.

Also note that configuration options in other parts of the radsqljdbc.aut file or the radsqljdbc.acc file are not covered here. For details on other configuration options in these files, see the SBR Administrators Guide and the SBR Reference Guide. These guides are available at this location: Steel-Belted Radius Documentation.

2. Verify that Enable=1 is set in the BOOTSTRAP section.

3. Save the file and restart the SBR daemon.

4. Check the SBR debug log to ensure that the connection is established.

If the connection is established, the log will contain this message: Connected to database.

Note that this procedure assumes that all other parameters in the AUT or ACC file are correctly configured.

For comparison, a sample radsqljdbc.aut file is shown below.

[Bootstrap]
Enable=1
LibraryName=radsql_auth_jdbc.so
InitializationString=SQL-JDBC

[Settings]
Driver=com/microsoft/sqlserver/jdbc/SQLServerDriver
Connect=DSN=jdbc:sqlserver://172.28.80.104:1433;UID=sbr;PWD=sbr;
SQL=SELECT userpassword FROM users WHERE username = %name/40
ParameterMarker=?
ConcurrentTimeout=30
ConnectTimeout=25
QueryTimeout=25
WaitReconnect=2
MaxWaitReconnect=360
PasswordFormat = 0
DefaultResults = 0
;ShutdownTimeout = 1
;ErrorMap=<mssql.ini|mysql.ini|oracle.ini>
LogLevel=2

;[Server]
;s1=2
;s2=2

;[Server/s1]
;Connect=DSN=<dsn_name_here>;UID=<username_for_dB>;PWD=<password_for_dB>

;[Server/s2]
;Connect=DSN=<dsn_name_here>;UID=<username_for_dB>;PWD=<password_for_dB>

[Results]
Password=1/48
;Profile=2/48
;Alias=2/48

[Failure]
;Accept=0
;Profile=xyz
;FullName=Remote User

Note

Comment on this article > Affected Products Browse the Knowledge Base for more articles related to these product categories. Select a category to begin.

Getting Up and Running with Junos

Getting Up and Running with Junos Security Alerts and Vulnerabilities Product Alerts and Software Release Notices Problem Report (PR) Search Tool EOL Notices and Bulletins JTAC User Guide Customer Care User Guide Pathfinder SRX High Availability Configurator SRX VPN Configurator Training Courses and Videos End User Licence Agreement Global Search