You can test connections for data sources with the wsadmin tool and scripting. Before starting this task, the wsadmin tool must be running. See the Starting the wsadmin scripting client article for more information.
Perform the following steps to test a data source to ensure a connection to the database.
set ds [$AdminConfig getid /DataSource:DS1/] $AdminControl testConnection $ds
ds = AdminConfig.getid('/DataSource:DS1/') AdminControl.testConnection(ds)
Example output:
WASX7217I: Connection to provided datasource was successful.
Example output:
WASX7217I: Connection to provided data source was successful.