wood burning stoves 2.0*
The moose likes Linux / UNIX and the fly likes Problem with Linux Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "Problem with Linux" Watch "Problem with Linux" New topic
Author

Problem with Linux

Padma Prasad
Ranch Hand

Joined: Sep 16, 2002
Posts: 76
Hi,

I have tomcat and DB installed in a linux machine. I am deploying a war file. When I run the application in the browser, I can enter the user name and password. but after that I get an error page with a line "An Error has occurred in this application. Please check your log files for further information. "

When I check catalina.out, I found an error that said

"ERROR - StandardManager.doLoad(434) | IOException while loading persisted sessions: java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: com.sfo.web.SelectOptionBean
java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: com.sfo.web.SelectOptionBean "

When I run tomcat in windows, I still get this error but I get the next page in the browser.... that is the application is running.

What could be the error here? why is linux not forcing the application to run?

Thanks,
Angel
Dave Salter
Ranch Hand

Joined: Jul 20, 2005
Posts: 293

It looks like Linux is not so tolerant. Does it all work if you make com.sfo.web.SelectOptionBean Serializable?

Cheers,

Dave.
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16250
    
  21

It's never been a good idea to store non-serializable objects in a Session, even though Sun's never actually has come out and officially discouraged it in the JavaDocs.

Tomcat4 had no significant issues, but Tomcat5 is much less tolerant, since part of its clustering ability is predicated on being able to bounce sessions from one VM to another.


Customer surveys are for companies who didn't pay proper attention to begin with.
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
Originally posted by Tim Holloway:
Tomcat4 had no significant issues, but Tomcat5 is much less tolerant, since part of its clustering ability is predicated on being able to bounce sessions from one VM to another.

...and that holds for not just Tomcat 5 but any other J2EE application server or web container that supports session replication.


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Padma Prasad
Ranch Hand

Joined: Sep 16, 2002
Posts: 76
Thanks for your responses.

I implemented serializable interface and I don't get that error any more.
But I have a different issue. When I run the application on tomcat server installed on linux, I get the login page and I login with correct username/pwd. But I don't get the next page. Instead I see a page which says "An Error has occurred in this application. Please check your log files for further information.". But when I check catalina.out, there is no error in it. Why am I getting this error? is Linux stopping the application by any chance?

I get this at the url which ends with j_security_check. Don't know if this is a stupid question, but what's about this?

Please help me.

Thanks,
Angel
[ July 25, 2005: Message edited by: Angel Hafer ]
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16250
    
  21

Check your other logfiles like the localhost log. It should be in one of them.

Catalina.out is mostly for messages from the Tomcat system itself, not apps. It does tend to see some app messages (also I think stdout prints) under Solaris, but not in Linux.
 
Consider Paul's rocket mass heater.
 
subject: Problem with Linux