BEA Logo BEA WebLogic Server Release 6.1

  BEA Home  |  Events  |  Solutions  |  Partners  |  Products  |  Services  |  Download  |  Developer Center  |  WebSUPPORT

 

  |  

  WebLogic Server Doc Home   |     FAQ   |   Previous Topic   |   Next Topic   |   Contents   |   View as PDF

FAQs: Server-Related Questions

 


What should I do if my server "hangs" or "freezes"?

If your WebLogic Server "freezes," you will need to collect certain diagnostic information, including thread dumps and Java garbage collection metrics, before contacting BEA Technical Support. For details, see Collecting Diagnostic Information.


How do I configure WebLogic to use a SOCKS proxy?

You can configure a java.net socket to use SOCKS by setting a Java system property. For details, see How do I make Java work with a proxy server?. Once the property is set, WebLogic socket connections use the SOCKS proxy.


How can I speed up connection responses?

Connection delays are often caused by DNS problems. WebLogic performs a reverse lookup on the hostname from which a new connection is made. If the DNS reverse lookup is not working properly because the connection is coming from a proxy server, it could be responsible for the delay. You might want to work with your system administrator to determine whether DNS and the third-party networking software are working properly. Try writing a simple server program that performs a reverse lookup on any connection made to it. If that lookup is delayed, then you know that the proxy server is the source of the problem.


How does WebLogic support CORBA and client communication via IIOP?

"CORBA" support means many things to many people. It often means simply IIOP /ORB support and not much on CORBA services. WebLogic supports CORBA in multiple ways.

First, Java clients can tunnel through a CORBA environment to WebLogic Server. We call this "IIOP tunneling," and it is intended for use with applets coming through an IIOP firewall, such as the IONA Wonderwall product. This is a Java-to-Java model riding over an IIOP communications framework.

WebLogic RMI over IIOP provides RMI services for many clients (including CORBA clients) over IIOP. For more information, see Using WebLogic RMI over IIOP.

WebLogic Enterprise Connectivity enables you to create IIOP connection pools to a BEA WebLogic Enterprise System, allowing you to execute WebLogic Enterprise CORBA objects from WebLogic Server servlets and Enterprise JavaBeans.


How do I speed up HTTP tunneling?

Unfortunately, a significant performance hit occurs when you use HTTP tunneling. We have optimized it somewhat, but, because everything is encapsulated in HTTP, HTTP tunneling is slower than direct Java-to-Java TCP/IP connections.

Be sure that you really need to use HTTP tunneling. For example, if your firewall can pass IP packets through port 80, you can use the fast T3 protocol on port 80.

If you must use HTTP tunneling to go through a firewall, BEA recommends using a third-party product such as e-Border.


Can WebLogic Server start with a UNIX boot?

You can add a startup script to your UNIX rc scripts to run WebLogic Server at UNIX boot time. Here is an example from an HP-UX 11 system, running under JDK 1.1. You need to supply the URL for your WebLogic Server and your system password. This file, wlstart, is placed in the /sbin/init.d directory and there is a link to it in the /sbin/rc2.d directory:

export SHLIB_PATH=\
/home/user1/weblogic/lib/hpux11:/oracle/8.0.4/lib
export CLASSPATH=/home/user1/weblogic/classes:\
/home/user1/weblogic/lib/weblogicaux.jar
export ORACLE_HOME=/oracle/8.0.4
export ORACLE_SID=DEMO
export ORACLE_TERM=vt100
export QAT=/home/user1/weblogic
cd $QAT
PATH=/sbin:/usr/sbin:/usr/bin:/opt/java/bin
export PATH
case $1 in
'start')
    java -ms64m -mx64m -verbosegc weblogic.Server > \
       /home/user1/weblogic/server.out 2>&1
    ;;
'stop')
    java weblogic.Admin URL shutdown system password
    ;;
*)
    echo "usage: $0 {start|stop}"
    ;;
esac

You should work with your UNIX system administrator to set up scripts similar to this for your system.


What affects servlet performance besides clients and traffic?

Response time for a servlet is about 5 times slower when you are running a screen saver on the machine, particularly for the OpenGL screen savers. Try turning off your screen saver and see if that helps!


Why do I get "NoClassDefFound"/"Too Many Open files"messages on Solaris?

Problem: When I am using WebLogic Server on Solaris and try to run my application, I get a "NoClassDefFound" error, although the class causing the error does exist and is in the right directory. In fact, there are other classes in the same directory that are getting loaded. I also get a "Too many open files" error.

We have seen this situation when the user account runs out of file descriptors. On Solaris, each user account has a certain limited number of file descriptors. You can find out how many file descriptors you have with the limit command in csh.

You can increase file descriptors if you have enough privileges with the ulimit command in the csh. Otherwise, ask your system administrator to increase the file descriptors available to your processes.


How do I increase WebLogic Server memory?

Increase the allocation of Java heap memory for WebLogic Server. (Set the minimum and the maximum to the same size.) Start WebLogic Server with the -ms32m option to increase the allocation, as in this example:

  $ java ... -ms32m -mx32m ... 

This allocates 32 megabytes of Java heap memory to WebLogic Server, which improves performance and allows WebLogic Server to handle more simultaneous connections. You can increase this value if necessary.


What causes Java.io exceptions in the log file?

You may see messages like these in the log file:

(Windows NT)

 java.io.IOException Connection Reset by Peer
 java.io.EOFException Connection Reset by Peer

(Solaris)

java.io.Exception: Broken pipe

These messages occur when you are using servlets. A client initiates an HTTP request, and then performs a series of actions on the browser:

  1. Click Stop or enter equivalent command or keystrokes

  2. Click Refresh or enter equivalent command or keystrokes

  3. Send a new HTTP request.

The messages indicate that WebLogic Server has detected and recovered from an interrupted HTTP request.


Java-CORBA integration: RMI-IIOP or Java IDL?

It is important to understand the distinction between these two ways of integrating Java with CORBA.

RMI-IIOP is for Java programmers who want to program to the RMI interfaces but use IIOP as the underlying transport. RMI-IIOP provides interoperability with other CORBA objects implemented in various languages, but only if all the remote interfaces are originally defined as Java RMI interfaces. It is of particular interest to programmers using Enterprise JavaBeans (EJBs), because the remote object model for EJB is RMI-based.

Java IDL is for CORBA programmers who want to program in Java based on interfaces defined in CORBA IDL. This is "business as usual" CORBA programming, supporting Java in exactly the same way as other languages like C++ or COBOL.


How do an RMI-IIOP application and an existing CORBA object interoperate?

If the existing CORBA object has its remote interfaces defined originally in CORBA IDL, then interoperability is not possible. RMI-IIOP applications can interoperate with other CORBA objects only when their remote interfaces are originally defined as Java RMI interfaces.

For example, to interoperate between an RMI-IIOP client and a C++ object you need to:

  1. Define the remote interface of the object in Java as an RMI interface.

  2. Run rmic -iiop against the interface to produce the stub for your RMI-IIOP client.

  3. Run rmic -idl against the interface to produce IDL compatible with the RMI interface.

  4. Run a C++ stub compiler against the IDL file to produce the C++ skeleton for your C++ server object.


What is the function of T3 in WebLogic Server?

T3 provides a framework for WebLogic Server messages that support for enhancements. These enhancements include abbreviations and features, such as object replacement, that work in the context of WebLogic Server clusters and HTTP and other product tunneling.

T3 predates Java Object Serialization and RMI, while closely tracking and leveraging these specifications. T3 is a superset of Java Object. Serialization or RMI; anything you can do in Java Object Serialization and RMI can be done over T3.

T3 is mandated between WebLogic Servers and between programmatic clients and a WebLogic Server cluster. HTTP and IIOP are optional protocols that can be used to communicate between other processes and WebLogic Server. It depends on what you want to do. For example, when you want to communicate between


How can I debug the Java code that I have running in WebLogic Server?

You can use tools such as WebGain, JBuilder, NetBeans and JDB that rely on the Java Platform Debugger Architecture (JPDA) to debug your Java code running in WebLogic Server.

JPDA is integrated in the Java 2 Platform, Standard Edition (J2SE) SDK 1.3 on all platforms and SDK 1.2.2 for Linux. There is a download available from Sun to add JPDA support to the J2SE SDK 1.2.2 on Solaris and Microsoft Window platforms. If you are using J2SE SDK 1.2.2 on these platforms you must first get this download.

To allow a debugger to attach to the virtual machine that WebLogic runs you have to start WebLogic in debug mode. In order to start WebLogic in debug mode using a Sun virtual machine follow these steps (start with step one only if using a Solaris platform):

  1. If using a Solaris platform, change the LD_LIBRARY_PATH environment variable to prepend $JAVA_HOME/lib/sparc:
    export LD_LIBRARY_PATH=$JAVA_HOME/lib/sparc:$LD_LIBRARY_PATH
    

  2. Add the following parameters to the java command line (before the "weblogic.Server" string) that launches WebLogic server:
    -Xdebug
    -Xnoagent
    -Xrunjdwp:transport=dt_socket
    server=y
    address=<port_for_debugger_to_connect>
    suspend=n
    -Djava.compiler=NONE
    

Note that with the Hotspot Performance engine the -Xnoagent and -Djava.compiler=NONE options are no longer required, but are accepted and ignored for compatibility reasons.

If server=y and no address parameter is supplied, WebLogic Server chooses the transport address and prints it to the standard output stream. So, if a line such as:

Listening for transport dt_socket at address: 46666

prints in your standard output stream when the server starts, the number 46666 is the port number to be supplied to your tool's remote debugger in order to attach it to WebLogic's virutal machine.

 

back to top previous page next page