Thursday, November 29, 2012

HTTP Error Codes and their meaning

Following are the HTTP Error Codes. These Error codes are crucial for troubleshooting various issues with Symantec Endpoint Protection.




You can see these error codes in various logs, such as scm-server-0.log, sylink log, in a Secars test.



If you can interpret the correct meaning of the http error code, you can decide the places to look at for resolving this issue.



These status codes indicate a provisional response. The client should be prepared to receive one or more 1xx responses before receiving a regular response.



* 100 - Continue.

* 101 - Switching protocols.



2xx - Success



This class of status codes indicates that the server successfully accepted the client request.



* 200 - OK. The client request has succeeded.

* 201 - Created.

* 202 - Accepted.

* 203 - Non-authoritative information.

* 204 - No content.

* 205 - Reset content.

* 206 - Partial content.

* 207 - Multi-Status (WebDay).



3xx - Redirection



The client browser must take more action to fulfill the request. For example, the browser may have to request a different page on the server or repeat the request by using a proxy server.



* 301 - Moved Permanently

* 302 - Object moved.

* 304 - Not modified.

* 307 - Temporary redirect.



4xx - Client Error



An error occurs, and the client appears to be at fault. For example, the client may request a page that does not exist, or the client may not provide valid authentication information.



* 400 - Bad request.

* 401 - Access denied. IIS defines several different 401 errors that indicate a more specific cause of the error. These specific error codes are displayed in the browser but are not displayed in the IIS log:

o 401.1 - Logon failed.

o 401.2 - Logon failed due to server configuration.

o 401.3 - Unauthorized due to ACL on resource.

o 401.4 - Authorization failed by filter.

o 401.5 - Authorization failed by ISAPI/CGI application.

o 401.7 – Access denied by URL authorization policy on the Web server. This error code is specific to IIS 6.0.



* 403 - Forbidden. IIS defines several different 403 errors that indicate a more specific cause of the error:



o 403.1 - Execute access forbidden.

o 403.2 - Read access forbidden.

o 403.3 - Write access forbidden.

o 403.4 - SSL required.

o 403.5 - SSL 128 required.

o 403.6 - IP address rejected.

o 403.7 - Client certificate required.

o 403.8 - Site access denied.

o 403.9 - Too many users.

o 403.10 - Invalid configuration.

o 403.11 - Password change.

o 403.12 - Mapper denied access.

o 403.13 - Client certificate revoked.

o 403.14 - Directory listing denied.

o 403.15 - Client Access Licenses exceeded.

o 403.16 - Client certificate is untrusted or invalid.

o 403.17 - Client certificate has expired or is not yet valid.

o 403.18 - Cannot execute requested URL in the current application pool. This error code is specific to IIS 6.0.

o 403.19 - Cannot execute CGIs for the client in this application pool. This error code is specific to IIS 6.0.

o 403.20 - Passport logon failed. This error code is specific to IIS 6.0.





* 404 - Not found.



o 404.0 - (None) – File or directory not found.

o 404.1 - Web site not accessible on the requested port.

o 404.2 - Web service extension lockdown policy prevents this request.

o 404.3 - MIME map policy prevents this request.

* 405 - HTTP verb used to access this page is not allowed (method not allowed.)

* 406 - Client browser does not accept the MIME type of the requested page.

* 407 - Proxy authentication required.

* 412 - Precondition failed.

* 413 – Request entity too large.

* 414 - Request-URI too long.

* 415 – Unsupported media type.

* 416 – Requested range not satisfiable.

* 417 – Execution failed.

* 423 – Locked error.



5xx - Server Error



The server cannot complete the request because it encounters an error.



* 500 - Internal server error.



o 500.12 - Application is busy restarting on the Web server.

o 500.13 - Web server is too busy.

o 500.15 - Direct requests for Global.asa are not allowed.

o 500.16 – UNC authorization credentials incorrect. This error code is specific to IIS 6.0.

o 500.18 – URL authorization store cannot be opened. This error code is specific to IIS 6.0.

o 500.19 - Data for this file is configured improperly in the metabase.

o 500.100 - Internal ASP error.



* 501 - Header values specify a configuration that is not implemented.

* 502 - Web server received an invalid response while acting as a gateway or proxy.

o 502.1 - CGI application timeout.

o 502.2 - Error in CGI application.

* 503 - Service unavailable. This error code is specific to IIS 6.0.

* 504 - Gateway timeout.

* 505 - HTTP version not supported.

Monday, November 26, 2012

WebSphere troubleshooting .....



1. Have an end-to-end view in WebSphere troubleshooting, from browser all the way to the backend system.

2. First, test JVM to see if it is working. Make sure that the JVM is up and running and there is no hang thread. Turn on verbose GC and look into system log and native_std.log for JVM related error message.

3. From the browser, to be if the URL is working. If the return code is 500 internal error, this may be a JVM or plugin issue. If the return code is 404 page not found error, it may well be a web server problem.

4. Try to browse into the transport port of the web server and application server directly. If there URL works, then, you can exclude the web server and application server from the troubleshooting scope.

5. Use “telnet server_name port_name” to test network connectivity and server status or test other components of the system, for example MQ server with a port number of 1470.

6. Look into the access log of the web server to see if any request has actually made to the web sever and not got stuck with the 3DNS or BIG IP. Also look into error logs to see if there are any plugin problems and SITEMINDER issues.

7. If there is high CPU, usually it is bad application code.

8. If there is high memory consumption, create heap dump with kill -3 helps. You can ship the dump to IBM for analysis if your work station does not have enough memory to run the Support Assistance suite of tools.

9. Check connection pool – a frequently seen problem is a bug in the JEE code that does not close the connection after using. This causes a connection leak. Use “telnet server_name 446″ to examine the network connectivity between the WebSphere Application Server and the backend systems. This will also tell you if the server is actually up and running. Sometimes, the piling up of connections is due to a connectivity issue. Use TPV, Introscope, or ITCAM to inspect the connection pool as well as examine system log for connection timeout.

10. It helps tremendously if you have transaction monitoring capability. Then, you know exactly where the transaction got stuck or slows down. Introscope provides this capability, though you need in-depth expertise in Introscope that takes time to build.

11. The capability to monitor user experience and transaction is critical in troubleshooting.

Thursday, November 22, 2012

How to find out JBoss Versions

My group is working on a way to perform C&A on JBOSS. The method discussed here did not work as expected with JBOSS EAP 5.1 and JBOSS AS Community 6.0.1. After poking around a bit I found that the $JBOSS_HOME/bin/run.sh script will tell you the version. For C&A purposes it's nice to have a quick method to get answers so we have been using the following find statement:




find $JBOSS_HOME -name run.sh -exec {} -V \;
grep '^JBoss'

JBoss 5.1.1 (build: SVNTag=JBPAPP_5_1_1 date=201105171607)



Unfortunatily, if you are working with SCAP this method is useless since there is no definition that I am aware of that allows for the execution of a shell script. But you can use the Independent Definition 5.10.1 1/27/2012 ind:xmlfilecontent test to extract the JBoss version from the $JBOSS_HOME/jar-versions.xml:





name: applet.jar

specVersion: 5.1.1

1.1.1 Hot deploy copying jar (in standalone mode, not suggested in domain mode)


The easiest way to hot deploy a driver in standalone mode is to copy the jar into the $JBOSS_HOME/standalone/deployments (don’t forget to read the README.located there!). If you are copying a jdbc 4 compliant driver you will get a message like this into console where you have started the standalone server:



12:59:17,663 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) Starting deployment of "mysql-connector-java-5.1.15.jar"

12:59:18,191 INFO [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-3) Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)

12:59:18,291 INFO [org.jboss.as.server.controller] (DeploymentScanner-threads - 2) Deployed "mysql-connector-java-5.1.15.jar"1.1.2 Deploy a driver using jboss-admin.sh command line tool

Standalone: Start the server in standalone mode, open another console, launch the jboss-admin.sh tool. Run these commands:



[standalone@localhost:9999 /] connect

Closed connection to localhost:9999

Connected to standalone controller at localhost:9999

[standalone@localhost:9999 /] deploy /dati/drivers/mysql-connector-java-5.1.15.jar

'mysql-connector-java-5.1.15.jar' deployed successfully.You will get an output to server running console identical to one pasted in section 1.1.1.



Domain: Start the server in domain mode, pen another console, launch the jboss-admin.sh tool. Run these commands:



[standalone@localhost:9999 /] connect

Closed connection to localhost:9999

Connected to domain controller at localhost:9999

[domain@localhost:9999 /] deploy --all-server-groups /dati/drivers/mysql-connector-java-5.1.15.jar

'mysql-connector-java-5.1.15.jar' deployed successfully.You will get this output to server running console:



[Server:server-one] 13:07:51,933 INFO [org.jboss.as.server.deployment] (MSC service thread 1-5) Starting deployment of "mysql-connector-java-5.1.15.jar"

[Server:server-two] 13:07:51,934 INFO [org.jboss.as.server.deployment] (MSC service thread 1-6) Starting deployment of "mysql-connector-java-5.1.15.jar"

[Server:server-two] 13:07:52,344 INFO [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-7) Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)

[Server:server-one] 13:07:52,355 INFO [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-7) Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)

[Server:server-two] 13:07:52,441 INFO [org.jboss.as.server.controller] (pool-1-thread-1) Deployed "mysql-connector-java-5.1.15.jar"

[Server:server-one] 13:07:52,441 INFO [org.jboss.as.server.controller] (pool-1-thread-1) Deployed "mysql-connector-java-5.1.15.jar"