Query the server state using wsadmin.sh

 

Using Jacl

### Identify the server and assign it to the server variable.
set server [$AdminControl completeObjectName cell=cell,node=node,name=server,type=Server,*]

### Query for the state attribute.
$AdminControl getAttribute $server state

 

Using Jython

server = AdminControl.completObjectName('cell=cell,node=node,name=server,type=Server,*')
print server

print AdminControl.getAttribute(server, 'state')