Thanks to Mark for the response to my initial e-mail on my problem with 
servlets.

I have now followed the TomCat manual and have created a build environment using
ant.

The problem I now have is that I get an exception thown at

           ant install

nd this is associated with "HTTP response code: 401 for URL"

One thing that I did have to do was to change the REALM given in the
conf/server.xml which came with my download of tomcat.
It was Userdatabase, and I changed this to MemoryRealm in order to pick up the
tomcat-users.xml file.  Initially I could not actually activate the "TomCat 
Manager" link
under Administration on the front page. Once I assigned user "tomcat" to have 
the
"manager" role this changed and I can access that link.

In my build.properties file I have set

   manager.username=tomcat
   manager.password=tomcat

I just can't see what is going wrong.

Thanks, again.

Charles

-----------------------------------------------------------------------------------------------------------

COMPILE is OK.

-bash-3.2$ ant all
Buildfile: build.xml
Trying to override old definition of datatype resources

clean:
   [delete] Deleting directory /users/cgillan/Hello/build
   [delete] Deleting directory /users/cgillan/Hello/dist

prepare:
    [mkdir] Created dir: /users/cgillan/Hello/build
    [mkdir] Created dir: /users/cgillan/Hello/build/WEB-INF
    [mkdir] Created dir: /users/cgillan/Hello/build/WEB-INF/classes
     [copy] Copying 3 files to /users/cgillan/Hello/build
     [copy] Copied 1 empty directory to 1 empty directory under 
/users/cgillan/Hello/build

compile:
    [javac] Compiling 1 source file to 
/users/cgillan/Hello/build/WEB-INF/classes

all:

BUILD SUCCESSFUL
Total time: 0 seconds

Try to INSTALL

-bash-3.2$ ant install
Buildfile: build.xml
Trying to override old definition of datatype resources

prepare:

compile:

install:

BUILD FAILED
java.io.IOException: Server returned HTTP response code: 401 for URL: 
http://lawrencium.ecit.qub.ac.uk:8080/manager/deploy?path=%2FHello&war=file%3A%2F%2F%2Fusers%2Fcgillan%2FHello%2Fbuild
        at 
sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1153)
        at 
org.apache.catalina.ant.AbstractCatalinaTask.execute(AbstractCatalinaTask.java:223)
        at org.apache.catalina.ant.DeployTask.execute(DeployTask.java:201)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
        at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at 
org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
        at org.apache.tools.ant.Task.perform(Task.java:348)
        at org.apache.tools.ant.Target.execute(Target.java:357)
        at org.apache.tools.ant.Target.performTasks(Target.java:385)
        at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
        at 
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
        at org.apache.tools.ant.Main.runBuild(Main.java:758)
        at org.apache.tools.ant.Main.startAnt(Main.java:217)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)

Total time: 0 seconds
-bash-3.2$

-------------------------------------------------------------------

Reply via email to