Configure new mail providers
We can use scripting and wsadmin.sh to configure new mail providers.
Before starting this task, wsadmin.sh must be running. See the topic Starting the wsadmin scripting client article for more information.
To configure a new mail provider:
- Identify the parent ID:
Jacl:
set node [$AdminConfig getid /Cell:mycell/Node:mynode/]
Jython:
node = AdminConfig.getid('/Cell:mycell/Node:mynode/') print node
Example output:
mynode(cells/mycell/nodes/mynode|node.xml#Node_1)
- Get required attributes:
Jacl:
$AdminConfig required MailProvider
Jython:
print AdminConfig. required('MailProvider')
Example output:
Attribute Type name String
- Set up required attributes:
Jacl:
set name [list name MP1] set mpAttrs [list $name]
Jython:
name = ['name', 'MP1'] mpAttrs = [name]
- Create the mail provider:
Jacl:
set newmp [$AdminConfig create MailProvider $node $mpAttrs]
Jython:
newmp = AdminConfig.create('MailProvider', node, mpAttrs) print newmp
Example output:
MP1(cells/mycell/nodes/mynode|resources.xml#MailProvider_1)
- Save the configuration changes. See the topic Saving configuration changes with wsadmin.sh for more information.
- In a network deployment environment only, synchronize the node. See the topic Synchronizing nodes with wsadmin.sh for more information.
Related tasks
Use the wsadmin scripting AdminConfig object for scripted administration Saving configuration changes with wsadmin.sh Synchronize nodes using wsdmin.sh Start the wsadmin scripting client
Commands for the AdminConfig object