Thursday 12 November 2009

Webservers on unmanaged nodes

My current client is running IHS but managing them from within WAS as running on an unmanaged node (all this is on AIX)

A lot of the Infocenter documentation is based around running on managed nodes so the troubleshooting has been fun. There was never anything major, just fiddly.

We run IHS as non root, so when we first added the webserver to WAS we were unable to start it as we had the port set to 80. A non root user cannot use a port less than 1024 . The first thought was to change the port to port 8080 (see the issues in the vhost matching port below about the issues we had with this and our load balancer). Of course the easier way was to update the user and group settings within the httpd.conf.

When trying to propagate the plugin we got errors about file permissions on the admin console and also on the dmgr log. This took a while to track down - the WAS user had full access to update the plugin file on the unmanaged node so I just couldn't work this out. Eventually when checking the set up between enviornments, I clicked on "webservers ==> my server ==> Configuration file" which should open up the httpd.conf. This failed to show up due to a permissions problem.

So I gave the WAS user access to httpd.conf on the remote box and as well as allowing me to view the httpd.conf I could also propagte the plugin. Why the was users needs to check the httpd.conf before sedning out the file I don't know as the location of the plugin file, although mentioned in httpd.conf is also part of the WAS config.

The next issue I had was startting and stopping the webservers. When I clicked start, it took a minute before we got an error saying failed to start. Further investigation showed the server had started and the error was due to WAS not being able to get the server status. Just through various bits of testing we were doing, we found out this was due to a firewall issue. It seems that as there is no serverStatus script that can be run, that WAS does some sort of telnet or other network check on the port that IHS is listening on (in this case 8080). Oncer we opened up port 8080 on the firewall the start request worked correctly and the status showed up as well.

One of the drawbacks of running no an unmanaged node is that there is no stopServer or startServer script that can be run which would be the case on an unmanaged node. The only way to script from the dmgr box is to run a jython script like the following:

Stop

AdminControl.invoke('WebSphere:name=WebServer,process=dmgr,platform=common,node=myMgr,version=6.1.0.21,type=WebServer,mbeanIdentifier=WebServer,cell=myCell,spec=1.0', 'stop', '[myCell mynode mywebserver]', '[java.lang.String java.lang.String java.lang.String]')

Start

AdminControl.invoke('WebSphere:name=WebServer,process=dmgr,platform=common,node=myMgr,version=6.1.0.21,type=WebServer,mbeanIdentifier=WebServer,cell=myCell,spec=1.0', 'start', '[myCell mynode mywebserver]', '[java.lang.String java.lang.String java.lang.String]')

Anyway, off now to change some performce settings - thread pools and oracle connection pools! The fun never stops

No comments:

Post a Comment