|
From: Leif M. <le...@ta...> - 2004-06-07 04:23:53
|
Sunil,
Please post questions to the wrapper-user mailing list rather than
sending them to me
directly. It makes them searchable for others having the same problem
in the future
and also makes it possible for others to answer the questions.
See below.
Annam, Sunil wrote:
>Leif,
>
>Thanks for the reply.
>I was running on UNIX. But I don't have library for 64 bit HPUX.
>Therefore, to understand concept of Wrapper, I am trying to test another
>server application that is running on SuSe linux.
>
>When the pServer starts, it does the following
>mgHome = System.getProperty("MG_HOME", "..") + "/";
>System.out.println("MG_HOME: " + mgHome);
>
>
That message should be showing up in the wrapper.log file regardless of
whether
or not the MG_HOME system property is being set correctly.
Could you set the wrapper.debug=true property and then post the generated
wrapper.log file for a single run. This will give me a lot more
information about
exactly what is going on.
>I am not seeing MG_HOME string in console output and wrapper.log.
>So I was wondering where the output goes. My applicatiosn creates a log
>file in $MG_HOME\logs but it is not there if I run it through wrapper.
>In wrapper.conf, I have "set.MG_HOME=/home/linux/pServer".
>
>
I am not clear exactly how you are specifying the location of the log
file in your
JVM. You can not reference a variable within the JVM using $JVM_HOME.
You will have to do something like:
System.out.println( "Path: " + System.getProperty( "MG_HOME" ) + "/logs" );
In order to make that system property available, you will have to pass
it to the JVM.
Environment variables are not visible from the JVM on their own:
set.MG_HOME=/home/linux/pServer
wrapper.java.additional.1=-DMG_HOME=%MG_HOME%
The first will set the environment variable and the second will define
the system
property when the JVM is launched.
>As I said before, after I start my application through wrapper, I go to
>other terminal window and see 'pServer status'. It tells me "pServer
>service is running (27780)".
>
>
How are you launching the Wrapper? If you are using the sh script that
comes
with the Wrapper, could you try running it with the 'console' command rather
than 'start'? This will run the Wrapper in the current console and make
it easier
to see the output that is being sent to the Wrapper process.
It will also make it clear that the JVM is indeed still running.
>In addition to that, when clients try to make connection with server,
>they could not find the server.
>
>
This makes me wonder if the JVM is actually running. What do you see if
you run
'ps -fax' You should see a tree of the processes running on your
system. Look for
the Wrapper and its JVM.
The script that ships with the Wrapper can also be used to check the
status of
the Wrapper process by running it with the 'status' command.
Cheers,
Leif
>-----Original Message-----
>From: Leif Mortenson [mailto:le...@ta...]
>Sent: Saturday, May 29, 2004 3:15 AM
>To: Annam, Sunil
>Subject: Re: where ot find output of System.out.println
>
>Sunil,
> You are running on UNIX correct? The shell script takes one of a
>number of
>commands. If you launch it using the 'console' command then the
>Wrapper will be
>launched in the current shell and you will be able to see all of your
>println messages
>in the console just as if you had run Java manually. Another copy of
>the console
>output will show up in the wrapper.log file. You will have to look at
>your
>wrapper.conf to see where you have configured its location.
>
> When you run with the 'start' command however, the Wrapper is run as
>
>a detached
>daemon process and you will get the shell prompt back right after the
>Wrapper is
>launched. In this case, the console output is suppressed as it does
>not have a place
>to go. All of the output is still available in the wrapper.log file
>just as above however.
>
> The logging done by your application should not have been affected
>by the
>Wrapper. How are you doing the logging? When running with the Wrapper
>the
>user directory of the JVM process is set to the location of the shell
>script by default.
>Is it possible that it is not in the location you are expecting?
>
>Cheers,
>Leif
>
>Annam, Sunil wrote:
>
>
>
>>I was able to configure wrapper.conf and other files. Now when I do
>>"pServer status" it says that "pServer service is running (27780)".
>>
>>When run independently, pServer logs activity in a log file and prints
>>some statements using System.out.println on console. Running pServer
>>thru wrapper does not create log file and no messages on console.
>>
>>Where should I look for System.out.println messages?
>>
>>Thanks,
>>
>>Sunil
>>
>>
>>
>
>
>
|