This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Tomcat and the fly likes running Tomcat server from an USB key Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "running Tomcat server from an USB key" Watch "running Tomcat server from an USB key" New topic
Author

running Tomcat server from an USB key

Celinio Fernandes
Ranch Hand

Joined: Jun 28, 2003
Posts: 547

Hi,
I am trying to run Tomcat5.5.17 from my USB key.
I first have it running from my hard drive d:\Tomcat5.5.17\

I copied the files to my USB key, launched F:\Tomcat5.5.17\bin\tomcat5.exe
and I can see in the DOS console that it cannot find certain files
java.io.FileNotFoundException: C:\Program Files\Apache Software Foundation\Tomcat 5.5\conf\tomcat-users.xml.new (Acces denied)
at java.io.FileOutputStream.open(Native Method)
The denied permission is because I do not have the rights to write on this hard drive. That is why I want to run it from my USB key.

Can anyone tell me which files and settings I need to modify to make it work ?
Or point me to any good link on the subject.
Thanks in advance.


SCJP 1.4, SCWCD 1.4, SCBCD 1.3, SCBCD 5
Visit my blog
Sivaraman Lakshmanan
Ranch Hand

Joined: Aug 02, 2003
Posts: 231
Hi Max,
Since you are running the Tomcat from USB key(F, all the files it should take from F: only. I am just wondering why is it looking at C:. Did you set the CATALINA_HOME variable to C:?


Regards,
Sivaraman.L
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8839
    
    7

You should be aware that flash drives can wear out, so running an application from one, as opposed to storing data, is a bad idea


"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12761
    
    5
What happens if you try launching with startup.bat from a command prompt with the ..\bin current dirctory? That does some tricks to set environment variables according to where it starts.
Bill
Stu Thompson
Hooplehead
Ranch Hand

Joined: Jun 14, 2006
Posts: 136
Originally posted by Joe Ess:
You should be aware that flash drives can wear out, so running an application from one, as opposed to storing data, is a bad idea


Great idea for demo or school settings, but yea...seems like a bad idea outside of that. Note that USB is significantly slower than HDDs also...something to be aware of.


"This is not to say that design is unnecessary. But after a certain point, design is just speculation." --Philip Chu
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: running Tomcat server from an USB key
 
Similar Threads
Difference between UBUNTU bootable USB drive and UBUNTU installation on USB Drive
Eclipse projects on removable media
Runtime getRuntime() exec(String command) - How does this work?
right clicking on the hard drive partition shows some junk characters
usb drive