Configure a single built-in, file-based repository in a new configuration under federated repositories using wsadmin
Use the Jython or Jacl scripting language with the wsadmin tool to configure a single built-in, file-based repository in a new configuration under Federated repositories.
Shut down the application server and ensure we have the primary administrator id and password.
The federated repositories configuration file, wimconfig.xml, is supported by WebSphere Application Server 6.1.x and is located in the app_server_root/profiles/profile/config/cells/cell/wim/config directory.
Use the following steps to configure for use a single built-in, file-based repository in a new configuration for federated repositories.
Tasks
- Start the wsadmin scripting tool.
- Create the fileRegistry.xml file, which is the user registry itself, if it does not already exist. If the fileRegistry.xml file does exist, this step just adds the user to registry.
Use Jython:
AdminTask.addFileRegistryAccount('-userId isoet01s01 -password oets01')Use Jacl:
$AdminTask addFileRegistryAccount {-userId isoet01s01 -password oets01}For more information on the addFileRegistryAccount command, see the documentation about the FileRegistryCommands command group for the AdminTask object.
- Update the security.xml file to enable administrative security, set the activeUserRegistry to use federated repositories, and update the primaryAdmin and its password.
Use Jython:
AdminTask applyWizardSettings('-secureApps false -secureLocalResources false -userRegistryType WIMUserRegistry -customRegistryClass com.ibm.ws.wim.registry.WIMUserRegistry -adminName isoet01s01 -adminPassword oets01')Use Jacl:
$AdminTask applyWizardSettings {-secureApps false -secureLocalResources false -userRegistryType WIMUserRegistry -customRegistryClass com.ibm.ws.wim.registry.WIMUserRegistry -adminName isoet01s01 -adminPassword oets01}For more information on the applyWizardSettings command, see the documentation about the WizardCommands .
- Save the configuration changes. Enter the following commands to save the new configuration and close the wsadmin tool:
Use Jython:
AdminConfig.save()Use Jacl:
$AdminConfig save- Restart the application server.
Subtopics
- FileRegistryCommands
Federated repositories provides a file registry. Use the commands in the FileRegistryCommands command group to administer the file registry using the wsadmin tool.
Related information:
WizardCommands