The following example configures the session management of a Web container for database session persistence.
Before performing this task you have to create a JDBC provider and create a data source that points to an existing database.
Using Jacl:
set server [$AdminConfig getid /Cell:mycell/Node:mynode/Server:server1/]
Example output:
server1(cells/mycell/nodes/mynode/servers/server1:server.xml#Server_1)
Using Jacl:
set smgr [$AdminConfig list SessionManager $server]
Example output:
(cells/mycell/nodes/mynode/servers/server1:server.xml#SessionManager_1)
Using Jacl:
$AdminConfig modify $smgr {{sessionDatabasePersistence {{datasourceJNDIName jdbc/mySession} {userId myUser} {password myPassword}}}}
This command sets the minimum set of attributes to configure database session persistence. You can optionally modify the db2RowSize and tableSpaceName attributes too.
Using Jacl:
$AdminConfig save