Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
The moose likes Tomcat and the fly likes tomcat 5.5/windows -- is not reading env vars Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "tomcat 5.5/windows -- is not reading env vars" Watch "tomcat 5.5/windows -- is not reading env vars" New topic
Author

tomcat 5.5/windows -- is not reading env vars

maya brown
Ranch Hand

Joined: Feb 18, 2009
Posts: 42

hi,

I'm having a weird problem.. downloaded tomcat 5.5, installed sdk/jre 1.5.0_22, set up env vars (JAVA_HOME, JRE_HOME, CATALINA_HOME)
yet when go to start tomcat (by running tomcat/bin/startup.bat) get told JAVA_HOME & JRE_HOME are not set, by they are set.. this on an XP machine, I have installed tomcat and set env vars in xp machines many times.. I don't get why it's not reading env vars (when type 'set' in DOS shell it does not show these two env vars, which I have set and can see when go to windows CP/system/advanced/env vars)

thank you..

Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16019
    
  20

Windows maintains 2 sets of environment variables. System-wide variables and per-user variables. Usually, you can set your JAVA_HOME and Tomcat PATH variables in either place, but there can be cases where your command-line user ID isn't the same as your GUI user ID, in which case, the user variable settings won't come across.

You may actually find it more convenient to write a wrapper batch file that locally sets those variables then runs the tomcat commands (startup.bat or catalina.bat start).


Customer surveys are for companies who didn't pay proper attention to begin with.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: tomcat 5.5/windows -- is not reading env vars