jQuery in Action, 2nd edition*
The moose likes Websphere and the fly likes Garbage collector help Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Websphere
Bookmark "Garbage collector help " Watch "Garbage collector help " New topic
Author

Garbage collector help

George Peter
Greenhorn

Joined: Oct 31, 2007
Posts: 26
inorder to use the Garbage collector tool from IBM i did the following

# Extract the content of GCCollector.zip in a directory of your chioce.
# Download jfreeChart-1.0.0-rc1.jar and jcommon-1.0.0-rc1.jar and place them in the lib directory that was created when you unzipped GCCollector.zip


when i tried to run GC by

1) double clicking the GCCollector.jar
2) or running the following commad from the java bin directory

javaw -Xmx300m -classpath lib/jfreechart-1.0.0-rc1.jar;lib/jcommon-1.0.0-rc1.jar -jar lib/GCCollector.jar


I get the following error


"Couldnot find the main class .Program will exit"



thanks

Peter
George Peter
Greenhorn

Joined: Oct 31, 2007
Posts: 26
help really appreciated
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18135
    
    8

Is this GCCollector.jar supposed to be an executable jar? Did you have some instructions that told you to type that command?
George Peter
Greenhorn

Joined: Oct 31, 2007
Posts: 26
yes it is an executable jar file

i tried to run this using the following

javaw -Xmx300m -classpath lib/jfreechart-1.0.0-rc1.jar;lib/jcommon-1.0.0-rc1.jar -jar lib/GCCollector.jar


i got the above error
then i tried running GCCollector.bat got the same error

thanks
Peter
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18135
    
    8

I'm very surprised the instructions told you to type that. Because when you use the -jar option, everything in the -classpath option is completely ignored. Usually IBM documentation doesn't make elementary blunders like that.
George Peter
Greenhorn

Joined: Oct 31, 2007
Posts: 26
hi Paul,
I dont understand clearly what you mean.
Anyway here is the instruction mentioned in document comes with ibm GC

"n order to be able to run Diagnostic Tool for Java� Garbage Collector, you must perform the folowing steps:

* Ensure that you have a Java Runtime Environment (1.3 or above) that lets you to execute java programs
* Extract the content of GCCollector.zip in a directory of your chioce.
* Download jfreeChart-1.0.0-rc1.jar and jcommon-1.0.0-rc1.jar and place them in the lib directory that was created when you unzipped GCCollector.zip

Now, you are ready to run Diagnostic Tool for Java� Garbage Collector. The sample batch file GCCollector.bat is located in the directory where you unzipped GCCollector.zip; you can run it, or you can adapt it for your environment. The batch file has only a line with the following command:

javaw -Xmx300m -classpath lib/jfreechart-1.0.0-rc1.jar;lib/jcommon-1.0.0-rc1.jar -jar lib/GCCollector.jar

As you can see, you execute the jar file GCCollector.jar including in the classpath the jar files jfreechart-1.0.0-rc1.jar and jcommon-1.0.0-rc1.jar. "
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18135
    
    8

Here's what I meant when I said the -classpath option was completely ignored: that command you posted there is exactly the same as this command:

javaw -Xmx300m -jar lib/GCCollector.jar

And if the people who produced the product didn't know that, then shame on them for releasing that to the general public. You need to contact them and ask them what you should be doing instead.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Garbage collector help
 
Similar Threads
servlet chart generate problem
Problems setting up JFreeChart in NetBeans
opening a pdf file created by jasper in client side
drawing chart through servlets
Graphs in JSP