00:10.47 | *** join/#tomcat Dwayne_Hicks (n=elsie@adsl-68-74-64-46.dsl.emhril.ameritech.net) |
00:12.18 | *** join/#tomcat durandal (n=durandal@ppp-70-226-202-235.dsl.spfdil.ameritech.net) |
00:14.58 | durandal | hello; i have built tomcat-6.0.16 on a up-to-date gentoo system running sun-jdk-1.6.0.06 and i'm having a terrible time figuring out how to install a simple webapp |
00:16.27 | durandal | my app (gong-5.0.4S) comes with instructions, but they recommend i use the admin app (which seems to be deprecated) to set up a context pointing at the folder i've put gong into |
00:17.32 | durandal | i've tried adding what i think is an appropriate context tag to conf/context.xml : <Context docBase="/usr/local/gong" path="/gong" /> |
00:17.57 | durandal | and i've tried installing the old admin app per instructions here (http://wiki.apache.org/tomcat/HowTo#head-f50555909547d981d0e2b030323632b26047013e) |
00:18.13 | durandal | i can't get either app to work, however |
00:20.10 | durandal | as a last resort, i've also tried putting the contents of my gong folder into webapps/ROOT/ (after disposing of the old contents to a backup location) |
00:20.32 | MHSL | durandal, so did that work? |
00:20.57 | durandal | nope |
00:21.07 | durandal | it seemed like a bad idea =/ |
00:21.25 | MHSL | durandal, is webapps configured as your default appbase for default host? |
00:21.28 | durandal | one moment, and i can tell you what happened instead... |
00:22.04 | durandal | i have no idea; i started with default configurations from upstream and haven't modified anything except conf/context.xml |
00:22.21 | MHSL | durandal, another thing is, it's best to just use the binary package from tomcat website, it should work without hassle |
00:22.34 | durandal | gong btw is here (http://gong.ust.hk/) and install instructions are here (http://gong.ust.hk/downloads_instructions.html) |
00:22.35 | MHSL | durandal, check your server.xml whether the appbase is pointing to webapps |
00:23.28 | MHSL | durandal, when you said it didn't work, you got 404 or something? |
00:23.40 | MHSL | durandal, also check the log |
00:23.41 | durandal | <Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false"> |
00:24.23 | durandal | i'm working on getting error messages back; i didn't record them as i was trying things the first time through |
00:25.29 | durandal | all i need is to serve this one application, so i'd prefer the simplest configuration that will do so, but obviously priority #1 is getting the app to serve at all... |
00:27.26 | durandal | error message is here: (http://rafb.net/p/k7UG5Z63.html) |
00:28.13 | durandal | that's when i get rid of ROOT/* and put gong/* in ROOT/ |
00:29.37 | durandal | er, new error |
00:29.47 | durandal | i chown'ed to tomcat:tomcat |
00:30.32 | durandal | now i get "The requested resource (/) is not available.", which is not totally strange since there is no index.* page in the folder |
00:31.20 | MHSL | durandal, you put gong in ROOT? it doesn't work that way, you have to put the content of gong into ROOT |
00:31.43 | durandal | i put the content of gong into ROOT |
00:32.02 | MHSL | durandal, so any error? |
00:32.35 | durandal | well, now the 500 error is back - the one i pastebin'ed... |
00:33.01 | MHSL | durandal, it can't read the ROOT directory or it's parent, check the permission |
00:33.07 | MHSL | its* |
00:33.33 | MHSL | durandal, make sure the directory is readable by the user which you used to run tomcat |
00:33.59 | durandal | ROOT is tomcat:tomcat, a+r |
00:34.03 | durandal | so are all its contents |
00:34.32 | MHSL | a+r? isn't it supposed to be ugo? |
00:34.41 | durandal | all |
00:34.48 | durandal | so ugo+r |
00:34.50 | MHSL | durandal, directory is executable? |
00:35.18 | durandal | yes, but nothing in it is; should the contents be +x also? |
00:35.24 | MHSL | durandal, do this chmod -R u=rwX,g=rX,o=rX |
00:35.37 | durandal | webapps, btw, is tomcat:tomcat, ug+rx |
00:35.37 | MHSL | durandal, and ROOT at the back |
00:36.19 | MHSL | durandal, i gtg to office now, will be back later, see u later if you're still online |
00:36.39 | durandal | well, i got 2 404's while tomcat restarted, and now more 500's |
00:36.47 | durandal | okay thanks a lot for your help =) |
01:12.41 | *** join/#tomcat kanai (n=kanai@124.32.114.226) |
01:36.11 | *** join/#tomcat khapa (n=khapa@innovax.com.sg) |
01:36.20 | khapa | durandal still having problem? |
01:43.40 | *** join/#tomcat clajo04_ (n=clajo04_@cpe-72-229-214-63.nyc.res.rr.com) |
02:55.16 | durandal | khapa, yes, i'm still having trouble =( |
03:04.28 | *** join/#tomcat acidjnk (n=have@pD9509C15.dip0.t-ipconnect.de) |
03:11.23 | *** join/#tomcat karstensrage (n=karstens@76.21.8.74) |
03:13.32 | javasucks | it appears my sample "Hello World" application for tomcat fails on the Servlet part. the .jsp way is ok. Servlet = fail. it says: This is the output of a servlet that is part of the Hello, World application. (followed by white space) |
03:14.55 | karstensrage | perhaps your self-fulfilling nick has something to do with it |
03:16.09 | javasucks | karstensrage, i used the file here: http://tomcat.apache.org/tomcat-6.0-doc/appdev/sample/sample.war |
03:17.12 | javasucks | put it into my webapps directory as they wanted me to and the outout of their hello world servlet (source code isn't included in the war, just the .class so i can't really debug) isn't "hello world" |
03:17.38 | javasucks | is this the way it's supposed to be or did i mess up? |
03:17.50 | javasucks | or did they mess up or something else |
03:18.57 | javasucks | their .jsp file seemingly works just fine. just their servlet looks like it might be outputing incorrectly |
03:21.13 | *** join/#tomcat pucko_ (i=andreas@81-234-246-21-o933.tbon.telia.com) |
03:22.26 | javasucks | ok. it's not the fact that i changed classpath i reverted back same output |
03:23.23 | karstensrage | works for me out of the box |
03:23.36 | karstensrage | what do you mean changed the classpath? |
03:23.40 | karstensrage | does tomcat even run? |
03:23.44 | javasucks | yes.. |
03:23.50 | karstensrage | http://localhost:8080 |
03:23.58 | karstensrage | does that show the tomcat startup page? |
03:24.04 | javasucks | http://68.228.81.214:8080/sample |
03:24.30 | javasucks | does clicking the servlet give you "hello!" ? |
03:25.11 | karstensrage | cant seem to get that |
03:25.52 | javasucks | can't get to the sample home page or the "hello!"? |
03:26.57 | karstensrage | This is the output of a servlet that is part of the Hello, World application. |
03:27.02 | karstensrage | thats what I get |
03:27.19 | karstensrage | in the catalina.out are there any errors? |
03:27.33 | javasucks | where's that loctaed? |
03:28.11 | javasucks | are those the ones with dates in the file names? |
03:28.58 | karstensrage | thats the output of the link for the servlet |
03:29.45 | javasucks | so "Hello!" isn't supposed to be on the page? |
03:29.52 | karstensrage | well |
03:29.57 | karstensrage | "This is the output of a servlet that is part of the Hello, World application. " |
03:30.05 | karstensrage | theres a "hello" in there |
03:30.31 | javasucks | what file specifically? i'm in tomcat 6.0/logs |
03:30.38 | karstensrage | catalina.out |
03:31.07 | javasucks | all i see is admin.2008-05-27.log and the like |
03:31.40 | karstensrage | <PROTECTED> |
03:31.53 | karstensrage | if there are a lot of files in there it might be hard to see |
03:32.45 | javasucks | no such file or directory |
03:33.51 | javasucks | i are in windows |
03:34.53 | javasucks | karstensrage, are you getting the "Hello!" when you click your particular machine's version of the servlet ? same as the .jsp link? |
03:35.02 | javasucks | on the page itself or is it blank? |
03:37.22 | javasucks | i guess they munged up their hello world servlet. I view source and there is no "Hello!" just "this is the output of hello world" |
03:37.43 | javasucks | bleh how does one manage to mess up hello world application :/ |
03:38.01 | *** join/#tomcat durandal_ (n=durandal@ppp-70-226-202-235.dsl.spfdil.ameritech.net) |
03:40.53 | karstensrage | i dont get it |
03:40.55 | karstensrage | does it say |
03:41.02 | karstensrage | "This is the output of a servlet that is part of the Hello, World application. " |
03:41.14 | karstensrage | or something completely different? |
03:41.47 | javasucks | it says that with a picture of a messed up cat in the upper left corner |
03:41.58 | javasucks | shouldn't it additionally say "Hello!" as it is a Hello world application? |
03:42.02 | karstensrage | no |
03:42.05 | karstensrage | its working |
03:42.16 | karstensrage | your expectations are off |
03:42.32 | karstensrage | change your nick and love java |
03:42.38 | javasucks | ERGH. hello world that doesn't say "Hello" |
03:42.47 | javasucks | i don't understand why the .jsp page says it |
03:42.50 | javasucks | and the servlet doesn't |
03:42.59 | karstensrage | what does the .jsp say EXACTLY? |
03:43.30 | javasucks | "This is the output of a servlet that is part of the Hello, World application. Hello!" (Hello! on new line and picture of messed up cat) |
03:43.30 | karstensrage | This is the output of a JSP page that is part of the Hello, World application. |
03:43.30 | karstensrage | Hello! |
03:43.38 | karstensrage | right |
03:43.41 | karstensrage | same as I get |
03:43.47 | karstensrage | its not a messed up cat |
03:43.49 | karstensrage | its a "tom" cat |
03:43.59 | javasucks | yes that's what the .jsp page has but why doesn't the servlet have a Hello! message? |
03:44.49 | lyken | cause the class isn't loaded ? |
03:45.03 | javasucks | ARGH |
03:45.18 | javasucks | i'm using tomcat's hello world example app |
03:45.25 | javasucks | here we go again |
03:46.54 | javasucks | http://tomcat.apache.org/tomcat-6.0-doc/appdev/sample/sample.war <----- put that file into my webapps folder. I'm just having a problem with the servlet link not printing "Hello!" as the .jsp page does. Doesn't anyone find it strange that a Helloworld app doesn't print Hello!? |
03:50.12 | javasucks | karstensrage, how are my expectations off in expecting hello world to print hello! :/ |
03:50.33 | javasucks | (based on past experiences with online tutorials in other languages that do hello world apps) |
03:56.58 | lyken | well having a name like yours doesn't really encourage me to help you |
03:57.37 | javasucks | uh huh or you can't help? |
03:58.01 | lyken | getting angry at people in this channel won't help your cause |
03:58.31 | javasucks | committing ad hominems doesn't make things better nor am I angry. just puzzled |
03:59.33 | javasucks | besides, the question wasn't about java language constructs or the like.. the .war file doesn't even come with source |
03:59.51 | javasucks | just a question about their documentation/tutorials/the way things SHOULD work |
04:00.47 | lyken | you really haven't been in java land long :) |
04:01.12 | javasucks | heh they force feed me Java at my school for the entire Information and Computer Science degree |
04:01.14 | lyken | the way you think it should work is the opposite of how it usually does |
04:01.31 | lyken | ive programmed java for a number of years |
04:01.32 | javasucks | hello World should print Good bye? |
04:01.34 | lyken | its a lot better than what it was |
04:02.19 | lyken | is tomcat unpacking the war file? |
04:02.31 | javasucks | i think it is. |
04:03.55 | javasucks | yep. i deleted the sample folder, visited the URL again and magically the sample folder appears once again in the directory |
04:04.06 | javasucks | which i believe is normal |
04:05.34 | lyken | yup |
04:09.03 | javasucks | this is fine. i'll just leave it at "The hello world application that doesn't tell you Hello!" |
04:25.42 | karstensrage | i just checked the source to Hello.java |
04:25.45 | karstensrage | it is working |
04:26.04 | karstensrage | its just a standard servlet |
04:26.15 | karstensrage | the does a bunch of println's to the writer |
04:26.40 | karstensrage | <PROTECTED> |
04:26.40 | karstensrage | <PROTECTED> |
04:27.01 | karstensrage | the source is in webapps/docs/appdev/sample |
04:27.05 | karstensrage | if you have the source |
04:27.24 | karstensrage | so the sample.war is working exactly as it should |
04:27.51 | karstensrage | is using tomcat-6.0.13 |
04:28.16 | karstensrage | and ftr, I LURVE java and Tomcat |
04:28.25 | karstensrage | I dont LURVE OpenAIM atm |
04:30.10 | javasucks | where did you get teh source? |
04:30.11 | karstensrage | that was way more than I wanted to spend on a NON issue |
04:30.17 | karstensrage | ummm |
04:30.21 | karstensrage | tomcat.apache.org |
04:30.29 | javasucks | can you send specific file link? |
04:31.23 | karstensrage | http://www.trieuvan.com/apache/tomcat/tomcat-6/v6.0.16/src/apache-tomcat-6.0.16-src.tar.gz |
04:31.28 | karstensrage | thats a mirror |
04:45.50 | *** join/#tomcat shashi (n=shashi@125.16.213.2) |
05:03.53 | *** join/#tomcat durandal (n=durandal@ppp-70-226-202-235.dsl.spfdil.ameritech.net) |
05:47.47 | *** join/#tomcat peter_12 (n=peter_12@S010600119506b129.gv.shawcable.net) |
06:06.41 | *** join/#tomcat jasonb (i=noneoyer@adsl-66-124-73-250.dsl.sntc01.pacbell.net) |
06:31.07 | *** join/#tomcat kjkoster5489 (n=kjkoster@ip188-184-173-82.adsl2.versatel.nl) |
06:33.23 | *** join/#tomcat bennett_ (n=bennett@adsl-69-110-23-99.dsl.pltn13.pacbell.net) |
06:44.08 | *** join/#tomcat cweagans (i=a867875a@gateway/web/ajax/mibbit.com/x-3faeca6fb49c0191) |
06:46.24 | cweagans | Is there a Tomcat module that will serve subversion repositories? |
06:46.46 | cweagans | (or a Tomcat-based version tracking system?) |
06:46.48 | kjkoster5489 | Doesn't svn work over http? |
06:46.58 | kjkoster5489 | Webdav maybe? |
06:47.05 | kjkoster5489 | Just guessing, really. |
06:47.10 | cweagans | yes, but I have a shared server...I can't install subversion |
06:48.03 | jasonb | Sventon! |
06:48.34 | jasonb | http://www.sventon.org/ |
06:48.47 | cweagans | is that able to do commits? |
06:49.43 | cweagans | hmm....guess not. |
06:49.45 | cweagans | dang. |
06:51.34 | jasonb | "do commits"? |
06:52.45 | cweagans | can you use that applet to commit code to the subversion repository? |
06:53.24 | jasonb | "applet"? Which applet? |
06:53.36 | jasonb | You mean webapp? |
06:53.49 | cweagans | erm....sure? |
06:53.57 | cweagans | whatever you would call sventon |
06:53.57 | jasonb | An applet is something else. |
06:54.02 | jasonb | sventon is a webapp. |
06:54.06 | cweagans | ah |
06:54.06 | cweagans | ok |
06:54.23 | cweagans | me = tomcat noob |
06:54.56 | jasonb | No, sventon cannot itself commit to subversion.. it is used to explore/navigate commits, but can't (itself) commit anything. |
06:55.11 | jasonb | For that, you could use JspWiki.. with the svn back end. |
06:57.03 | cweagans | ok, so I guess what I am really looking for is a tomcat-based subversion "proxy"? something where I can, in a command line, say svn co http://www.mydomainhere.com/tomcat/subversion/branches/mybranchhere |
06:57.10 | jasonb | http://www.jspwiki.org/wiki/SubversionProvider |
06:57.53 | jasonb | Well, that would be mod_dav_svn.. what you're describing there.. And, that's for Apache httpd. |
06:59.04 | cweagans | yeah...I'm looking for the tomcat equivalent (I don't have the permissions to install apache mods) |
06:59.52 | *** join/#tomcat dvayanuMC (n=dvayanu@ppp-88-217-18-14.dynamic.mnet-online.de) |
07:01.48 | jasonb | cweagans: What are you trying to do? Just not run httpd? Why not use svnserve? |
07:02.47 | cweagans | ok: I want to be able to access my subversion repository over the internet. I am running off of a shared webserver, so I can't install apache modules (or subversion for that matter.....I'm running the binary from my home directory) |
07:06.54 | jasonb | You could build and run all of it from your home directory. |
07:07.46 | jasonb | You do not need apache httpd in order to serve up your repository to the internet. Subversion has a built in server named svnserve that can also serve it, and it does a great job. |
07:07.48 | *** join/#tomcat Dwayne_Hicks (n=elsie@adsl-68-74-64-46.dsl.emhril.ameritech.net) |
07:09.42 | cweagans | so how would I access the repositories on a computer other then the server? by ip address? or..... |
07:15.48 | *** join/#tomcat diLLec (n=dillec@dillec.biz) [NETSPLIT VICTIM] |
07:15.48 | *** join/#tomcat minerale (i=35181@about/cooking/alfredo/Minerale) [NETSPLIT VICTIM] |
07:15.48 | *** join/#tomcat teite (i=teite@trough.maeh.org) [NETSPLIT VICTIM] |
07:15.49 | *** join/#tomcat jeef (n=jeff@ifup.us) [NETSPLIT VICTIM] |
07:15.49 | *** join/#tomcat roasten (n=roasten@195.242.55.254) [NETSPLIT VICTIM] |
07:15.49 | *** join/#tomcat jorgenhg (n=jorgenhg@user.skolelinux.no) [NETSPLIT VICTIM] |
07:20.14 | jasonb | cweagans: If you cannot map it to any DNS name, then yes, you could access it by the IP address of the server. |
07:21.00 | cweagans | what do you mean by 'map to any DNS name?' like.....if a domain resolves to that IP? |
07:22.06 | jasonb | Yes, if the server's fully qualified hostname is already in DNS, then you can access the svn repo via a URL having that hostname. |
07:26.00 | *** join/#tomcat vikumar (n=Vimal@nat/redhat-in/x-c7623546d17e684b) |
07:28.51 | *** part/#tomcat cweagans (i=a867875a@gateway/web/ajax/mibbit.com/x-3faeca6fb49c0191) |
08:21.19 | *** join/#tomcat dvayanu (n=dvayanu@host-62-245-224-138.customer.m-online.net) |
08:24.03 | *** join/#tomcat _change (n=_change@195.250.132.186) |
08:37.51 | *** join/#tomcat rnicolas (n=rnicolas@gw-easynet-lvl.smile.fr) |
08:39.37 | *** join/#tomcat rnicolas (n=rnicolas@gw-easynet-lvl.smile.fr) |
08:40.49 | *** join/#tomcat PaulEU (n=pawcioos@ip-091201121126.mikolow.net) |
09:20.04 | *** join/#tomcat Vanuatoo (n=Vanuatoo@host-85-114-227-35.adsl.caucasus.net) |
09:26.35 | PaulEU | hello! I have question: where can I set directory to retrieve logs from host? I don't want use default folder logs in tomcat 5.5.26, OS: Linux, Java: 1.6 |
09:28.20 | PaulEU | I tried add one line between <Host> </Host> like that: <Logger className="org.apache.catalina.logger.FileLogger" directory="logs/user" prefix="user\_log." suffix=".txt" timestamp="true" /> |
09:28.28 | PaulEU | but it doesn't work :/ |
09:29.04 | PaulEU | I read it: http://tomcat.apache.org/tomcat-5.5-doc/logging.html but there isn't exist information how can I change path |
09:30.19 | *** join/#tomcat {Chris} (n=cdupont@abo-44-36-68.mts.modulonet.fr) |
09:34.12 | *** join/#tomcat rnicolas_ (n=rnicolas@gw-easynet-lvl.smile.fr) |
10:00.20 | *** join/#tomcat rnicolas (n=rnicolas@gw-easynet-lvl.smile.fr) |
10:17.18 | *** join/#tomcat kiattikhun (n=chatzill@203.149.15.244) |
10:36.15 | *** join/#tomcat ohsix (i=ohsix@66.220.111.222) |
11:11.38 | kjkoster5489 | directory="..."? |
11:11.48 | kjkoster5489 | PaulEU |
11:12.27 | PaulEU | kjkoster5489: in <Host> ? |
11:12.47 | kjkoster5489 | In conf/logging.properties? |
11:13.19 | PaulEU | I'll try check |
11:17.45 | PaulEU | I don't understand.. in which line? |
11:17.53 | PaulEU | I don't see directory... |
11:18.22 | PaulEU | I have default file from setup |
11:29.36 | PaulEU | I understand that I should change.. |
11:35.14 | PaulEU | kjkoster5489: when user put webapp.war into webapps it create own log, where should I change default path? |
11:37.13 | *** join/#tomcat rnicolas (n=rnicolas@gw-easynet-lvl.smile.fr) |
11:37.58 | *** join/#tomcat rnicolas (n=rnicolas@gw-easynet-lvl.smile.fr) |
11:39.08 | kjkoster5489 | In webapp.war |
11:55.44 | PaulEU | I have problem.. because only root can start service tomcat.. |
11:56.03 | PaulEU | I want that user can delete own logs |
11:56.21 | PaulEU | but it's not possible (permissions root) |
12:04.58 | kjkoster5489 | Unless the rights on the logs dir are rwxrwxrwx and you script the deletion to do the security for you |
12:05.05 | kjkoster5489 | Tricky and insecure, but there it is. |
12:05.14 | kjkoster5489 | Or just give everyone his own Tomcat. :) |
12:05.20 | kjkoster5489 | How many are there? |
12:05.26 | kjkoster5489 | Users, I mean? |
12:05.36 | PaulEU | kjkoster5489: actually I created only one |
12:05.44 | PaulEU | I created user tomcat.tomcat |
12:05.56 | PaulEU | and he starts service.. it works OK |
12:06.21 | PaulEU | next I created user: user1 and he wants see logs own app |
12:07.21 | PaulEU | I've got error in logs |
12:07.30 | PaulEU | java.util.logging.ErrorManager: 4 |
12:08.20 | PaulEU | java.io.FileNotFoundException: /home/services/tomcat/5.5.26/logs/user1/catalina.2008.05.28.log (Permission denied) |
12:10.43 | *** join/#tomcat sveajobb (n=tommy@83.233.28.240) |
12:11.44 | PaulEU | kjkoster5489: I tried create some users.. but there is n't good solution for it |
12:19.27 | kjkoster5489 | Is this a re-packed tomcat, or a stock tomcat from apache. |
12:19.35 | kjkoster5489 | ? |
12:19.49 | PaulEU | its from apache |
12:19.49 | kjkoster5489 | What is the owner of the tomcat dirs? |
12:20.26 | PaulEU | I did set as tomcat |
12:20.38 | kjkoster5489 | And the Tomcat JVM runs as user Tomcat? |
12:20.47 | PaulEU | yes |
12:22.21 | PaulEU | and I want that user user1 can see logs |
12:22.30 | PaulEU | I did symlink: |
12:23.01 | PaulEU | ln -s /home/users/user1/logs /home/services/tomcat/5.5.26/logs/user1 |
12:23.03 | PaulEU | as root |
12:23.22 | PaulEU | I want that user can see logs in own directory |
12:25.34 | PaulEU | in file conf/logging.properties I set: 1catalina.org.apache.juli.FileHandler.directory = ${catalina.base}/logs/user1 and |
12:25.43 | PaulEU | 2localhost.org.apache.juli.FileHandler.directory = ${catalina.base}/logs/user1 |
12:26.29 | PaulEU | in other lines there aren't changed |
12:39.06 | PaulEU | eh, I'll try do it later again.. |
12:39.19 | PaulEU | I must go out.. thanks for advices |
12:50.24 | *** join/#tomcat rnicolas (n=rnicolas@gw-easynet-lvl.smile.fr) |
13:13.01 | *** join/#tomcat clajo04 (n=clajo04@209.sub-75-196-176.myvzw.com) |
13:26.48 | *** join/#tomcat randrewj (n=raj-user@user-160u629.cable.mindspring.com) |
13:49.07 | ph|ber | y0.. anyway around this: Internal error: setAttribute: Non-serializable attribute |
13:55.03 | MHSL | ph|ber, that means just like what it said |
13:55.37 | *** join/#tomcat clajo04 (n=clajo04@32.sub-75-197-174.myvzw.com) |
14:04.20 | *** join/#tomcat peter_12 (n=peter_12@S010600119506b129.gv.shawcable.net) |
14:05.51 | *** join/#tomcat kervel (n=kervel@d5152FE02.access.telenet.be) |
14:06.48 | kervel | hello, in my web app, i'd like to autodetect misconfigured tomcat servers that process URL parameters as ansi instead of UTF-8.. but in order to do this, i would need to find out how the request parameters are processed from inside the web app |
14:06.59 | kervel | the goal is enabling a workaround for misconfigured tomcats automatically |
14:09.29 | kervel | ahh, and i use various tomcat versions on ubuntu hardy, java 1.6, tomcat ranging from 5.5.x to 6.0.14 |
14:10.01 | kervel | most of the tomcat servers are misconfigured wrt parsing url parameters (= default configuration of tomcat) |
14:19.51 | *** join/#tomcat virak_70_smoss (n=virak_70@203.144.95.152) |
14:26.04 | dvayanu | err |
14:26.11 | dvayanu | what do you mean with misconfigured? |
14:35.29 | virak_70_smoss | hi all |
14:35.41 | virak_70_smoss | how can i use jsp code connect to mysql? |
14:35.45 | virak_70_smoss | what should i do? |
14:36.00 | virak_70_smoss | <== New with jsp |
14:36.38 | sveajobb | Hi, I'm having a question regarding jsp. I'm trying from within a jsp-tag call another jsp-tag. but I'm quite lost . anyone can point me in the right direction ? |
14:37.52 | MHSL | virak_70_smoss, search jsp tutorial jdbc on google |
14:38.22 | virak_70_smoss | Ok..thanks MHSL |
14:42.33 | dvayanu | sveajobb: why would you want that? |
14:43.37 | sveajobb | dvayanu, well I have 'code-snippet' which I have moved to a tag, but that 'code-snippet' relies on other jsp-tags |
14:43.59 | dvayanu | sveajobb: be creative :-) |
14:44.22 | dvayanu | or pastebin the sniplet |
14:44.52 | sveajobb | dvayanu, eee.. hehe.. any suggestions ? :) I mean I could just create a object of that type and put all the correct values and calling doStartTag or whatever, but that sounds like an ugly way of doing it ? |
14:45.12 | dvayanu | very ugly indeed |
14:45.36 | dvayanu | http://www.pastebin.org/ |
14:45.38 | sveajobb | well it's nothing more than a few <my:special_tags> that should be called. so not that much to paste really |
14:46.19 | dvayanu | cant you store the results of the first tag in a ... variable? |
14:47.00 | ph|ber | grrr |
14:47.00 | sveajobb | http://www.pastebin.org/39203 |
14:49.04 | dvayanu | too much logic, why dont you prepare everything in controller previously and just iterate over it? |
14:49.37 | dvayanu | with logic:iterate for an instance, or c:forEach |
14:50.16 | *** join/#tomcat randrew1 (n=raj-user@user-160u629.cable.mindspring.com) |
14:50.38 | sveajobb | dvayanu, that is the old jsp. I want to rewrite that and put it all in a simple jsp-tag which will output exactly the same code as the jsp version. simply by calling <my:SelectChannels/> |
14:51.29 | dvayanu | so you want to move the markup into the tag? |
14:51.53 | sveajobb | dvayanu, I guess you could call it a 'module' or a 'widget' |
14:52.08 | sveajobb | dvayanu, the markup AND the logic. I want it to be easily reused |
14:52.16 | dvayanu | i would call it bad design ;-) |
14:52.27 | sveajobb | dvayanu, how come ? |
14:52.49 | dvayanu | moving markup into java code is considered bad design |
14:53.18 | dvayanu | all you need is a bean class and an iterate tag |
14:53.19 | sveajobb | how would you then do if you for instance have a specialized tag which does some background magic , called <input:text> and want to bundle that with a fancy looking design around it. and then reuse it on several parts of your site ? |
14:53.59 | dvayanu | i would work with jsp:include (or whatever jsp fragmentation technique you are using) and include the whole logic |
14:54.07 | dvayanu | controller->bean->jsp |
14:54.35 | sveajobb | I'm not using beans , never looked at it either. |
14:54.57 | dvayanu | bad design :-) |
14:55.22 | dvayanu | you are using model1 which by now should be considered one of the death sins |
14:56.26 | sveajobb | I don't know if I would call <gui:toolTip text="Click here to see information" url="info.jsp"/> would be called bad design even though it returned "<a href=""> + alot of javascript thingies" .. I would call it elegant. |
14:57.09 | dvayanu | http://java.sun.com/developer/technicalArticles/javaserverpages/servlets_jsp/ |
14:58.38 | dvayanu | in your case you should have a controller (servlet or whatever) which iterates your channels and creates a collection of beans, consisting of image, description, and whatever you need in a iteration run, and place it into the request |
14:58.38 | dvayanu | your jsp than just has to iterate over the beans and place the properteis |
14:58.56 | sveajobb | I will check that url out and see if makes any sense :) |
14:59.24 | dvayanu | check the model1 vs, model2 description |
14:59.49 | dvayanu | but you are about to do a reverse scriptlet |
14:59.59 | dvayanu | hmm, markup-let? :-) |
15:01.03 | sveajobb | but creating a collection of beans just for printing out a bunch of images with a few checkboxes.. that seems like too much processing :) |
15:01.32 | dvayanu | a bean is just a class with some properties |
15:01.33 | sveajobb | but how would you then do tags like my <gui:toolTip ...> example up there ? |
15:01.46 | dvayanu | most of it will be generated by the ide anyway |
15:02.01 | sveajobb | the ide? :o I'm using jed man :) |
15:02.34 | dvayanu | well, if the tag just creates a A tag, i mean tag for tag, its ok, but if it creates a whole table with captions and stuff, its to much |
15:03.43 | sveajobb | a A tag? :) |
15:03.50 | sveajobb | what is that. do I need to read the page first? |
15:04.14 | dvayanu | <a> |
15:04.39 | dvayanu | anchor tag |
15:04.42 | sveajobb | aaah.. you mean that :) |
15:04.48 | dvayanu | yes |
15:04.48 | dvayanu | ;-) |
15:04.54 | dvayanu | bo = bolivia? |
15:04.56 | *** join/#tomcat rgsteele||work (n=chatzill@74.94.57.81) |
15:04.59 | sveajobb | well if it creates an anchor tag + image tag + javascript code? |
15:05.41 | dvayanu | if the designer/html producers needs to customize it, does he/she has to change your code? |
15:10.17 | sveajobb | yes, but ofcourse I provide some parameters for customizing it. however I guess the main question is how to reuse code in several places, in a good way. so far I have used jsp-tags for this purpose |
15:11.05 | dvayanu | you know struts html tags? |
15:12.01 | dvayanu | http://struts.apache.org/1.2.x/userGuide/struts-html.html |
15:12.04 | sveajobb | dvayanu, not really. I've only looked into struts while studying, never used it for real. |
15:22.05 | rgsteele||work | Hey folks. I'm using Tomcat 5.5.25, and I can reach it via port 8080 on my webserver. However, when I click on the 'manager' link, I got a 404. I noticed that the webapps that work are in /usr/share/tomcat5/webapps, but the admin, manager, and host-manager directories were in /usr/share/tomcat5/server/webapps. So, I copied the directories from /var/lib/tomcat5/server/webapps to /usr/share/tomc |
15:22.07 | rgsteele||work | at5/webapps, and now I'm getting exceptions like "javax.servlet.ServletException: Wrapper cannot find servlet class org.apache.catalina.manager.HTMLManagerServlet or a class it depends on". Have I zigged where I should have zagged? |
15:25.56 | grantrules | yeah i think they were fine in that directory |
15:26.11 | grantrules | i forgot where it lives, but there's a Context directive that points to that dir iirc |
15:30.17 | dvayanu | under conf/Catalina/localhost |
15:32.43 | ph|ber | anyone use an enterprise SOA? |
15:35.05 | dvayanu | soa as in service oriented architecture? |
15:36.01 | ph|ber | yes.. an enterprise solution .. ie: jboss, websphere |
15:36.02 | ph|ber | etc |
15:36.30 | dvayanu | why is jboss an enterprise solution and ... corba not? |
15:36.50 | ph|ber | i just gave examples. i didnt list every possible one |
15:37.28 | dvayanu | if pojo with corba counts, count me in |
15:37.40 | ph|ber | we are looking for something, ... easy to use, ease of clustering. |
15:38.57 | dvayanu | plain old corba |
15:39.03 | dvayanu | or plain old rmi |
15:39.54 | ph|ber | we are running into non-serializable attribute, with tomcat6 clustering |
15:40.23 | ph|ber | im not a programmer, just the linux admin. |
15:40.29 | ph|ber | so i only handle the system and OS |
15:40.49 | ph|ber | so im not sure if that is code based, and will be that no matter what application server its on. or what. |
15:41.04 | dvayanu | well, it depends strongly on what kind of application you have |
15:41.10 | dvayanu | or what do you do with it |
15:41.13 | dvayanu | or where do you want |
15:41.22 | dvayanu | to get with it at which cost |
15:41.36 | ph|ber | we are willing to spend money. |
15:41.48 | ph|ber | we are a international company. until now have run on tomcat 5.5.15 |
15:41.49 | dvayanu | to give you an example, we have a site with many 10K concurrent users |
15:41.55 | ph|ber | the .26 crashes our app. |
15:42.23 | ph|ber | and we cant cluster bc of the serialized errors |
15:43.10 | dvayanu | 2000-3000 requests per second |
15:43.19 | dvayanu | bc? |
15:43.34 | ph|ber | ? |
15:43.47 | dvayanu | 05:42 ph|ber and we cant cluster bc of the serialized errors |
15:43.51 | ph|ber | we have around 70-80k of users |
15:43.52 | dvayanu | because? |
15:43.55 | ph|ber | oh.. because. |
15:43.56 | ph|ber | yes |
15:44.17 | dvayanu | 70-80K concurrent users? |
15:44.24 | ph|ber | no |
15:44.28 | ph|ber | total. |
15:44.35 | dvayanu | how many online? |
15:44.36 | ph|ber | we have a distributorship. |
15:44.39 | ph|ber | hrm. |
15:44.53 | ph|ber | monday morning, when the cluster went into production we were seeing around 2k |
15:45.06 | ph|ber | we just moved to our "cluster enviroment" |
15:45.06 | dvayanu | how many servers? i assume just one? |
15:45.20 | ph|ber | 2 big ip f5's -> 2 apaches - > 4 tomcats |
15:45.32 | dvayanu | why apache? |
15:45.43 | ph|ber | serves up images, etc. |
15:45.50 | ph|ber | and using mod_jk for the balancing |
15:45.52 | dvayanu | i see but why in front of tomcat? |
15:45.58 | ph|ber | ssl is terminated at f5s |
15:46.04 | dvayanu | you can balance directly with the f5 |
15:46.16 | dvayanu | and make dns or path rules |
15:46.22 | ph|ber | didnt want to go back through the f5s. |
15:46.24 | dvayanu | like s.yourdomain.com for images etc |
15:46.38 | ph|ber | the tomcats then go on to our oracle servers., etc. |
15:46.45 | ph|ber | didnt want all that back through the f5s. |
15:47.04 | ph|ber | its all encrypted, etc.. with ingrian encryption servers |
15:47.14 | dvayanu | but what do you mean with back? puting a httpd infront of tomcat doesnt add any security (in fact it reduces it) |
15:47.40 | dvayanu | where are you located? us or europe? |
15:47.48 | ph|ber | each tomcat has 3 instances of different sites on each. |
15:47.50 | ph|ber | us |
15:47.52 | grantrules | that actually sounds like my company's setup. a bit more hardware, though |
15:48.27 | dvayanu | do you have own developers? |
15:48.34 | ph|ber | so port 80 and 443 come in to f5s, to apaches, then they serve out to tomcats. |
15:48.34 | dvayanu | or outsourcing? |
15:48.36 | ph|ber | yes. |
15:48.38 | ph|ber | own. |
15:48.55 | ph|ber | there are about 300 people in the international headquaters, where im at, |
15:49.01 | ph|ber | from IS to phones, etc |
15:49.06 | ph|ber | distributor help.etc. |
15:49.11 | ph|ber | ever heard of juiceplus? |
15:49.15 | dvayanu | nope |
15:49.19 | dvayanu | i'm from europe |
15:49.23 | ph|ber | dietary suppliment. |
15:49.29 | ph|ber | we have multiple offices there. |
15:49.53 | dvayanu | well, if you have money and smart people, time to move to a 3 tier application i'd say |
15:50.15 | dvayanu | sofar i understand that your tomcat connects directly to the database |
15:50.20 | dvayanu | connect |
15:53.19 | ph|ber | yeop |
15:54.04 | dvayanu | that will kill you in long term |
15:54.16 | ph|ber | we have office in .fr , .au, .it, .dk, .be, .no, .nl, .se |
15:54.18 | ph|ber | etc |
15:54.18 | ph|ber | :> |
15:54.20 | dvayanu | you will need to cluster the db, and there is no such thing as db-clustering |
15:54.22 | ph|ber | .eu |
15:54.30 | ph|ber | there is in oracle |
15:54.40 | ph|ber | .tw, |
15:54.41 | dvayanu | legends and myths :-) |
15:54.51 | dvayanu | it doesnt make the db faster, just more complicated |
15:55.13 | dvayanu | and it forces you to buy needless stuff ;-) |
15:55.19 | *** join/#tomcat SethX (i=wizard@loeblich.linuxteam.at) |
15:55.52 | grantrules | yeah. clustering sucks. we have like $15 mil worth of hardware to run oracle. |
15:56.09 | ph|ber | all our web stuff is on x86. |
15:56.27 | ph|ber | but we have multiple ibm powerpc 5, and pc6 running other stuff |
15:56.59 | dvayanu | phber: but first of all you need to know what are your problems, and than solve them |
15:57.05 | dvayanu | do you have any monitoring |
15:57.17 | dvayanu | application level monitoring |
15:57.29 | ph|ber | hrm.. nagios and munin for server level |
15:57.38 | ph|ber | and nagios just does checking on the site is up. |
15:57.44 | ph|ber | we just purchased jmeter ithink. |
15:57.49 | ph|ber | that would be a programmer question |
15:57.55 | dvayanu | jmeter is free |
15:58.01 | dvayanu | and its not monitoring |
15:58.04 | dvayanu | its loadtesting |
15:58.05 | ph|ber | some j program |
15:58.08 | ph|ber | :> |
15:58.10 | dvayanu | jprobe? |
15:58.17 | ph|ber | hrm. |
15:58.20 | ph|ber | possible. |
15:58.22 | grantrules | jconsole? :P |
15:58.30 | dvayanu | that free too :-) |
15:58.59 | ph|ber | hold, asking my programming manager. |
15:59.20 | ph|ber | jprofiler |
15:59.35 | dvayanu | still, no monitoring :-) |
15:59.56 | ph|ber | so what should we use? |
16:00.01 | ph|ber | i did deploy probe. |
16:00.20 | dvayanu | you mean lambdaprobe? |
16:00.34 | ph|ber | yea |
16:00.42 | dvayanu | a good start |
16:01.30 | dvayanu | http://moskito.anotheria.net/moskitodemo/mui/mskShowAllProducers check this one out |
16:01.47 | dvayanu | but it requires you to actively use it in the production code for best results |
16:03.50 | dvayanu | generally, do you actually know what your problem is? |
16:04.03 | ph|ber | Internal error: setAttribute: Non-serializable attribute |
16:04.04 | ph|ber | java.lang.IllegalArgumentException: setAttribute: Non-serializable attribute at |
16:04.14 | ph|ber | an a whole bunch more. |
16:04.21 | ph|ber | but the programmers are going to look at it. |
16:04.29 | ph|ber | just wondering if there was something i could do.. |
16:04.32 | grantrules | easy solution: |
16:04.37 | grantrules | implements Serializable |
16:04.38 | grantrules | :) |
16:05.57 | dvayanu | let them work |
16:06.08 | ph|ber | ok.. lunch time. |
16:09.15 | vanksi | hey, just a quick question, how did you guys handle the migration from mysql 4 -> 5 when using hibernate for db updates (mainly hibernate.mappings.update) |
16:10.01 | dvayanu | vanksi: not at all |
16:10.36 | vanksi | dvayanu, well didn't you have a problem with the boolean values (mysql 4 is tinyint / mysql 5 is bit) |
16:11.09 | dvayanu | vanksi: we are on tomcat channel, not on mysql channel |
16:11.15 | dvayanu | so frankly, most of us dont care |
16:11.40 | grantrules | isn't bit just an alias for tinyint anyways? |
16:11.44 | grantrules | both work, right? |
16:11.50 | vanksi | dvayanu, well yeah, but i just thought maybe you guys have experienced the same thing, since this has to do with hibernate and such |
16:12.08 | vanksi | grantrules, not quite |
16:12.13 | dvayanu | vanksi: this isnt hibernate channel either :-) |
16:13.29 | vanksi | dvayanu, sorry, this is more along in the lines of an #openbsd channel |
16:13.54 | vanksi | ... anyhow, all my questions are related to tomcat |
16:15.17 | grantrules | well by that logic, everything's related to tomcat |
16:15.36 | grantrules | i use tomcat. i also like bikes! can anyone recommend a good wheelset? |
16:15.51 | dvayanu | vanksi: feel free to ask, but chances to get an answer are greater elsewhere |
16:16.45 | grantrules | arg. some communist upgraded my tomcat dev instance without asking me first and reset my server.xml :( |
16:18.32 | dvayanu | time to go home :-) |
16:18.36 | dvayanu | good luck anybody |
16:30.19 | *** join/#tomcat SethX (i=wizard@loeblich.linuxteam.at) |
16:32.43 | *** join/#tomcat jasonb (n=jasonb@75.144.23.117) |
16:38.50 | *** join/#tomcat DB42 (n=wy@bzq-219-142-146.static.bezeqint.net) |
16:39.04 | DB42 | hi, when handling stuff like 404 in <error-page> can i somehow get the original error message? |
16:45.22 | *** join/#tomcat PaulEU (n=PaulEU@ip-091201121126.mikolow.net) |
16:45.39 | PaulEU | hello |
16:45.46 | PaulEU | I have still problems :( |
16:45.57 | *** join/#tomcat _change (n=_change@195.250.132.186) |
16:46.30 | PaulEU | I'm using 5.5.26 from binary package. System is Linux, java is 1.6. |
16:47.00 | PaulEU | I decompressed tomcat.tar.gz, next set all files as tomcat.tomcat user and groups |
16:47.54 | *** join/#tomcat Infinito_ (n=yingyang@200-140-154-221.gnace701.dsl.brasiltelecom.net.br) |
16:48.04 | PaulEU | I did put symlink from user root to user1 like that: ln -s /home/user1/webapps /opt/tomcat/webapps/user1 |
16:48.57 | PaulEU | user1's dir webapps has the same permissions as tomcat (tomcat.tomcat) with chmod 777 |
16:49.51 | PaulEU | when I started service tomcat via ./startup.sh I see that user tomcat can't open dir catalina/webapps/user1 question why? |
16:51.30 | grantrules | does tomcat have permission to read in /home/user1? |
16:51.42 | PaulEU | no |
16:52.00 | PaulEU | because user user1 has permission: user1.group |
16:52.37 | grantrules | well, if it can't access the parent directory, it won't be able to access that directory. right? |
16:52.50 | PaulEU | but this user is in group tomcat |
16:53.52 | PaulEU | and why it doesn't see it? It must be in the same uid and gid? |
16:54.14 | PaulEU | is it possible that user has other uid.gid in tomcat? |
16:54.58 | ph|ber | back |
16:55.24 | grantrules | uhg. fuck javascript. |
16:59.33 | PaulEU | grantrules: can you help me? |
17:01.14 | randrew1 | PaulEU: If you're clear about the user that owns the tomcat process, then you could su to that user and see if the target dir is accessible. |
17:01.25 | DB42 | hi, when handling stuff like 404 in <error-page> can i somehow get the original error message? |
17:03.38 | PaulEU | randrew1: this user can't access to dir: /home/user1 |
17:04.08 | rgsteele||work | grantrules: A Context directive in the tomcat5.conf? |
17:04.10 | PaulEU | randrew1: how can I set it? I want that tomcat.tomcat starts service.. user has only one dir |
17:04.34 | rgsteele||work | (Sorry, had to step away for a bit) |
17:04.39 | *** join/#tomcat acidjnk (n=have@pD9509053.dip0.t-ipconnect.de) |
17:05.34 | PaulEU | is it possible that user tomcat can access to user with user1.tomcat ? |
17:05.59 | grantrules | rgsteele||work: i dunno what tomcat5.conf is |
17:06.00 | grantrules | 11:26 < dvayanu> under conf/Catalina/localhost |
17:06.00 | PaulEU | I say that user tomcat has group tomcat and group user1 |
17:07.26 | grantrules | aaaaaaaaaauhg |
17:07.51 | PaulEU | so that: user1 has groups: users,tomcat. User tomcat has groups: tomcat,users |
17:08.27 | grantrules | if the home directories are owned by the group tomcat or users and has read permissions, you should be fine |
17:09.32 | PaulEU | but why user tomcat can't visible dir ? |
17:10.22 | grantrules | what? |
17:10.42 | grantrules | if the tomcat user can't see the dir, it doesn't have the correct permissions |
17:16.22 | rgsteele||work | grantrules: Eh, I suppose I can figure out which config file it is, but I suppose the 'zig' where I should have 'zagged' is copying the admin, manager, and host-manager from $TOMCAT_ROOT/server/webapps to $TOMCAT_ROOT/webapps? |
17:16.58 | grantrules | yeah you didn't need to do that afaik |
17:17.11 | rgsteele||work | After the copy, I got a 500, but before it I was getting 404's. So, there must be some place where I can tell it where those apps live. |
17:19.15 | PaulEU | grantrules: now I fix it, I put package.war but it doesn't deployed :/ |
17:19.30 | PaulEU | there is nothing in logs |
17:19.44 | PaulEU | user tomcat can read dir /home/user1/webapps |
17:19.50 | PaulEU | and put |
17:20.23 | grantrules | extract the war to /home/user1/webapps/ |
17:21.24 | grantrules | the only wars that would get deployed would be things directly in /opt/tomcat/webapps/ |
17:21.30 | *** join/#tomcat Quiddity (n=steve@ng1.cptxoffice.net) |
17:21.31 | grantrules | your wars are in /opt/tomcat/webapps/user1/ |
17:21.45 | grantrules | that won't get deployed |
17:22.49 | PaulEU | grantrules: but: I did one fixation: in server.xml I changed: <Host appBase="webapps/user1" |
17:22.55 | PaulEU | and I see that it deployed |
17:23.02 | grantrules | right |
17:23.06 | grantrules | because you're changing the appbase |
17:23.07 | *** join/#tomcat Nicke (n=niclasa@ua-83-227-140-135.cust.bredbandsbolaget.se) |
17:23.14 | grantrules | .. |
17:24.30 | PaulEU | grantrules: is it possible to have some appBase on one host ? |
17:24.37 | grantrules | ? |
17:24.42 | PaulEU | because nobody know about it |
17:24.48 | grantrules | i don't know what you're asking |
17:25.35 | PaulEU | I want in server.xml one <Host> with some appBase dirs |
17:25.47 | grantrules | you can't |
17:25.56 | grantrules | you can specify multiple contexts like i said yesterday |
17:26.02 | grantrules | that point to specific places |
17:26.16 | PaulEU | grantrules: but I tried and it doesn't work :( |
17:26.24 | grantrules | because you were doing it wrong |
17:26.58 | PaulEU | I want that in tomcat/webapps dirs like that: user1 (symlink to user1 dir), user2 (symlink to user2 dir) |
17:27.09 | grantrules | i know. |
17:27.14 | grantrules | i get what you're trying to do |
17:27.29 | PaulEU | grantrules: I've wait long time and nobody write here eh |
17:27.36 | grantrules | what the fuck are you talking about? |
17:27.40 | grantrules | i've given you a bunch of solutions |
17:27.50 | PaulEU | hm |
17:28.03 | PaulEU | you saw that it doesn't work ;) |
17:28.10 | PaulEU | it didn't work |
17:28.12 | grantrules | because you're DOING IT WRONG |
17:28.24 | PaulEU | maybe yes |
17:28.26 | grantrules | i tell you what you need to fix but you ignore me |
17:28.49 | grantrules | i give up |
17:28.53 | PaulEU | :( I'm sorry maybe I misunderstand you |
17:29.20 | PaulEU | misunderstood |
17:32.04 | PaulEU | I'll read logs from yesterday and I'll try do it again later.. |
17:34.05 | *** join/#tomcat gregor_k (n=a@stgt-4dbe0595.pool.einsundeins.de) |
17:35.30 | *** join/#tomcat maier (n=maier@p14-59.med.unc.edu) |
17:37.01 | *** join/#tomcat zencyl (n=eric@158.135.138.107) |
17:53.37 | *** join/#tomcat peter_12 (n=peter_12@S010600119506b129.gv.shawcable.net) |
18:23.32 | DB42 | when handling stuff like 404 in <error-page> can i somehow get the original error message? and can i auto make an global error page for my site ? |
18:26.21 | *** join/#tomcat tieTYT2 (n=none@216.174.112.81) |
18:26.29 | tieTYT2 | my common/classes has a log4j.properties file in there |
18:26.34 | tieTYT2 | i'm using 5.5.17 |
18:26.38 | tieTYT2 | is that supposed to be there? |
18:26.48 | tieTYT2 | i'm getting double log4j messages, that's why i care |
18:26.58 | grantrules | what happens if you remove it? :P |
18:27.21 | tieTYT2 | lets see :) |
18:28.00 | tieTYT2 | i get a warning that it couldn't find appenders |
18:28.03 | tieTYT2 | maybe this is there |
18:28.20 | tieTYT2 | i mean should be here. but my boss modified the original |
18:28.25 | grantrules | that shouldn't matter, afaik |
18:28.54 | grantrules | DB42: probably there's something in request/response. check those |
18:28.59 | tieTYT2 | why not? |
18:29.09 | DB42 | grantrules: i'm talking about web.xml for like all web responses not 200 |
18:29.15 | grantrules | ? |
18:29.17 | DB42 | like all the 4xx and 5xx |
18:29.24 | DB42 | i want to auto handle them all in a single error.jsp |
18:29.29 | grantrules | what's wrong with error-page? |
18:29.46 | DB42 | i can only define one per error-page, no ? |
18:30.18 | grantrules | didn't i answer you yesterday? |
18:30.25 | grantrules | i remember this same question |
18:31.15 | tieTYT2 | hm |
18:31.18 | DB42 | yeah it wasn't helpfull |
18:31.24 | DB42 | you said you can do error-page with just location, but you can't |
18:31.26 | tieTYT2 | i think that tomcat is ONLY using this log4j.properties |
18:33.41 | grantrules | DB42: well how many errors are you going to have besides 404 and 500 or whatever |
18:33.52 | DB42 | dunno, how many http errors ar ethere or whatever ? |
18:33.58 | *** join/#tomcat kshitij (n=kshitij@proxy.iiit.ac.in) |
18:34.09 | grantrules | maybe like 50 |
18:35.13 | DB42 | so.. how cani handle them all.. |
18:35.47 | *** join/#tomcat markl__ (n=mark@c-24-10-191-137.hsd1.ut.comcast.net) |
18:36.16 | tieTYT2 | ok i have a big jar with dependencies in it in shared/lib My log4j.properties is in a jar inside a webapp though |
18:36.23 | tieTYT2 | will that setup cause problems? |
18:37.32 | tieTYT2 | for example, could the jars I depend on try to log before the webapp's log4j.properties has been loaded? |
18:37.36 | DB42 | in a global way... |
18:37.39 | grantrules | DB42: i'd just set one up for 404 and one for java.lang.Throwable |
18:37.48 | DB42 | for 500 ? |
18:37.53 | grantrules | sure |
18:38.24 | DB42 | blah, k, maybe i'll look at a code of a commerical product |
18:39.15 | DB42 | tommorow i present my webapp :) |
18:39.40 | grantrules | to who? |
18:41.15 | DB42 | my instructor |
18:41.25 | grantrules | then why even worry about error messages? |
18:41.32 | grantrules | you should be handling exceptions |
18:41.42 | DB42 | i am |
18:41.45 | grantrules | and why would you have a 404 or whatever if it's just going to your instructor |
18:41.51 | DB42 | but stuff like htpp error msgs is important as well |
18:41.59 | grantrules | why? |
18:42.00 | DB42 | cause its a requirment |
18:42.04 | grantrules | weird |
18:42.33 | grantrules | i'd just cover 404. usually takes a bit of work to get anything besides that |
18:47.53 | *** join/#tomcat Dwayne_Hicks (n=elsie@adsl-68-74-64-46.dsl.emhril.ameritech.net) |
18:59.33 | *** join/#tomcat randrewj (n=raj-user@user-160u629.cable.mindspring.com) |
19:00.35 | *** join/#tomcat ethermeme (n=davistv@209.173.132.12) |
19:06.26 | ethermeme | Hi everyone. Is there some kind of gotcha to using a JDBC realm with mod_proxy_ajp? Apache is forwarding requests to Tomcat properly, but j_security_check isn't getting invoked for some reason. |
19:08.35 | ethermeme | Do I have to do something special to the Connector? |
19:12.50 | ethermeme | Would putting some config in a pastebin help? |
19:21.31 | jasonb | Which connector you use isn't really related to internal container managed security. |
19:22.08 | jasonb | You can verify that by requesting the resource from Tomcat directly over the JIO connector (which is much faster, by the way). |
19:25.28 | *** part/#tomcat tieTYT2 (n=none@216.174.112.81) |
19:32.55 | *** join/#tomcat yassine (n=yassine@unaffiliated/yassine) |
19:35.10 | ethermeme | Ok, maybe it's my rewrite rules. |
19:36.59 | ph|ber | any ideas why mod_jk wouldnt work? |
19:37.14 | ph|ber | my app is deployed, its listening on the port. but the mod_jk log says : |
19:37.21 | ph|ber | Wed May 28 14:36:55 2008] [error] ajp_service::jk_ajp_common.c (1758): Error connecting to tomcat. Tomcat is probably not started or is listening on the wrong port. worker=nsaodev failed |
19:37.27 | *** join/#tomcat kshitij (n=kshitij@proxy.iiit.ac.in) |
19:37.36 | ph|ber | but i can use the http port and it works, and the port is open and listening |
19:38.07 | kshitij | hi, i'm new to konversation, i'm having some problems with java servlets |
19:38.17 | kshitij | can anyone help me please |
19:38.33 | grantrules | just ask |
19:40.53 | kshitij | the example codes of java servlets in the /srv/www/tomcat55/base/webapps/jsp-examples are working fine |
19:41.01 | kshitij | but when i write a new code |
19:41.07 | kshitij | its not working |
19:41.49 | grantrules | you're gonna have to be a bit more specific than that |
19:42.32 | kshitij | the servlet codes that come default as examples in the localhost folder are working fine |
19:42.37 | grantrules | yeah i get that |
19:42.42 | grantrules | you can't just say "not working" |
19:42.49 | kshitij | ohh sry |
19:42.51 | grantrules | gonna have to be more specific on that part |
19:43.07 | kshitij | type Status report |
19:43.07 | kshitij | message /jsp-examples/HelloWorldExample |
19:43.08 | kshitij | description The requested resource (/jsp-examples/HelloWorldExample) is not available. |
19:43.34 | kshitij | this is the error message i get on the browser |
19:44.01 | kshitij | the code is a simple servlet code for printing hello world on the browser |
19:44.49 | grantrules | what are you changing? |
19:45.34 | kshitij | added a servlet in web.xml |
19:45.48 | grantrules | how? |
19:47.23 | kshitij | <PROTECTED> |
19:47.27 | kshitij | <PROTECTED> |
19:47.31 | kshitij | <PROTECTED> |
19:47.31 | kshitij | <PROTECTED> |
19:47.31 | kshitij | <PROTECTED> |
19:47.31 | kshitij | <PROTECTED> |
19:47.31 | kshitij | <PROTECTED> |
19:47.32 | kshitij | <PROTECTED> |
19:47.34 | kshitij | added these lines in web.xml |
19:48.02 | grantrules | that's it? |
19:48.20 | grantrules | you just added a map. what's it mapping to? |
19:48.59 | kshitij | maps to any new servlet created |
19:49.10 | kshitij | i've no further idea about it |
19:49.12 | kshitij | :| |
19:49.24 | grantrules | maybe you should read up on this |
19:49.59 | kshitij | the tutorials ask me to make some changes in /var/tomcat55 folder |
19:50.04 | kshitij | but when i installed tomcat |
19:50.09 | kshitij | no such folder was created |
19:50.15 | kshitij | i tried reading |
19:50.24 | grantrules | well you created the mapping |
19:50.30 | grantrules | now you just need to define the servlet for that name |
19:50.30 | kshitij | could you please give me some link which i could just follow |
19:50.48 | kshitij | yes i did that |
19:50.54 | grantrules | where? |
19:51.03 | kshitij | import javax.servlet.*; |
19:51.07 | kshitij | import javax.servlet.http.*; |
19:51.11 | kshitij | public class servletToJsp extends HttpServlet { |
19:51.14 | grantrules | oh dear god |
19:51.15 | kshitij | <PROTECTED> |
19:51.16 | grantrules | don't paste stuff in here |
19:51.19 | kshitij | <PROTECTED> |
19:51.23 | kshitij | <PROTECTED> |
19:51.35 | kshitij | <PROTECTED> |
19:51.39 | kshitij | <PROTECTED> |
19:51.43 | kshitij | <PROTECTED> |
19:51.47 | kshitij | <PROTECTED> |
19:51.51 | kshitij | <PROTECTED> |
19:51.51 | kshitij | <PROTECTED> |
19:51.51 | kshitij | <PROTECTED> |
19:51.51 | kshitij | } |
19:51.51 | kshitij | in the classes folder |
19:52.08 | kshitij | ohh sry |
19:52.11 | grantrules | that's not what i was talking about at all |
19:52.18 | grantrules | and if you're going to paste code, do it somewhere like pastebin.ca |
19:52.25 | kshitij | okk |
19:52.57 | grantrules | <servlet><servlet-name>servletToJsp</servlet-name><servlet-class>fully.qualified.class.NameServlet</servlet-class></servlet> |
19:53.01 | grantrules | in your web.xml |
19:58.00 | kshitij | I did that |
19:58.05 | kshitij | the same error again |
19:58.10 | grantrules | did you change the class name? |
20:00.01 | kshitij | the servlet iand the classname are the same in this case right? |
20:00.42 | grantrules | eh? |
20:06.41 | *** join/#tomcat slak (n=fube@ool-4b7faf03.static.optonline.net) |
20:06.46 | slak | hi guys |
20:06.54 | slak | i implmented tomcat native apr library on my box |
20:07.09 | slak | and now im getting a ton of random faultString: java.io.IOException: Socket read failed |
20:07.13 | slak | faultActor: |
20:07.15 | slak | faultNode: |
20:07.18 | slak | faultDetail: {http://xml.apache.org/axis/}stackTrace: java.io.IOException: Socket read failed |
20:07.24 | slak | if i take it out and reload the app server, problem is fixed |
20:07.45 | slak | when the exception hits the browser posts a 503 |
20:07.49 | slak | from apache |
20:08.49 | kshitij | and there are 2 web.xml files, one in /etc/tomcat55 and the other in /srv/www |
20:08.55 | kshitij | which one do i make changes in? |
20:13.25 | DB42 | split("\\s+") removes all whitespaces? |
20:20.44 | slak | wow this channel is real helpful :P |
20:21.26 | zencyl | slak: did you not read the slow motion channel part? |
20:21.49 | grantrules | yeah, if you want quick help, feel free to hire me as a consultant!! otherwise i'm going to put my real job first! |
20:22.10 | slak | mutlitask people! |
20:22.32 | slak | having a serious issue over here! |
20:22.39 | slak | ;) |
20:24.04 | DB42 | yeah, paying usually gets a quicker response |
20:25.28 | *** join/#tomcat bobbytech (n=bobbytec@CPE001cf0f5f5eb-CM001a6680c26c.cpe.net.cable.rogers.com) |
20:25.32 | bobbytech | How can I set a password on a tomcat web app dir, but still allow tomcat manager requests to go through? |
20:25.58 | slak | bobby: you have to pay for that kind of help |
20:26.08 | slak | your hard american bux |
20:26.15 | slak | (or euros) |
20:26.26 | bobbytech | but I'm canadian :( |
20:26.43 | slak | there's no help in this channel |
20:26.50 | slak | i have to save up and pay |
20:27.33 | slak | bobby what do you mean by passwrd |
20:27.43 | bobbytech | basic authentication |
20:27.45 | slak | at what point would you be prompted for this password |
20:27.52 | slak | in the webbrowser? |
20:27.55 | bobbytech | yes |
20:28.11 | bobbytech | the directory auth is working fine |
20:28.16 | slak | and basic apache http auth isnt working for your case? |
20:28.23 | bobbytech | it's when I try to open it up for tomcat manager I run into issues |
20:28.48 | slak | what are the issues |
20:29.00 | slak | i guess this is more or a apache httpd question |
20:29.06 | slak | s/or/of |
20:29.31 | bobbytech | probably |
20:29.47 | slak | you can exclude /manager |
20:29.54 | bobbytech | how? |
20:29.56 | slak | in your apache config |
20:30.08 | bobbytech | I have this: |
20:30.09 | bobbytech | <Directory "/home/web/tomcat/webapps/www.linkory.capitalit.com/ROOT"> |
20:30.55 | bobbytech | er, http://pastebin.com/m572473dc |
20:31.07 | bobbytech | ugh, sorry |
20:31.43 | slak | well i dont understand how that would work over ajp connector |
20:31.44 | bobbytech | http://pastebin.com/m63f36577 |
20:32.35 | bobbytech | so, I'm trying to get /manager/html/ to be allowed |
20:32.37 | slak | how does httpd know that its hitting that directory when you use mod_jk or modproxy to communicate with the tomcat app server over :8009 |
20:33.11 | bobbytech | All the ajp stuff works fine |
20:33.21 | bobbytech | It's the directory conf that's the problem |
20:33.30 | bobbytech | if I comment it out, everything works |
20:33.47 | slak | there is basic authentication in tomcat |
20:33.51 | slak | i suggest you use that insgead |
20:33.55 | slak | instead of the httpd |
20:33.57 | bobbytech | if it's in, it just keeps prompting me for apache, then tomcat manager, then apache, then fail |
20:34.41 | slak | http://www.onjava.com/pub/a/onjava/2003/06/25/tomcat_tips.html |
20:34.44 | slak | check out section 5 |
20:36.35 | bobbytech | Yeah, well this is a staging site where keeping this configuration seperate from the app itself is more ideal |
20:36.50 | slak | i understand |
20:36.58 | bobbytech | this allows the the web app configuration to be independent of the environment |
20:37.09 | slak | unfortunately i dont know how that would work, doesnt make sense to me over ajp connector |
20:37.23 | slak | goodluck |
20:37.31 | bobbytech | thanks for your help :) |
20:37.50 | slak | see if you can use httpd auth on <Location> |
20:38.01 | slak | <Directory> just doesnt seem to matter here |
20:38.11 | bobbytech | I'm finding the apache documentation hard to understand |
20:38.22 | slak | #httpd is a good place |
20:38.27 | slak | much more active than this channel |
20:40.57 | *** join/#tomcat Quiddity (n=steve@ng1.cptxoffice.net) |
20:56.45 | randrewj | bobbytech: slak is right. |
21:00.34 | randrewj | bobbytech: It's strange to set DocumentRoot to what looks like your WebApp Context directory. If you jkmount the uris, then the app does not need to be DocumentRoot. (There can be esoteric reasons for doing that kind of config.) Anyway, httpd won't be able to properly associate the Directory restriction with requests handled by tomcat. |
21:11.43 | bobbytech | randrewj: I need that for the static content in the web app |
21:11.57 | bobbytech | The dynamic pages are jk mounted |
21:13.40 | bobbytech | Does this not make sense? |
21:16.44 | bobbytech | httpd is empty! |
21:18.58 | bobbytech | ugh... this is killing me |
21:19.12 | bobbytech | Is there no authoratative place I can look to for this info? |
21:23.31 | slak | #httpd :) |
21:25.47 | *** join/#tomcat maier (n=maier@cpe-065-190-201-155.nc.res.rr.com) |
21:29.04 | bobbytech | randrewj: you still around? |
21:32.07 | randrewj | bobbytech: tomcat can serve both the static and dynamic content. |
21:32.47 | randrewj | bobbytech: it's tricky to do otherwise, esp if you are trying to use auth. |
21:33.04 | randrewj | bobbytech: rarely worth it. |
21:33.09 | *** part/#tomcat randrewj (n=raj-user@user-160u629.cable.mindspring.com) |
21:39.42 | *** join/#tomcat Dwayne_Hicks (n=elsie@adsl-68-74-64-46.dsl.emhril.ameritech.net) |
21:41.26 | *** join/#tomcat balla (n=balla@adsl-ull-103-28.51-151.net24.it) |
21:41.38 | *** part/#tomcat bobbytech (n=bobbytec@CPE001cf0f5f5eb-CM001a6680c26c.cpe.net.cable.rogers.com) |
22:15.12 | *** join/#tomcat Andy_More (n=chatzill@91.98.6.235) |
22:17.41 | *** join/#tomcat dvayanu (n=dvayanu@ppp-88-217-18-14.dynamic.mnet-online.de) |
22:55.44 | *** join/#tomcat victori_ (n=victori@cpe-75-80-141-237.san.res.rr.com) |
22:59.22 | *** join/#tomcat peter_12 (n=peter_12@S010600119506b129.gv.shawcable.net) |
22:59.55 | peter_12 | I have a subclass of HttpServlet and when I call getServletContext() I am getting a null pointer exception |
23:00.10 | peter_12 | javax.servlet.GenericServlet.getServletContext(GenericServlet.java:160) |
23:10.09 | *** join/#tomcat yassine (n=yassine@p54BB478A.dip.t-dialin.net) |
23:33.34 | *** join/#tomcat lyken_ (n=dc@majesticgecko.com) |