Re: war files not deploying on redhat
Hi, I don't know if it was just a typo in your post, but AutoDeploy should be |autoDeploy. -- Edgar Alves | Paul Warner wrote: Hello, I have read the documentation and searched the archives, and whatever I have found, I have tried, but still my .war files will not unpack and auto deploy. I have been running a tomcat server for several months in which the .war files unpacked and auto-deployed perfectly. But with this new installation, the Redhat way, with files all over the place, I have not been able to make it work. I am using Tomcat 5.0.28 via an rpm on Redhat EL 3. I am accessing the tomcat server via apache and the jk2 connector. I have the server.xml file configured with: Host name=localhost debug=0 appBase=webApps unpackWARs=true AutoDeploy=true xmlValidation=false xmlNamespaceAware=false My application has its context.xml file in the META-INF directory correctly pointing to the appname, /copse. I have an xml file in /etc/tomcat5/Catalina/localhost/copse.xml which has in it: Context docBase=${catalina.home}/build/copse.war privileged=true antiResourceLocking=false antiJARLocking=false/Context The /webapps directory and its contents are owned by tomcat, the tomcat process owner. root has CATALINA_HOME in its environment, set to /usr/share/tomcat5. I have a link in /usr/share/tomcat5 to /var/lib/tomcat5/build, which contains the copse.war file. tomcat has read and write privs for this build/ directory and all its files. The differences between my working installation and the 'broken' one seem to be: 1. root owned the instance of tomcat in the working version, tomcat owns the instance of tomcat in the broken one 2. file permissions were not all tomcat rw in the broken one, but this I have fixed now - as far as I know all relevant files are owned by tomcat 3. CATALINA_HOME wasn't set properly for root at first in the 'broken' install - but this also has been fixed (I believe). It points to the directory that holds all the softlinks to the other directories, such as conf, webapps, build, and so on. I have resorted to unpacking the war file myself, and the application works. But unpacking by hand is cumbersome and time-consuming. Does anyone have the (I presume simple) key to unlock this problem? Thanks, Paul - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: war files not deploying on redhat
Hi, I don't know if it was just a typo in your post, but AutoDeploy should be |autoDeploy. -- Edgar Alves Thanks for the quick answer and sharp eye - but it WAS a typo, sorry! In the server.xml file, it is listed as autoDeploy=true. It is the basic server.xml file, not really altered by me, and almost exactly matches the server.xml file on the other machine, the one that works. Thanks, Paul | Paul Warner wrote: Hello, I have read the documentation and searched the archives, and whatever I have found, I have tried, but still my .war files will not unpack and auto deploy. I have been running a tomcat server for several months in which the .war files unpacked and auto-deployed perfectly. But with this new installation, the Redhat way, with files all over the place, I have not been able to make it work. I am using Tomcat 5.0.28 via an rpm on Redhat EL 3. I am accessing the tomcat server via apache and the jk2 connector. I have the server.xml file configured with: Host name=localhost debug=0 appBase=webApps unpackWARs=true AutoDeploy=true xmlValidation=false xmlNamespaceAware=false My application has its context.xml file in the META-INF directory correctly pointing to the appname, /copse. I have an xml file in /etc/tomcat5/Catalina/localhost/copse.xml which has in it: Context docBase=${catalina.home}/build/copse.war privileged=true antiResourceLocking=false antiJARLocking=false/Context The /webapps directory and its contents are owned by tomcat, the tomcat process owner. root has CATALINA_HOME in its environment, set to /usr/share/tomcat5. I have a link in /usr/share/tomcat5 to /var/lib/tomcat5/build, which contains the copse.war file. tomcat has read and write privs for this build/ directory and all its files. The differences between my working installation and the 'broken' one seem to be: 1. root owned the instance of tomcat in the working version, tomcat owns the instance of tomcat in the broken one 2. file permissions were not all tomcat rw in the broken one, but this I have fixed now - as far as I know all relevant files are owned by tomcat 3. CATALINA_HOME wasn't set properly for root at first in the 'broken' install - but this also has been fixed (I believe). It points to the directory that holds all the softlinks to the other directories, such as conf, webapps, build, and so on. I have resorted to unpacking the war file myself, and the application works. But unpacking by hand is cumbersome and time-consuming. Does anyone have the (I presume simple) key to unlock this problem? Thanks, Paul - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: war files not deploying on redhat
A typo in a post about a typo... :) s/|autodeploy/autoDeploy/ Edgar Alves wrote: Hi, I don't know if it was just a typo in your post, but AutoDeploy should be |autoDeploy. -- Edgar Alves | Paul Warner wrote: - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: WAR files and web.xml
I'm not sure what kind of information you are trying to change but I have a few suggestions which might get you started: 1) If the changes are something like database/realm passwords or logging information, you can put those in a context file called yourapp.xml and put it in $CATALINA_HOME/conf/Catalina/localhost before you drop your war in place. (For that matter I guess you could put any sort of resource or resource reference in there) So the user can modify the xml file before they run ant install and the install target drops the context file in that dir, and then the war in the webapps dir. (Or better yet, the user could modify the build.properties before doing the install and ant could do the configuration/substitution in the context file as described below.) 2) You could setup tokens like @REPLACE_HERE@ in your web.xml and then have something like user1.information=A and user2.information=B etc in your build.properties. You could use ant's replace target to replace the tokens during the war target. The user (or you) could then specify the deploy environment like this: ant -Ddeploy.env=user1 war which would create a war file using the user1. properties. We do this where I work to create wars for dev, test, uat, and production. If #2 looks like something you want to do, and you want the ant snippet, email me and I'll send it your way. :) |)ave -Original Message- From: Mark [mailto:[EMAIL PROTECTED] Sent: Friday, April 01, 2005 6:27 AM To: Tomcat Users List Subject: WAR files and web.xml I have a question concerning the generation of a war file and my web.xml file. I want to create a WAR file for my web application using Ant, and place my web.xml file into the WAR file. The problem I have is that once the web.xml file is placed into the web.xml file, users/admins will not be able to make changes to the configuration parameters in the web.xml file. For instance, I have a servlet that I load at tomcatstartup and it reads configuration information from the web.xml. Now if the web.xml file has to be placed into the WAR file, a customer will not be able to customize the values contained in the web.xml file. So, am I missing something, or is this how everything is supposed to work? Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WAR files and web.xml
For the same needs, I use the Context.xml outside the war. use the tags Parameter .../ to pass your admin parameters. Regards. On Fri, 1 Apr 2005 08:26:37 -0500 Mark [EMAIL PROTECTED] wrote: I have a question concerning the generation of a war file and my web.xml file. I want to create a WAR file for my web application using Ant, and place my web.xml file into the WAR file. The problem I have is that once the web.xml file is placed into the web.xml file, users/admins will not be able to make changes to the configuration parameters in the web.xml file. For instance, I have a servlet that I load at tomcatstartup and it reads configuration information from the web.xml. Now if the web.xml file has to be placed into the WAR file, a customer will not be able to customize the values contained in the web.xml file. So, am I missing something, or is this how everything is supposed to work? Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WAR files and Eclipse
I did as suggested but it didn't work . The ironic thing now is that scence I tried that the user accounts /home/username/public_html no longer works to compile jsp pages. I figure this is weird becasue I see the compilation .class files in the $CATALINAHOME/work/Catalina/localhost/~username/classname.class, but when I try to go to http://localhost/~username/index.jsp I just see a pure white page. No matter how many time I reboot the server I get the same result Does anyone else want to take a shoot at this or am I to give up. sven morales wrote: I think there is another attribute to Listener which is home.Base. Set this where you normally put user/public_html directory. For example on mine, its set as homeBase=/home and user home is /home/sergio. Once this is working, any war files on your /home/user/public_html should get expanded. --- Dwayne Ghant [EMAIL PROTECTED] wrote: Anybody won't to take a shoot at this? Dwayne Ghant wrote: Intresting question associated with this subject. If I have public_html enabled for developers on local machine ex: Listener className=org.apache.catalina.startup.UserConfig directoryName=public_html userClass=org.apache.catalina.startup.PasswdUserDatabase/ Can I have a setting for tomcat to unwar there personal test applications in there public_html directories I'm assuming it would look something like this (listed below): Host name=localhost debug=0 appBase=/home/*/public_html unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host I'm probably incorrect, but I do need to know, to finish setting up JSP enviornment for java developers like myself. . Rhino wrote: It's actually very easy to do what you want to do. Assuming you have correctly installed and configured Sysdeo, you will need to tell Eclipse where the War file for your Tomcat project should be generated. This is done on a *project* basis, i.e. you have to repeat this step once for each Tomcat project you create but you will never have to do this again for a given project unless you change the location where you want the War file. 1. Select the Tomcat project in the Package Explorer perspective. 2. Right click for a context menu. Choose 'Properties'. 3. Within Properties, choose 'Tomcat' from the tree on the left. 4. Click on the 'Export to WAR settings' tab within the Tomcat properties. 5. Enter the path that tells Tomcat where to generate your War file. The path name should include the file name of the War file. I normally put my War files in a folder called 'war' directly beneath the project so my WAR file for export looks like this: D:\eclipse\workspace\MyProject\war\MyProject.war. Naturally, you are free to organize your files differently. 6. Click on OK to close the Properties dialog. Then, every time you want to regenerate your War file, all you need to do is this: 1. Select the Tomcat project in the Package Explorer perspective. 2. Right-click for a context menu. Choose 'Tomcat project'. 3. Choose 'Export to the war file sets in project properties'. 4. You should get a brief message that tells you the operation worked. Now, if you don't find Tomcat in the Properties tree or if you don't see the 'Tomcat project' option in the context menu, it means you probably didn't configure Sysdeo correctly. Don't worry, it's not that hard to fix. Just let us know and we'll try to help. Rhino - Original Message - From: Daniel Watrous [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, December 13, 2004 3:43 PM Subject: WAR files and Eclipse Hello All, I am new to WAR files and eclipse. Many searches on google bring me to the sysdeo tomcat plugin, which I have installed. I want to know if there is some standard way to generate a WAR file for deployment. I have found that I can export a JAR file and change its name, but in the process the directory structure is altered. Maybe you even know about a better IDE than eclipse for working with web-based projects. THANKS in advance. Daniel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Dwayne A. Ghant Application Developer Temple University 215.204. [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL
Re: WAR files and Eclipse
Yes you are correct. Thus far I have correctly configured Apache2.x/Tomcat5.x/mod.jk2 . And it works pretty seamlessly. My attemps to get the the useraccounts working resulted in me doing this: Listener className=org.apache.catalina.startup.UserConfig directoryName=public_html homeBase=/home/ userClass=org.apache.catalina.startup.PasswdUserDatabase/ Which did work!!! The only objective I was trying to achive after that was working; was too make sure tomcat would unzip all .jar file in /home/useraccounts/public_html/ . I thought this would be preatty simple. If I am correct I do believe that the unziping funtionality is bound to the Host tag. Allowing only the appBase attribute to be used once per Host tag. ex: Host name=localhost debug=0 appBase=/var/www/html/ unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false So with that said I belive that I would have to set up another host. Everyone out there: If I stand corrected please tell me ??? I LOVE IT WHEN I'M CORRECTED; it simply means I'm learning something new. sven morales wrote: Wait a minute, you didnt say you were using Apache to front the Tomcat did you? At least thats the impression I gathered since you were hitting it as http://localhost/~userjoe/index.jsp. I am not overly familiar with having Apache fronting Tomcat. With that kind of URI, I think its going to the apache side and not to Tomcat. You must set your mapping in http.conf or worker.properties(?) to make this work. Or your set-up has Tomcat serving off port 80 and you are running this as root right? --- Dwayne Ghant [EMAIL PROTECTED] wrote: I did as suggested but it didn't work . The ironic thing now is that scence I tried that the user accounts /home/username/public_html no longer works to compile jsp pages. I figure this is weird becasue I see the compilation .class files in the $CATALINAHOME/work/Catalina/localhost/~username/classname.class, but when I try to go to http://localhost/~username/index.jsp I just see a pure white page. No matter how many time I reboot the server I get the same result Does anyone else want to take a shoot at this or am I to give up. sven morales wrote: I think there is another attribute to Listener which is home.Base. Set this where you normally put user/public_html directory. For example on mine, its set as homeBase=/home and user home is /home/sergio. Once this is working, any war files on your /home/user/public_html should get expanded. --- Dwayne Ghant [EMAIL PROTECTED] wrote: Anybody won't to take a shoot at this? Dwayne Ghant wrote: Intresting question associated with this subject. If I have public_html enabled for developers on local machine ex: Listener className=org.apache.catalina.startup.UserConfig directoryName=public_html userClass=org.apache.catalina.startup.PasswdUserDatabase/ Can I have a setting for tomcat to unwar there personal test applications in there public_html directories I'm assuming it would look something like this (listed below): Host name=localhost debug=0 appBase=/home/*/public_html unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host I'm probably incorrect, but I do need to know, to finish setting up JSP enviornment for java developers like myself. . Rhino wrote: It's actually very easy to do what you want to do. Assuming you have correctly installed and configured Sysdeo, you will need to tell Eclipse where the War file for your Tomcat project should be generated. This is done on a *project* basis, i.e. you have to repeat this step once for each Tomcat project you create but you will never have to do this again for a given project unless you change the location where you want the War file. 1. Select the Tomcat project in the Package Explorer perspective. 2. Right click for a context menu. Choose 'Properties'. 3. Within Properties, choose 'Tomcat' from the tree on the left. 4. Click on the 'Export to WAR settings' tab within the Tomcat properties. 5. Enter the path that tells Tomcat where to generate your War file. The path name should include the file name of the War file. I normally put my War files in a
Re: WAR files and Eclipse
Wait a minute, you didnt say you were using Apache to front the Tomcat did you? At least thats the impression I gathered since you were hitting it as http://localhost/~userjoe/index.jsp. I am not overly familiar with having Apache fronting Tomcat. With that kind of URI, I think its going to the apache side and not to Tomcat. You must set your mapping in http.conf or worker.properties(?) to make this work. Or your set-up has Tomcat serving off port 80 and you are running this as root right? --- Dwayne Ghant [EMAIL PROTECTED] wrote: I did as suggested but it didn't work . The ironic thing now is that scence I tried that the user accounts /home/username/public_html no longer works to compile jsp pages. I figure this is weird becasue I see the compilation .class files in the $CATALINAHOME/work/Catalina/localhost/~username/classname.class, but when I try to go to http://localhost/~username/index.jsp I just see a pure white page. No matter how many time I reboot the server I get the same result Does anyone else want to take a shoot at this or am I to give up. sven morales wrote: I think there is another attribute to Listener which is home.Base. Set this where you normally put user/public_html directory. For example on mine, its set as homeBase=/home and user home is /home/sergio. Once this is working, any war files on your /home/user/public_html should get expanded. --- Dwayne Ghant [EMAIL PROTECTED] wrote: Anybody won't to take a shoot at this? Dwayne Ghant wrote: Intresting question associated with this subject. If I have public_html enabled for developers on local machine ex: Listener className=org.apache.catalina.startup.UserConfig directoryName=public_html userClass=org.apache.catalina.startup.PasswdUserDatabase/ Can I have a setting for tomcat to unwar there personal test applications in there public_html directories I'm assuming it would look something like this (listed below): Host name=localhost debug=0 appBase=/home/*/public_html unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host I'm probably incorrect, but I do need to know, to finish setting up JSP enviornment for java developers like myself. . Rhino wrote: It's actually very easy to do what you want to do. Assuming you have correctly installed and configured Sysdeo, you will need to tell Eclipse where the War file for your Tomcat project should be generated. This is done on a *project* basis, i.e. you have to repeat this step once for each Tomcat project you create but you will never have to do this again for a given project unless you change the location where you want the War file. 1. Select the Tomcat project in the Package Explorer perspective. 2. Right click for a context menu. Choose 'Properties'. 3. Within Properties, choose 'Tomcat' from the tree on the left. 4. Click on the 'Export to WAR settings' tab within the Tomcat properties. 5. Enter the path that tells Tomcat where to generate your War file. The path name should include the file name of the War file. I normally put my War files in a folder called 'war' directly beneath the project so my WAR file for export looks like this: D:\eclipse\workspace\MyProject\war\MyProject.war. Naturally, you are free to === message truncated === __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WAR files and Eclipse
Anybody won't to take a shoot at this? Dwayne Ghant wrote: Intresting question associated with this subject. If I have public_html enabled for developers on local machine ex: Listener className=org.apache.catalina.startup.UserConfig directoryName=public_html userClass=org.apache.catalina.startup.PasswdUserDatabase/ Can I have a setting for tomcat to unwar there personal test applications in there public_html directories I'm assuming it would look something like this (listed below): Host name=localhost debug=0 appBase=/home/*/public_html unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host I'm probably incorrect, but I do need to know, to finish setting up JSP enviornment for java developers like myself. . Rhino wrote: It's actually very easy to do what you want to do. Assuming you have correctly installed and configured Sysdeo, you will need to tell Eclipse where the War file for your Tomcat project should be generated. This is done on a *project* basis, i.e. you have to repeat this step once for each Tomcat project you create but you will never have to do this again for a given project unless you change the location where you want the War file. 1. Select the Tomcat project in the Package Explorer perspective. 2. Right click for a context menu. Choose 'Properties'. 3. Within Properties, choose 'Tomcat' from the tree on the left. 4. Click on the 'Export to WAR settings' tab within the Tomcat properties. 5. Enter the path that tells Tomcat where to generate your War file. The path name should include the file name of the War file. I normally put my War files in a folder called 'war' directly beneath the project so my WAR file for export looks like this: D:\eclipse\workspace\MyProject\war\MyProject.war. Naturally, you are free to organize your files differently. 6. Click on OK to close the Properties dialog. Then, every time you want to regenerate your War file, all you need to do is this: 1. Select the Tomcat project in the Package Explorer perspective. 2. Right-click for a context menu. Choose 'Tomcat project'. 3. Choose 'Export to the war file sets in project properties'. 4. You should get a brief message that tells you the operation worked. Now, if you don't find Tomcat in the Properties tree or if you don't see the 'Tomcat project' option in the context menu, it means you probably didn't configure Sysdeo correctly. Don't worry, it's not that hard to fix. Just let us know and we'll try to help. Rhino - Original Message - From: Daniel Watrous [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, December 13, 2004 3:43 PM Subject: WAR files and Eclipse Hello All, I am new to WAR files and eclipse. Many searches on google bring me to the sysdeo tomcat plugin, which I have installed. I want to know if there is some standard way to generate a WAR file for deployment. I have found that I can export a JAR file and change its name, but in the process the directory structure is altered. Maybe you even know about a better IDE than eclipse for working with web-based projects. THANKS in advance. Daniel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Dwayne A. Ghant Application Developer Temple University 215.204. [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WAR files and Eclipse
I think there is another attribute to Listener which is home.Base. Set this where you normally put user/public_html directory. For example on mine, its set as homeBase=/home and user home is /home/sergio. Once this is working, any war files on your /home/user/public_html should get expanded. --- Dwayne Ghant [EMAIL PROTECTED] wrote: Anybody won't to take a shoot at this? Dwayne Ghant wrote: Intresting question associated with this subject. If I have public_html enabled for developers on local machine ex: Listener className=org.apache.catalina.startup.UserConfig directoryName=public_html userClass=org.apache.catalina.startup.PasswdUserDatabase/ Can I have a setting for tomcat to unwar there personal test applications in there public_html directories I'm assuming it would look something like this (listed below): Host name=localhost debug=0 appBase=/home/*/public_html unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host I'm probably incorrect, but I do need to know, to finish setting up JSP enviornment for java developers like myself. . Rhino wrote: It's actually very easy to do what you want to do. Assuming you have correctly installed and configured Sysdeo, you will need to tell Eclipse where the War file for your Tomcat project should be generated. This is done on a *project* basis, i.e. you have to repeat this step once for each Tomcat project you create but you will never have to do this again for a given project unless you change the location where you want the War file. 1. Select the Tomcat project in the Package Explorer perspective. 2. Right click for a context menu. Choose 'Properties'. 3. Within Properties, choose 'Tomcat' from the tree on the left. 4. Click on the 'Export to WAR settings' tab within the Tomcat properties. 5. Enter the path that tells Tomcat where to generate your War file. The path name should include the file name of the War file. I normally put my War files in a folder called 'war' directly beneath the project so my WAR file for export looks like this: D:\eclipse\workspace\MyProject\war\MyProject.war. Naturally, you are free to organize your files differently. 6. Click on OK to close the Properties dialog. Then, every time you want to regenerate your War file, all you need to do is this: 1. Select the Tomcat project in the Package Explorer perspective. 2. Right-click for a context menu. Choose 'Tomcat project'. 3. Choose 'Export to the war file sets in project properties'. 4. You should get a brief message that tells you the operation worked. Now, if you don't find Tomcat in the Properties tree or if you don't see the 'Tomcat project' option in the context menu, it means you probably didn't configure Sysdeo correctly. Don't worry, it's not that hard to fix. Just let us know and we'll try to help. Rhino - Original Message - From: Daniel Watrous [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, December 13, 2004 3:43 PM Subject: WAR files and Eclipse Hello All, I am new to WAR files and eclipse. Many searches on google bring me to the sysdeo tomcat plugin, which I have installed. I want to know if there is some standard way to generate a WAR file for deployment. I have found that I can export a JAR file and change its name, but in the process the directory structure is altered. Maybe you even know about a better IDE than eclipse for working with web-based projects. THANKS in advance. Daniel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Dwayne A. Ghant Application Developer Temple University 215.204. [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do you Yahoo!? The all-new My Yahoo! - Get yours free! http://my.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WAR files and Eclipse
Intresting question associated with this subject. If I have public_html enabled for developers on local machine ex: Listener className=org.apache.catalina.startup.UserConfig directoryName=public_html userClass=org.apache.catalina.startup.PasswdUserDatabase/ Can I have a setting for tomcat to unwar there personal test applications in there public_html directories I'm assuming it would look something like this (listed below): Host name=localhost debug=0 appBase=/home/*/public_html unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host I'm probably incorrect, but I do need to know, to finish setting up JSP enviornment for java developers like myself. . Rhino wrote: It's actually very easy to do what you want to do. Assuming you have correctly installed and configured Sysdeo, you will need to tell Eclipse where the War file for your Tomcat project should be generated. This is done on a *project* basis, i.e. you have to repeat this step once for each Tomcat project you create but you will never have to do this again for a given project unless you change the location where you want the War file. 1. Select the Tomcat project in the Package Explorer perspective. 2. Right click for a context menu. Choose 'Properties'. 3. Within Properties, choose 'Tomcat' from the tree on the left. 4. Click on the 'Export to WAR settings' tab within the Tomcat properties. 5. Enter the path that tells Tomcat where to generate your War file. The path name should include the file name of the War file. I normally put my War files in a folder called 'war' directly beneath the project so my WAR file for export looks like this: D:\eclipse\workspace\MyProject\war\MyProject.war. Naturally, you are free to organize your files differently. 6. Click on OK to close the Properties dialog. Then, every time you want to regenerate your War file, all you need to do is this: 1. Select the Tomcat project in the Package Explorer perspective. 2. Right-click for a context menu. Choose 'Tomcat project'. 3. Choose 'Export to the war file sets in project properties'. 4. You should get a brief message that tells you the operation worked. Now, if you don't find Tomcat in the Properties tree or if you don't see the 'Tomcat project' option in the context menu, it means you probably didn't configure Sysdeo correctly. Don't worry, it's not that hard to fix. Just let us know and we'll try to help. Rhino - Original Message - From: Daniel Watrous [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, December 13, 2004 3:43 PM Subject: WAR files and Eclipse Hello All, I am new to WAR files and eclipse. Many searches on google bring me to the sysdeo tomcat plugin, which I have installed. I want to know if there is some standard way to generate a WAR file for deployment. I have found that I can export a JAR file and change its name, but in the process the directory structure is altered. Maybe you even know about a better IDE than eclipse for working with web-based projects. THANKS in advance. Daniel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Dwayne A. Ghant Application Developer Temple University 215.204. [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WAR files and Eclipse
It's actually very easy to do what you want to do. Assuming you have correctly installed and configured Sysdeo, you will need to tell Eclipse where the War file for your Tomcat project should be generated. This is done on a *project* basis, i.e. you have to repeat this step once for each Tomcat project you create but you will never have to do this again for a given project unless you change the location where you want the War file. 1. Select the Tomcat project in the Package Explorer perspective. 2. Right click for a context menu. Choose 'Properties'. 3. Within Properties, choose 'Tomcat' from the tree on the left. 4. Click on the 'Export to WAR settings' tab within the Tomcat properties. 5. Enter the path that tells Tomcat where to generate your War file. The path name should include the file name of the War file. I normally put my War files in a folder called 'war' directly beneath the project so my WAR file for export looks like this: D:\eclipse\workspace\MyProject\war\MyProject.war. Naturally, you are free to organize your files differently. 6. Click on OK to close the Properties dialog. Then, every time you want to regenerate your War file, all you need to do is this: 1. Select the Tomcat project in the Package Explorer perspective. 2. Right-click for a context menu. Choose 'Tomcat project'. 3. Choose 'Export to the war file sets in project properties'. 4. You should get a brief message that tells you the operation worked. Now, if you don't find Tomcat in the Properties tree or if you don't see the 'Tomcat project' option in the context menu, it means you probably didn't configure Sysdeo correctly. Don't worry, it's not that hard to fix. Just let us know and we'll try to help. Rhino - Original Message - From: Daniel Watrous [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, December 13, 2004 3:43 PM Subject: WAR files and Eclipse Hello All, I am new to WAR files and eclipse. Many searches on google bring me to the sysdeo tomcat plugin, which I have installed. I want to know if there is some standard way to generate a WAR file for deployment. I have found that I can export a JAR file and change its name, but in the process the directory structure is altered. Maybe you even know about a better IDE than eclipse for working with web-based projects. THANKS in advance. Daniel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WAR files and Eclipse
I tried eclipse, but man was it hard to get configured properly. I wanted to use Eclipse/MyEclipse since I do Perl/C/C++ work as well and thought one tool that binds them all, yada yada yada. I then tried NetBeans and it worked for my environment 'out-of-the-box'. It took zero configuration for me. I just pointed it at my existing source tree and it built its environment and ant scripts accordingly. I really like all of it's editors/interfaces better as well. I would rather use 2 tools (NetBeans for java stuff, and eclipse(or my older editor) for everything else) than jump through Eclipses' hoops for java/J2EE stuff. Your mileage may vary. --JW Phillip Qin wrote: It is very easy. Use ant's war task. -Original Message- From: Daniel Watrous [mailto:[EMAIL PROTECTED] Sent: December 13, 2004 3:44 PM To: [EMAIL PROTECTED] Subject: WAR files and Eclipse Hello All, I am new to WAR files and eclipse. Many searches on google bring me to the sysdeo tomcat plugin, which I have installed. I want to know if there is some standard way to generate a WAR file for deployment. I have found that I can export a JAR file and change its name, but in the process the directory structure is altered. Maybe you even know about a better IDE than eclipse for working with web-based projects. THANKS in advance. Daniel !DSPAM:41bdff16171791264215269! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: WAR files and Eclipse
It is very easy. Use ant's war task. -Original Message- From: Daniel Watrous [mailto:[EMAIL PROTECTED] Sent: December 13, 2004 3:44 PM To: [EMAIL PROTECTED] Subject: WAR files and Eclipse Hello All, I am new to WAR files and eclipse. Many searches on google bring me to the sysdeo tomcat plugin, which I have installed. I want to know if there is some standard way to generate a WAR file for deployment. I have found that I can export a JAR file and change its name, but in the process the directory structure is altered. Maybe you even know about a better IDE than eclipse for working with web-based projects. THANKS in advance. Daniel !DSPAM:41bdff16171791264215269!
RE: War files don't work
Tang, Thanks for the reply. Unfortunantly, that isn't the behavior I am seeing, and I think the other poster had the same issue. If I don't have a context for my war file in the server.xml, then it unpacks fine. But, if I do have a context, then it won't unpack, and I have to do it manually. This is the server conf that I am trying to use that doesn't work: Context className=org.apache.catalina.core.StandardContext cachingAllowed=true charsetMapperClass=org.apache.catalina.util.CharsetMapper cookies=true crossContext=false debug=0 docBase=fortius.war mapperClass=org.apache.catalina.core.StandardContextMapper path=/fortius privileged=false reloadable=true swallowOutput=false useNaming=true wrapperClass=org.apache.catalina.core.StandardWrapper Environment description= name=local_dir override=true type=java.lang.String value=d:/java/tomcat/webapps/fortius/data/scintfiles/ /Context I do have the docBase pointing to my war file. Eric Pugh -Original Message- From: Tang To: Tomcat Users List; [EMAIL PROTECTED] Sent: 7/24/03 9:31 PM Subject: Re: War files don't work Hi, all you need to do is place WAR file into webapps directory, Tomcat will unpack for you. If you don't pack web application into WAR file. You should copy web application directory into webapps directory and config context parameter. You can check tomcat-docs for more configuration details. - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Thursday, July 24, 2003 6:18 PM Subject: RE: War files don't work I'm joining this thread late, but I posted a couple weeks ago the same problem.. I am running JDK1.4.2 and Tomcat 4.1.24. If I have a context specified in server.xml, then the war file DOESN'T unpack. If I don't have a context specified, then it DOES unpack. Setting the docBase to fortius.war versus fortius doesn't seem to matter at all. I am building my war file using Maven.. could that be the problem? Eric Pugh -Original Message- From: Rick Roberts To: Tomcat Users List Sent: 7/23/03 3:26 PM Subject: Re: War files don't work Making docBase = nsfs.war vice nsfs works!! :) However; the war file is not being unpacked. It seems that unpackWARs=true works the same as unpackWARs=false Thanks, Rick John Turner wrote: From the docs for Context: The Document Base (also known as the Context Root) directory for this web application, or the pathname to the web application archive file (if this web application is being executed directly from the WAR file). You may specify an absolute pathname for this directory or WAR file, or a pathname that is relative to the appBase directory of the owning Host. Thus, if you're going to put a Context entry in server.xml for nsfs, make the docBase nsfs.war, not nsfs. Further: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automat ic%20Application%20Deployment John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira
RE: War files don't work
What the Automatic Applcation Deployment doc says is that if you have a WAR file, it won't be expanded if you have a context element in the server.xml document. It will only be run from that war file in an unexpanded format. correct? Eric -Original Message- From: John Turner To: Tomcat Users List Sent: 7/23/03 3:18 PM Subject: Re: War files don't work Check out the rules for Auto deployment: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automat ic%20Application%20Deployment John Rick Roberts wrote: This sounds reasonable to me. But, if I don't have a Context/ element in server.xml then how do I provide Context/ type information to Tomcat? !-- NSFS Context -- Context path=/nsfs docBase=nsfs debug=0 reloadable=true crossContext=true Logger className=org.apache.catalina.logger.FileLogger prefix=nsfs_log. suffix=.txt timestamp=true/ /Context BTW, manually creating the nsfs/ directory did not help. however; if i manually create the nsfs/ dir and manually unpack the .war file everything works fine. another question: did I correctly create the nsfs.war file and test it by doing the following?: 1. cd to the webapps/nsfs/ directory 2. jar -cvf nsfs.war * 3. cp nsfs.war ../. (the webapps dir) 4. rm -rf nsfs/ 5. restart tomcat 6. use browser and navigate to http://localhost/nsfs Thanks, Rick - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
That's how I read it. Basically, a Context in server.xml trumps automatic deployment. As I understand it, you have to pick one or the other, not both. If you must put a Context in server.xml for your web application, and you want to use a WAR file, then make the docBase of the Context the WAR file, not a directory, like this: docBase=myApp.war John [EMAIL PROTECTED] wrote: What the Automatic Applcation Deployment doc says is that if you have a WAR file, it won't be expanded if you have a context element in the server.xml document. It will only be run from that war file in an unexpanded format. correct? Eric -Original Message- From: John Turner To: Tomcat Users List Sent: 7/23/03 3:18 PM Subject: Re: War files don't work Check out the rules for Auto deployment: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automat ic%20Application%20Deployment John Rick Roberts wrote: This sounds reasonable to me. But, if I don't have a Context/ element in server.xml then how do I provide Context/ type information to Tomcat? !-- NSFS Context -- Context path=/nsfs docBase=nsfs debug=0 reloadable=true crossContext=true Logger className=org.apache.catalina.logger.FileLogger prefix=nsfs_log. suffix=.txt timestamp=true/ /Context BTW, manually creating the nsfs/ directory did not help. however; if i manually create the nsfs/ dir and manually unpack the .war file everything works fine. another question: did I correctly create the nsfs.war file and test it by doing the following?: 1. cd to the webapps/nsfs/ directory 2. jar -cvf nsfs.war * 3. cp nsfs.war ../. (the webapps dir) 4. rm -rf nsfs/ 5. restart tomcat 6. use browser and navigate to http://localhost/nsfs Thanks, Rick - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: War files don't work
I'm joining this thread late, but I posted a couple weeks ago the same problem.. I am running JDK1.4.2 and Tomcat 4.1.24. If I have a context specified in server.xml, then the war file DOESN'T unpack. If I don't have a context specified, then it DOES unpack. Setting the docBase to fortius.war versus fortius doesn't seem to matter at all. I am building my war file using Maven.. could that be the problem? Eric Pugh -Original Message- From: Rick Roberts To: Tomcat Users List Sent: 7/23/03 3:26 PM Subject: Re: War files don't work Making docBase = nsfs.war vice nsfs works!! :) However; the war file is not being unpacked. It seems that unpackWARs=true works the same as unpackWARs=false Thanks, Rick John Turner wrote: From the docs for Context: The Document Base (also known as the Context Root) directory for this web application, or the pathname to the web application archive file (if this web application is being executed directly from the WAR file). You may specify an absolute pathname for this directory or WAR file, or a pathname that is relative to the appBase directory of the owning Host. Thus, if you're going to put a Context entry in server.xml for nsfs, make the docBase nsfs.war, not nsfs. Further: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automat ic%20Application%20Deployment John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: War files don't work
You need to make sure that you delete the webapps/nsfs directory before starting tomcat, or tomcat won't unpack the .war file. Place the .war file directly in the webapps directory. From: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/appdev/deployment.html Copy the web application archive file into directory $CATALINA_HOME/webapps/. When Tomcat is started, it will automatically expand the web application archive file into its unpacked form, and execute the application that way. This approach would typically be used to install an additional application, provided by a third party vendor or by your internal development staff, into an existing Tomcat installation. NOTE - If you use this approach, and wish to update your application later, you must both replace the web application archive file AND delete the expanded directory that Tomcat created, and then restart Tomcat, in order to reflect your changes. -Original Message- From: Rick Roberts [mailto:[EMAIL PROTECTED] Sent: 23 July 2003 20:27 To: Tomcat Users List Subject: Re: War files don't work Making docBase = nsfs.war vice nsfs works!! :) However; the war file is not being unpacked. It seems that unpackWARs=true works the same as unpackWARs=false Thanks, Rick John Turner wrote: From the docs for Context: The Document Base (also known as the Context Root) directory for this web application, or the pathname to the web application archive file (if this web application is being executed directly from the WAR file). You may specify an absolute pathname for this directory or WAR file, or a pathname that is relative to the appBase directory of the owning Host. Thus, if you're going to put a Context entry in server.xml for nsfs, make the docBase nsfs.war, not nsfs. Further: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automatic%2 0Application%20Deployment John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
Hi, all you need to do is place WAR file into webapps directory, Tomcat will unpack for you. If you don't pack web application into WAR file. You should copy web application directory into webapps directory and config context parameter. You can check tomcat-docs for more configuration details. - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Thursday, July 24, 2003 6:18 PM Subject: RE: War files don't work I'm joining this thread late, but I posted a couple weeks ago the same problem.. I am running JDK1.4.2 and Tomcat 4.1.24. If I have a context specified in server.xml, then the war file DOESN'T unpack. If I don't have a context specified, then it DOES unpack. Setting the docBase to fortius.war versus fortius doesn't seem to matter at all. I am building my war file using Maven.. could that be the problem? Eric Pugh -Original Message- From: Rick Roberts To: Tomcat Users List Sent: 7/23/03 3:26 PM Subject: Re: War files don't work Making docBase = nsfs.war vice nsfs works!! :) However; the war file is not being unpacked. It seems that unpackWARs=true works the same as unpackWARs=false Thanks, Rick John Turner wrote: From the docs for Context: The Document Base (also known as the Context Root) directory for this web application, or the pathname to the web application archive file (if this web application is being executed directly from the WAR file). You may specify an absolute pathname for this directory or WAR file, or a pathname that is relative to the appBase directory of the owning Host. Thus, if you're going to put a Context entry in server.xml for nsfs, make the docBase nsfs.war, not nsfs. Further: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automat ic%20Application%20Deployment John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: War files don't work
Howdy, The error I get looks like this: HTTP Status 404 - /nsfs type Status report message /nsfs description The requested resource (/nsfs) is not available. Apache Tomcat/4.1 What the root cause and full stack trace? Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
2003-07-23 10:04:43 WebappLoader[/nsfs]: Deploying class repositories to work directory /var/tomcat4/work/Standalone/localhost/nsfs 2003-07-23 10:04:43 WebappLoader[/nsfs]: Reloading checks are enabled for this Context 2003-07-23 10:04:43 ContextConfig[/nsfs]: Missing application web.xml, using defaults only 2003-07-23 10:04:43 StandardManager[/nsfs]: Seeding random number generator class java.security.SecureRandom 2003-07-23 10:04:43 StandardManager[/nsfs]: Seeding of random number generator has been completed 2003-07-23 10:04:43 StandardWrapper[/nsfs:default]: Loading container servlet default 2003-07-23 10:04:43 default: init 2003-07-23 10:04:43 StandardWrapper[/nsfs:invoker]: Loading container servlet invoker 2003-07-23 10:04:43 invoker: init 2003-07-23 10:04:43 jsp: init 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory at org.apache.naming.resources.FileDirContext.setDocBase(Unknown Source) at org.apache.catalina.core.StandardContext.resourcesStart(Unknown Source) at org.apache.catalina.core.StandardContext.start(Unknown Source) at org.apache.catalina.core.ContainerBase.start(Unknown Source) at org.apache.catalina.core.StandardHost.start(Unknown Source) at org.apache.catalina.core.ContainerBase.start(Unknown Source) at org.apache.catalina.core.StandardEngine.start(Unknown Source) at org.apache.catalina.core.StandardService.start(Unknown Source) at org.apache.catalina.core.StandardServer.start(Unknown Source) at org.apache.catalina.startup.Catalina.start(Unknown Source) at org.apache.catalina.startup.Catalina.execute(Unknown Source) at org.apache.catalina.startup.Catalina.process(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.apache.catalina.startup.Bootstrap.main(Unknown Source) Shapira, Yoav wrote: Howdy, The error I get looks like this: HTTP Status 404 - /nsfs type Status report message /nsfs description The requested resource (/nsfs) is not available. Apache Tomcat/4.1 What the root cause and full stack trace? Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Seems self-explanatory to me. John Rick Roberts wrote: 2003-07-23 10:04:43 WebappLoader[/nsfs]: Deploying class repositories to work directory /var/tomcat4/work/Standalone/localhost/nsfs 2003-07-23 10:04:43 WebappLoader[/nsfs]: Reloading checks are enabled for this Context 2003-07-23 10:04:43 ContextConfig[/nsfs]: Missing application web.xml, using defaults only 2003-07-23 10:04:43 StandardManager[/nsfs]: Seeding random number generator class java.security.SecureRandom 2003-07-23 10:04:43 StandardManager[/nsfs]: Seeding of random number generator has been completed 2003-07-23 10:04:43 StandardWrapper[/nsfs:default]: Loading container servlet default 2003-07-23 10:04:43 default: init 2003-07-23 10:04:43 StandardWrapper[/nsfs:invoker]: Loading container servlet invoker 2003-07-23 10:04:43 invoker: init 2003-07-23 10:04:43 jsp: init 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
Does the war file contain a web.xml file that contains entries for the /nsfs servlet? If not, that's likely your problem. Rhino - Original Message - From: Rick Roberts [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 12:11 PM Subject: War files don't work My server.xml contains this: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true !-- NSFS Context -- Context path=/nsfs docBase=nsfs debug=0 reloadable=true crossContext=true Logger className=org.apache.catalina.logger.FileLogger prefix=nsfs_log. suffix=.txt timestamp=true/ /Context My webapps dir contains my war file (nsfs.war). The error I get looks like this: HTTP Status 404 - /nsfs type Status report message /nsfs description The requested resource (/nsfs) is not available. Apache Tomcat/4.1 If I manually expand the nsfs.war file into a webapps/nsfs/ directory then all works fine. How do I get Tomcat to use the war file? -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
John Turner wrote: 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Seems self-explanatory to me. John Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. Do I need to make changes to my workers2.properties file to accomodate the .war file instead of and expanded webapps/nsfs directory? # # /nsfs # [uri:/nsfs] info=NSFS WBS Web Application context=/nsfs debug=0 [uri:/nsfs/servlet/*] info=Prefix mapping [uri:/nsfs/*.jsp] info=Extension mapping [uri:/nsfs/*] info=Map the whole webapp -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: War files don't work
Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
Yes. My war file has a web.xml file within the WEB-INF/ directory structure of the war file. Rhino wrote: Does the war file contain a web.xml file that contains entries for the /nsfs servlet? If not, that's likely your problem. Rhino - Original Message - From: Rick Roberts [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 12:11 PM Subject: War files don't work My server.xml contains this: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true !-- NSFS Context -- Context path=/nsfs docBase=nsfs debug=0 reloadable=true crossContext=true Logger className=org.apache.catalina.logger.FileLogger prefix=nsfs_log. suffix=.txt timestamp=true/ /Context My webapps dir contains my war file (nsfs.war). The error I get looks like this: HTTP Status 404 - /nsfs type Status report message /nsfs description The requested resource (/nsfs) is not available. Apache Tomcat/4.1 If I manually expand the nsfs.war file into a webapps/nsfs/ directory then all works fine. How do I get Tomcat to use the war file? -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
nsfs.war goes in webapps. How about just creating the directory and seeing what happens? In any case, if you're using WAR files, there's no reason to have a Context defined in server.xml, that's probably what is confusing Tomcat. Tomcat is reading server.xml, which tells it to start a Context called nsfs with a docBase of nsfs but no such docBase exists. John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
From the docs for Context: The Document Base (also known as the Context Root) directory for this web application, or the pathname to the web application archive file (if this web application is being executed directly from the WAR file). You may specify an absolute pathname for this directory or WAR file, or a pathname that is relative to the appBase directory of the owning Host. Thus, if you're going to put a Context entry in server.xml for nsfs, make the docBase nsfs.war, not nsfs. Further: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automatic%20Application%20Deployment John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
This sounds reasonable to me. But, if I don't have a Context/ element in server.xml then how do I provide Context/ type information to Tomcat? !-- NSFS Context -- Context path=/nsfs docBase=nsfs debug=0 reloadable=true crossContext=true Logger className=org.apache.catalina.logger.FileLogger prefix=nsfs_log. suffix=.txt timestamp=true/ /Context BTW, manually creating the nsfs/ directory did not help. however; if i manually create the nsfs/ dir and manually unpack the .war file everything works fine. another question: did I correctly create the nsfs.war file and test it by doing the following?: 1. cd to the webapps/nsfs/ directory 2. jar -cvf nsfs.war * 3. cp nsfs.war ../. (the webapps dir) 4. rm -rf nsfs/ 5. restart tomcat 6. use browser and navigate to http://localhost/nsfs Thanks, Rick John Turner wrote: nsfs.war goes in webapps. How about just creating the directory and seeing what happens? In any case, if you're using WAR files, there's no reason to have a Context defined in server.xml, that's probably what is confusing Tomcat. Tomcat is reading server.xml, which tells it to start a Context called nsfs with a docBase of nsfs but no such docBase exists. John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
Check out the rules for Auto deployment: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automatic%20Application%20Deployment John Rick Roberts wrote: This sounds reasonable to me. But, if I don't have a Context/ element in server.xml then how do I provide Context/ type information to Tomcat? !-- NSFS Context -- Context path=/nsfs docBase=nsfs debug=0 reloadable=true crossContext=true Logger className=org.apache.catalina.logger.FileLogger prefix=nsfs_log. suffix=.txt timestamp=true/ /Context BTW, manually creating the nsfs/ directory did not help. however; if i manually create the nsfs/ dir and manually unpack the .war file everything works fine. another question: did I correctly create the nsfs.war file and test it by doing the following?: 1. cd to the webapps/nsfs/ directory 2. jar -cvf nsfs.war * 3. cp nsfs.war ../. (the webapps dir) 4. rm -rf nsfs/ 5. restart tomcat 6. use browser and navigate to http://localhost/nsfs Thanks, Rick - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files don't work
Making docBase = nsfs.war vice nsfs works!! :) However; the war file is not being unpacked. It seems that unpackWARs=true works the same as unpackWARs=false Thanks, Rick John Turner wrote: From the docs for Context: The Document Base (also known as the Context Root) directory for this web application, or the pathname to the web application archive file (if this web application is being executed directly from the WAR file). You may specify an absolute pathname for this directory or WAR file, or a pathname that is relative to the appBase directory of the owning Host. Thus, if you're going to put a Context entry in server.xml for nsfs, make the docBase nsfs.war, not nsfs. Further: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html#Automatic%20Application%20Deployment John Rick Roberts wrote: Does the nsfs.war file go into webapps directory or into webapps/nsfs directory? Currently, the webapps/nsfs dir does not exist. There is only the nsfs.war file setting in the webapps directory. I am assuming that Tomcat will create the webapps/nsfs directory for me when it expands the war file. I have temporarily set permissions to 777 on the webapps directory and it still does not expand, nor try to use, the war file. Rick John Turner wrote: You've told Tomcat the docBase is nsfs. Tomcat thusly looks for a directory called nsfs in the Host's appBase. If it finds it, and unpackWars is true, it will unpack your WAR file into that directory (webapps/nsfs, NOT webapps). Thus, Tomcat needs r+w on webapps/nsfs. Does Tomcat have r+w on webapps/nsfs? Alternatively, make unpackWars false. John Rick Roberts wrote: My directory permissions are as follows: drwxrwx---7 root tomcat4 4096 Jul 23 12:17 webapps ps -ef shows me this, which is think is Tomcat, which is run by user tomcat4: tomcat4 6199 1 0 12:17 pts/200:00:36 /usr/java/jdk1.4/bin/java -Djava.endorsed.dirs= -classpath /usr/java/jdk1.4/lib/tools.jar:/var Thanks, Rick Shapira, Yoav wrote: Howdy, 2003-07-23 11:09:30 StandardContext[/nsfs]: Resources start failed: java.lang.IllegalArgumentException: Document base /var/tomcat4/webapps/nsfs does not exist or is not a readable directory Well explain it to me! :) There is a /var/tomcat4/webapps/nsfs.war file. There should not be a /var/tomcat4/webapps/nsfs directory. If you have unpackWARS=true tomcat will try to explode your war into the directory specified as the docBase, which is nsfs under webapps. If it can't create this directory or read/write into it, you get the above error. Check file permissions on webapps. Yoav Shapira -- *** * Rick Roberts* * Advanced Information Technologies, Inc. * *** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: War files / codeBase and security permissions (v4.0.4)
You should not have to make any changes to policy files for this to work. It is Tomcat itself that is unpacking the WAR files--so assigning permissions to the WAR file itself won't do anything. What does your server.xml file look like? How did you determine that WAR files weren't automatically being unpacked? What error did you see? Sean Dockery [EMAIL PROTECTED] Certified Java Web Component Developer Certified Delphi Programmer SBD Consultants http://www.sbdconsultants.com - Original Message - From: Kenneth J Baker [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Saturday, February 08, 2003 21:13 Subject: War files / codeBase and security permissions (v4.0.4) I'm deploying a war file with unpackWARs=false. I am trying to grant permissions to this war in 04webapps.policy. Here is what I've tried... Given the examples this is what I would expect to work but doesn't: grant codeBase file:${catalina.home}/webapps/iface.war!/- { permission java.security.AllPermission; }; This doesn't work (but works if unpackWARs=true): grant codeBase file:${catalina.home}/webapps/iface/- { permission java.security.AllPermission; }; This works because this is where tomcat extracts the war to (with unpackWARs set to false) grant codeBase file:${catalina.home}/work/Standalone/localhost/iface/- { permission java.security.AllPermission; }; What is the correct way to specify permissions to give to a war file? Thanks, Ken - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: war files and context entries
Try creating a context.xml file and put yoru Context ... entry in that. Now put your context.xml in META-INF of your .war file. Remove the context entry from Server.xml. When Tomcat starts up and doesn't see your war there, it will mark the context as disabled and will get confused if you later try to put the .war file for that context there while Tomcat is running. Now Start Tomcat fresh and then deploy your .war file. Things should work fine now. Jake At 07:45 PM 12/10/2002 -0800, you wrote: I have a war file that I deploy to my server 4.1.12. If I just deploy the war file without making any entries in the server.xml file and start Tomcat, everything is fine. OK so far. However, if I make an explicit context entry in the server.xml file for the war file using the following entry: Host name=localhost debug=9 appBase=webapps unpackWARs=true autoDeploy=true Context path=/cda docBase=cda.war debug=9 reloadable=true/ /Host When I try to start tomcat, it looks as if everything is going fine then it just quits with no errors or anything. I checked the logfile, and the last entry is: [timestamp] StandardContext[/cda]: Sending application start events [timestamp] StandardContext[/cda]: Starting filters Am I missing something here? Obviously I am cause it doesnt work. I know my war file is correctly configured because it works fine without the Context entry. Dave Patton
Re: WAR files not expanding.
Andoni writes: When I put a .war file over to my tomcat server it doesn't work. - It only creates an empty directory in webapps. If I put over the war and unzip the file, it works fine. If I put over the .war file and set unpackWARs=false it does not work. - The unpack command is understood though as it does not create the directory in webapps I am using Tomcat 4.0.4. Has anyone come across anything similar? Thanks in advance, Andoni. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] Hello Andoni, have u tried to build and deploy using ant? david. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: WAR files don't unpack if the webapp is already there
It's a feature. Sucks, huh? - Original Message - From: James Turner [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, May 09, 2002 2:23 PM Subject: WAR files don't unpack if the webapp is already there I'm going through the standard compile-edit-test look on some applications using JBuilder and Tomcat right now. I've got JBuilder creating a new WAR file in TOMCAT_HOME/webapps on rebuild, but I need to delete the old webapp directory before Tomcat will notice the new one and unpack it. Is this a feature of Tomcat? Shouldn't it notice if the webapp directory is out of date in comparison to the WAR file? James -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: WAR files don't unpack if the webapp is already there
Older versions of Tomcat don't, new ones will if you set reloadable to true in the context. It will monitor WEB-ING/lib and WEB-INF/classes for changes and reload if it detects any. This canj cause a performance degradation on your server so you may only want to do this for development. Rick - Original Message - From: James Turner [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, May 09, 2002 3:23 PM Subject: WAR files don't unpack if the webapp is already there I'm going through the standard compile-edit-test look on some applications using JBuilder and Tomcat right now. I've got JBuilder creating a new WAR file in TOMCAT_HOME/webapps on rebuild, but I need to delete the old webapp directory before Tomcat will notice the new one and unpack it. Is this a feature of Tomcat? Shouldn't it notice if the webapp directory is out of date in comparison to the WAR file? James -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: WAR files don't unpack if the webapp is already there
Not sure what you mean by new ones, but TC 4.0.3 does NOT unpack wars if the directory already exists regardless of the reloadable flag. Jeff - Original Message - From: Rick Fincher [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Thursday, May 09, 2002 2:57 PM Subject: Re: WAR files don't unpack if the webapp is already there Older versions of Tomcat don't, new ones will if you set reloadable to true in the context. It will monitor WEB-ING/lib and WEB-INF/classes for changes and reload if it detects any. This canj cause a performance degradation on your server so you may only want to do this for development. Rick - Original Message - From: James Turner [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, May 09, 2002 3:23 PM Subject: WAR files don't unpack if the webapp is already there I'm going through the standard compile-edit-test look on some applications using JBuilder and Tomcat right now. I've got JBuilder creating a new WAR file in TOMCAT_HOME/webapps on rebuild, but I need to delete the old webapp directory before Tomcat will notice the new one and unpack it. Is this a feature of Tomcat? Shouldn't it notice if the webapp directory is out of date in comparison to the WAR file? James -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: War files and config info
Try setting a parameter in your web.xml to the value of an external location for your config file. Inside your init() method check this location first for the config file you want to load, if you find it load it and move on, else load the config file you distributed with your application. Hope this helps. Jeremy Joslin Software Engineer Spotlife Inc. -Original Message- From: Bryan P. Glennon [mailto:[EMAIL PROTECTED]] Sent: Monday, April 08, 2002 3:24 PM To: [EMAIL PROTECTED] Subject: War files and config info Hi - We have a web app that gets distributed in a war file to a tomcat 4.0x server. One of the things in the war file is a configuration file for the app. This is an XML file that we open as a resource (using getResourceAsStream()) in our main servlet init() method. So far, so good. But, we need a way to override this file so that we can make config changes without redistributing the entire application. If we don't use a war file, we can just put the override file (using the same name) in a directory that is earlier in the class path. But we would like to keep the war file, since it does make distribution a bit easier. Any ideas on how to make this work? FYI, the exact call we use to open the config file is InputStream in = this.getClass().getClassLoader().getResourceAsStream(configFile); TIA, Bryan -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Re: War files and config info
On Mon, 8 Apr 2002, Bryan P. Glennon wrote: Date: Mon, 8 Apr 2002 17:24:19 -0500 From: Bryan P. Glennon [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: War files and config info Hi - We have a web app that gets distributed in a war file to a tomcat 4.0x server. One of the things in the war file is a configuration file for the app. This is an XML file that we open as a resource (using getResourceAsStream()) in our main servlet init() method. So far, so good. But, we need a way to override this file so that we can make config changes without redistributing the entire application. If we don't use a war file, we can just put the override file (using the same name) in a directory that is earlier in the class path. But we would like to keep the war file, since it does make distribution a bit easier. Any ideas on how to make this work? FYI, the exact call we use to open the config file is InputStream in = this.getClass().getClassLoader().getResourceAsStream(configFile); One approach to customizing configuration without messing with the WAR file is to use environment entry elements instead. Unlike some suggestions, this one is portable to all J2EE servers, Tomcat 4, and probably other servlet containers as well. The basic idea is that you declare your configuration parameters as env-entry references (with default values) in the web.xml file. For example, in a Payroll webapp you might have: env-entry env-entry-namemaxExemptions/env-entry-name env-entry-value15/env-entry-value env-entry-typejava.lang.Integer/env-entry-type /env-entry In your servlet (or in a JSP or JavaBean referenced by that servlet), you can retrieve this value as follows: InitialContext ic = new InitialContext(); Integer value = (Integer) ic.lookup(java:comp/env/maxExemptions); int maxExemptions = value.intValue(); The reason to go through all of this, though, is that you can override the default value in the server configuration -- for Tomcat 4, you do that in the server.xml file: Context path=/myapp ... ... Environment name=maxExemptions value=20 type=java.lang.Integer/ ... /Context You can define env-entry elements of any of the standard Java primitive types (by using the corresponding wrapper class) or String. If there are more variables than you really want to configure this way, one option would be to create a single String-valued environment entry that is simply the absolute pathname to a properties file somewhere on the host server. TIA, Bryan Craig -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: war files.
dont you need to set the unpackWARs attribute to true on your host in server.xml ? I think so, check out : http://jakarta.apache.org/tomcat/tomcat-4.0-doc/config/host.html hope it helps [EMAIL PROTECTED] -Original Message- From: chad kellerman [mailto:[EMAIL PROTECTED]] Sent: 25. febrúar 2002 18:49 To: [EMAIL PROTECTED] Subject: war files. Happy beginning of the week to everyone, Are there any special configurations that need to be made to the server.xml file or the web.xml file to get war files to work under virtual hosts?? I am getting WebApp: Error 404 error when ever I call the war file. Thanks for the help.. -chad -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Re: war files.
Thanks but, I should have said that I have that set already. I have it set to false. I did not want it to unpack. I did know wether I need something in WEB-INF or anything else. Thanks again -chad On Mon, 25 Feb 2002 18:49:36 - Reynir Hübner [EMAIL PROTECTED] wrote: dont you need to set the unpackWARs attribute to true on your host in server.xml ? I think so, check out : http://jakarta.apache.org/tomcat/tomcat-4.0-doc/config/host.html hope it helps [EMAIL PROTECTED] -Original Message- From: chad kellerman [mailto:[EMAIL PROTECTED]] Sent: 25. febrúar 2002 18:49 To: [EMAIL PROTECTED] Subject: war files. Happy beginning of the week to everyone, Are there any special configurations that need to be made to the server.xml file or the web.xml file to get war files to work under virtual hosts?? I am getting WebApp: Error 404 error when ever I call the war file. Thanks for the help.. -chad -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: war files
Is tomcat running at root? (Hint, if your files are being unpacked as part of Tomcat's execution, then they are owned by the user running Tomcat.) Randy -Original Message- From: chad kellerman [mailto:[EMAIL PROTECTED]] Sent: Friday, February 22, 2002 3:23 PM To: [EMAIL PROTECTED] Subject: war files Good Day, I have virtual hosts configured for tomcat I ran into a problem testing out a war file. Does anyone have any idea why a war file would unpack with the ownership of root when called from the web??? I am on a redhat 6.2 box with tomcat 4 and webapp. Thanks, Chad -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Re: war files
I thought if I was using the webapp module for virtual hosts it would execute as the user that the of the Virtual Host section where the webApp directive is??? For example: VirtualHost jakarta.domain.net User jak Group jakartagrp ServerName jakarta.domain.net ServerAdmin [EMAIL PROTECTED] DocumentRoot /home/jak/jakarta-www TransferLog /home/jak/jakarta-logs/access-log ScriptAlias /cgi-bin/ /home/jak/jakarta-www/cgi-bin/ WebAppConnection conn warp jakarta.gotc.net:8015 WebAppDeploy webapps conn/ /VirtualHost I would think any app executed under this user would have the users permissions?? I must be looking at it wrong. -chad On Fri, 22 Feb 2002 14:39:41 -0500 Randy Layman [EMAIL PROTECTED] wrote: Is tomcat running at root? (Hint, if your files are being unpacked as part of Tomcat's execution, then they are owned by the user running Tomcat.) Randy -Original Message- From: chad kellerman [mailto:[EMAIL PROTECTED]] Sent: Friday, February 22, 2002 3:23 PM To: [EMAIL PROTECTED] Subject: war files Good Day, I have virtual hosts configured for tomcat I ran into a problem testing out a war file. Does anyone have any idea why a war file would unpack with the ownership of root when called from the web??? I am on a redhat 6.2 box with tomcat 4 and webapp. Thanks, Chad -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Re: WAR files (URGENT)
26/11/2001 16:07:53, keiths [EMAIL PROTECTED] wrote: Can you clarify this. I have just tried the following... 1- remove the war file from the webapp dir 2- recreate the war file @jar cvf timeservlet.war * 3atry to intall using manager app from current location /var/tomcat4/, same error : FAIL - Encountered exception java.io.FileNotFoundException: /var/tomcat4/webapps/time/META-INF/MANIFEST.MF (No such file or directory) THE FILE IS IN THE WAR FILE ON THE PATH SHOWN 3b try to install on /var/tomcat/webapps/ Same result. What am I doing wrong... common error is the war file is placed in webapps directory but is not created there. jar cf myapp.war myapp from webapp dir is wrong, jar cf myapp.war * from your application directory, then move the war file up to webapp directory. Alec Bickerton wrote: Hi all, Can someone plz tell me how to install a web app packaged as a WAR file on tomcat 4.0.1 ? I've tried following the instructions in tomcat-docs but when I try them I get a file not foud exception even though all the file in question is in the war file. (With the correct path). I would appreciate any help as This is starting to drive me nuts. thanks in advance Alec. -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- Keith Simpson Skillview Technologies [EMAIL PROTECTED] (603)-382-9882 -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: WAR files (URGENT)
Hi, I did not follow this thread actively, but the error message you get suggests that the file /var/tomcat4/webapps/time/META-INF/MANIFEST.MF is not there or not accessible. Have you checked: - File names (upper/lower case, etc) - file protection? (rwdx, etc) The best way to check is to login as the user under which tomcat is runnig and then perform a jar tf /var/tomcat4/webapps/time/timeservlet.war I also noticed that you talk about webapp dir, where the error message indicates it is looking for a webapps directory (the s is missing) Regards, Cor -Original Message- From: Alec Bickerton [mailto:[EMAIL PROTECTED]] Sent: Monday, November 26, 2001 18:02 To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: WAR files (URGENT) 26/11/2001 16:07:53, keiths [EMAIL PROTECTED] wrote: Can you clarify this. I have just tried the following... 1- remove the war file from the webapp dir 2- recreate the war file @jar cvf timeservlet.war * 3atry to intall using manager app from current location /var/tomcat4/, same error : FAIL - Encountered exception java.io.FileNotFoundException: /var/tomcat4/webapps/time/META-INF/MANIFEST.MF (No such file or directory) THE FILE IS IN THE WAR FILE ON THE PATH SHOWN 3b try to install on /var/tomcat/webapps/ Same result. What am I doing wrong... common error is the war file is placed in webapps directory but is not created there. jar cf myapp.war myapp from webapp dir is wrong, jar cf myapp.war * from your application directory, then move the war file up to webapp directory. Alec Bickerton wrote: Hi all, Can someone plz tell me how to install a web app packaged as a WAR file on tomcat 4.0.1 ? I've tried following the instructions in tomcat-docs but when I try them I get a file not foud exception even though all the file in question is in the war file. (With the correct path). I would appreciate any help as This is starting to drive me nuts. thanks in advance Alec. -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- Keith Simpson Skillview Technologies [EMAIL PROTECTED] (603)-382-9882 -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Re: Newbie question re .war files
Yes, .war files are archives. In fact they use the standard? zip format. So, if Tomcat doesn't open them automatically, you can do it manually with any unzipping program like winzip or gzip. - Richard On Friday 24 August 2001 10:12 am, you wrote: Hi, I'm pretty new to Tomcat and a designer not a developer so sorry if this is a dum one, but... I'm trying to get the Dreamweaver UltraDev TagLib extensions flying with our Tomcat 3.2.1 install. I've added 2 .war files to the $TOMCAT_HOME/webapps dir as per install notes but restarting tomcat doesn't affect them and I can't find (yet) any other info on what I have to do to extract them (they are archives right?). Any help would save me some grey hairs! TIA Jon FYI The whole package is from http://jakarta.apache.org/taglibs/doc/ultradev4-doc/intro.html __ Jon Taylor Creative Director Olive Systems e-mail: [EMAIL PROTECTED] __ visit our site at www.olive.co.uk
Newbie question re .war files
Hi, I'm pretty new to Tomcat and a designer not a developer so sorry if this is a dum one, but... I'm trying to get the Dreamweaver UltraDev TagLib extensions flying with our Tomcat 3.2.1 install. I've added 2 .war files to the $TOMCAT_HOME/webapps dir as per install notes but restarting tomcat doesn't affect them and I can't find (yet) any other info on what I have to do to extract them (they are archives right?). Any help would save me some grey hairs! TIA Jon FYI The whole package is from http://jakarta.apache.org/taglibs/doc/ultradev4-doc/intro.html __ Jon Taylor Creative Director Olive Systems e-mail: [EMAIL PROTECTED] __ visit our site at www.olive.co.uk
Re: Newbie question re '.war' files
I've added 2 .war files to the $TOMCAT_HOME/webapps dir as per install notes but restarting tomcat doesn't affect them and I can't find (yet) any other info on what I have to do to extract them (they are archives right?). Restarting Tomcat should have expanded them into their respectively-named directories. So if you had jon.war and restarted tomcat, there is now a web app named jon, that you can access by requesting http://localhost:8080/jon, providing you've got the default Tomcat setup locally on your machine. - r Any help would save me some grey hairs! TIA Jon FYI The whole package is from http://jakarta.apache.org/taglibs/doc/ultradev4-doc/intro.html __ Jon Taylor Creative Director Olive Systems e-mail: [EMAIL PROTECTED] __ visit our site at www.olive.co.uk
Re: war files. (tomcat 4.0 beta 7)
| I have packaged my web application in a .war file and deployed it using | tomcat 4.0 beta 7. | | perfect. | | The only way I could get it to work was to copy my database jar files into | web-inf\lib, this would make my war file platform dependent as most database | vendors ship different jars for each operating system. | | I tried them in the %CATALINA_HOME%\lib but that did not help. | I think this is the same problem I had with some other jar file. I copied the missing jar file to $CATALINA_HOME/webapps/theAppl/WEB-INF/lib And the application works. Hope it helps. Wei
Re: war files. (tomcat 4.0 beta 7)
James, Stuart at [EMAIL PROTECTED] wrote: I have packaged my web application in a .war file and deployed it using tomcat 4.0 beta 7. perfect. The only way I could get it to work was to copy my database jar files into web-inf\lib, this would make my war file platform dependent as most database vendors ship different jars for each operating system. I tried them in the %CATALINA_HOME%\lib but that did not help. suggestions / recommendations. I _believe_... It's not %CATALINA_HOME%\lib, but %CATALINA_HOME%\common\lib But I might be wrong... Pier
Re: war files. (tomcat 4.0 beta 7)
On Tue, 14 Aug 2001, Pier P. Fumagalli wrote: James, Stuart at [EMAIL PROTECTED] wrote: I have packaged my web application in a .war file and deployed it using tomcat 4.0 beta 7. perfect. The only way I could get it to work was to copy my database jar files into web-inf\lib, this would make my war file platform dependent as most database vendors ship different jars for each operating system. I tried them in the %CATALINA_HOME%\lib but that did not help. suggestions / recommendations. I _believe_... It's not %CATALINA_HOME%\lib, but %CATALINA_HOME%\common\lib No, %CATALINA_HOME%\lib is the right place for JARs that should only be seen by applications. Use %CATALINA_HOME%\common\lib if you want a JAR file visible to both applications *and* Catalina internal classes (which is rarely necessary). Without knowing what the failure symptoms are when you put the JDBC driver files into %CATALINA_HOME%\lib, it's a little hard to debug that did not help. But I might be wrong... Pier Craig
Re: WAR files
Erin Lester wrote: Can anyone point me to some information about creating WAR files. http://jakarta.apache.org/tomcat/tomcat-3.3-doc/appdev/deployment.html Supposedly you can create them with deploytool, but I only know how to do this with the gui version and don't have an x-windows server on the server I'm working on. Very easy. Use Ant: http://jakarta.apache.org/ant/index.html . Ant is the default build tool (like 'make') for Jakarta applications. And take a look at the Tomcat source examples/build.sh and examples/build.xml files to see how Ant builds a WAR file. I've also read that you can use jartool to create WAR files, but the instructions said you will need to create your own version of the deployment descriptor. What does this mean? create my own web.xml? I have a web.xml but don't really use it for much (not all the servlets are in the web.xml). Yup, it means create your own web.xml. Just make sure it is in appname/WEB-INF/. Is there anything special we need to do in the web.xml/deployment descriptor file? Nope. and will a WAR created with the jar tool preserve the directory structure of the application? Yup. -- John Alex Hebert [EMAIL PROTECTED] System Engineer
Re: WAR files and the WEB-INF/lib directory
I don't think you are missing anything. The jar files in your web apps. web-inf/lib directory can not be seen from classes loaded from outside of your web app. Someplace you are probably loading a class that does not have access to the jar files in your web app. --- Tait, Allen [EMAIL PROTECTED] wrote: I am working on a web publishing app and am using Tomcat 3.2.1 with Cocoon. My application is installed by putting the .war file in the tomcat_home/webapps directory and restarting Tomcat. I am finding that any .jar files that I include in the WEB-INF/lib directory are not available to my application. However, if I explicitly include them in the CLASSPATH, when tomcat starts, everything works fine. Is there some configuration that I am missing or is an entry required in the web.xml file to get Tomcat to look at the application's WEB-INF/lib directory? I want to keep some .jars that apply to a particular app out of the global environment. Thanks __ Do You Yahoo!? Make international calls for as low as $.04/minute with Yahoo! Messenger http://phonecard.yahoo.com/
RE: .war files
.war files are "Web ARchive" Files. It's the easiest way of application deployment. I generate them by using JAR command. "jar -cvf test.war ." this command creates a test.war file which consists everything of current directory and following subdirectories. So goto your application directory and by using above command genenrate your application war file and dump it in webapps directory. tomcat when it comes up it generates a directory structure based on this war file(just unjar's this war file). Regds Raghu -Original Message- From: Mary McCarthy [mailto:[EMAIL PROTECTED]] Sent: Friday, January 12, 2001 5:30 PM To: [EMAIL PROTECTED] Subject: .war files hi anyone know how the .war files in the webapps folder generated? Thanks. _ Get your FREE download of MSN Explorer at http://explorer.msn.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: .war files
Mary McCarthy wrote: hi anyone know how the .war files in the webapps folder generated? Thanks. A web application archive (WAR) file is just a JAR file with a particular directory structure (as described in the Servlet Specification at http://java.sun.com/products/servlet/download.html). So, you can use the "jar" utility. For the Tomcat distribution in particular, the WAR files were created with the help of the Ant build tool (http://jakarta.apache.org/ant). You can learn about using Ant to help you create web applications by reading the Application Developer's Guide that is included with Tomcat 3.2.1 -- simply point your browser at file "doc/appdev/index.html" in the Tomcat distribution. Craig McClanahan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]