Tuesday, January 10, 2017

How To Create WebLogic Domain 12.2.1.1 Using WLST?

1) Create the python script wls_prod_domain.py with below content

----------------------------------------------------------------------------------------------------------
# Select the template to use for creating the domain

selectTemplate('Basic WebLogic Server Domain','12.2.1.1')
loadTemplates()

# Set the listen address and listen port for the Administration Server

cd('/Servers/AdminServer')
set('ListenAddress','192.168.142.128')
set('ListenPort',7001)

#Enable SSL on the Administration Server and set the SSL listen address and Port

create('AdminServer','SSL')
cd('SSL/AdminServer')
set('Enabled','false')
set('ListenPort', 7002)

# Set the domain password for the WebLogic Server administration user

cd('/')
cd('Security/base_domain/User/weblogic')
cmo.setPassword('welcome1')

# If the domain already exists, overwrite the domain

setOption('OverwriteDomain','true')

# write the domain and close the template

writeDomain('/oracle/Middleware/user_projects/domains/prod_domain')
closeTemplate()
exit()

---------------------------------------------------------------------------------------------------------------


2) Execute below WLST command for creating prod_domain.

         java weblogic.WLST wls_prod_domain.py


3) Start the weblogic server using below command 

          cd /oracle/Middleware/user_projects/domains/prod_domain/bin
          nohup ./startWebLogic.sh &


    d) Access The weblogic console using below URL



1 comment: