Use WebSphere’s Administrative Console to define a data source with an existing JDBC Provider.
Before you can finish configuring the data source, you must configure authentication data. These aliases contain credentials that are used to connect to the DBMS.
Click Security > Secure administration, applications, and infrastructure.
Under Authentication, click Java Authentiation and Authorization Service configuration > J2C authentication data. The JAAS - J2C authentication data panel is displayed.
Enter a unique alias, a valid user ID, a valid password, and a short description (optional). The user ID must be valid on the target database.
Click OK or Apply. No validation for the user ID and password is required.
The newly created entry is visible without restarting the application server process to use in the data source definition. But the entry is only in effect after the server is restarted.
Click Resources > JDBC Providers > Your_JDBC_Provider_Name > Data Sources tab in the left pane to display the Data sources page. The right pane displays a table of data sources configured for use with this JDBC provider. Click the New button above the table of data sources.
Use the wizard provided to configure the general properties for the new data source. Note the following on the Enter basic data source information page:
The JNDI Name is the path to the DataSource object in the directory service. You must specify this same value as the -f argument in setRepo -tdbms -iinitCtxFac -ffilepath.
Select the Component-managed Authentication Alias that you created in Configuring a JDBC Provider. These are the credentials that will be used to access the DBMS (to which this DataSource points).
Click Next when you have configured this panel. The Create New JDBC provider page is displayed.
Configure the database-specific properties for this data source as needed. Refer to the online help for information about the available properties.
Make sure Use this data source in container-managed persistence (CMP) is unchecked. Identity Manager does not use Enterprise Java Beans (EJBs). Click Next to go to the summary page.
Click Finish to save your data source.
When configuring the data source in clustered WebSphere environments, configure it at the cell level. This allows the data source to be accessed from all nodes in the cell.
To configure this use the -D $propertiesFilePath option where $propertiesFilePath contains:
Examine the WebSphere configuration to determine the JNDI port to specify.
In the WebSphere administration console, navigate to Servers > Application Servers > Your_Server > Ports.
Look at the BOOTSTRAP_ADDRESS property. Use the specified port in the java.naming.provider.url property.
The java.naming.provider.url uses localhost as the hostname. WebSphere replicates a JNDI server on each node in the cluster so that each application server has its own JNDI server to query. Specify localhost for the host so that each application server in the cluster is used as the JNDI server that Identity Manager queries when the DataSource is being located.