[Geoserver-devel] Questions about deploying geoserver, config, war etc

Hi,

I have some pressing need to get geoserver running with some test data but I am tripping up at the last mile.
I have redhat 8 0.95beta geoserver and recent versions of ant, postgresql (7.3.3), jboss, java etc.

I downloaded 0.95 distro of geoserver and could not find a war file referred to in the user install instructions.

I created a geoserver.war file using ant after looking at the build.xml for the right tag.
I deployed this to my servlet container -jboss and it deployed "successful" but there
was one error message that worried me:
some /tmp/.... file that it could not find/access (I will get the exact path if you want).

In the user install instructions it says to put a configuration.xml file in "your web root" directory
then "geoserve/data".
Well, I am not sure if I know what is meant here. There is a webapps/ROOT directory in
the /usr/local/geoserver/server directory where I have installed geoserver. Is this what is meant?
There is no data directory under it - it is empty.

There is a data directory under geoserver/misc. Is this what are meant by the data dir under web root?

Please also note the install instructions are out of date for postgresql:
it now uses gmake not make.

Further, a minor but I think important point:
The instrcutions for installing postgis say:
"You should place PostGIS in your Postgresql 'contrib' directory and follow the directions for installation there."
There would be less mistakes if it said:
"You should place PostGIS in your Postgresql 'contrib', change to the postgresql directory and follow the directions for installation there."
I tried running mak and make install from the 'contrib' directory and got some confusing results :slight_smile:

regards,

chris

So it looks like I missed a few things the last time I updated the user
installation files. Sorry about that.

I downloaded 0.95 distro of geoserver and could not find a war file
referred to in the user install instructions.

I created a geoserver.war file using ant after looking at the build.xml
for the right tag.

Sorry about not answering that question, it was emailed to the geoserver
list a little while ago, and I thought I had replied to list, but I only
replied to the sender. The answer to the question of 'where is the war?'
Is that it must be created by running 'ant war'. And if you update your
misc/data/featureType directory at all then the command must be run again.

I deployed this to my servlet container -jboss and it deployed
"successful" but there
was one error message that worried me:
some /tmp/.... file that it could not find/access (I will get the exact
path if you want).

Yes, please get me the exact path. It may be a jboss problem, as we have
not tested at all with jboss. If I have some time today I'll try to
download jboss and see if I get the same problem. Tomcat is by far the
most tested servlet container, and we have also successfully tested resin,
though not as extensively.

In the user install instructions it says to put a configuration.xml file
in "your web root" directory
then "geoserve/data".
Well, I am not sure if I know what is meant here. There is a
webapps/ROOT directory in
the /usr/local/geoserver/server directory where I have installed
geoserver. Is this what is meant?

First, I'll tell you what you should do, second I'll tell you what is
meant. The thing to do is just edit the configuration.xml file in
$GEOSERVER_HOME/misc/documents/. When you do 'ant war' this configuration
file will roll into the war, and will put itself in the right place when
placed in the servlet container. What is meant by 'your web root
directory' is the place where you expand the war. In the case of tomcat
it is $CATALINA_HOME/webapps, and I'm pretty sure it's called webapps in
resin too. So you place the geoserver.war in the appropriate place, and
then start up the servlet container, and it will expand to a /geoserver
directory, that will have a /data subdirectory, which is where the
configuration.xml file that you edited in geoserver/misc/documents ends
up. Which is to say that if you would like to edit the configuration
without having to rebuild the war each time then you can just edit that
file directly. You can do the same for the featureTypes in the data
directory. I personally do not recommend it, as I find it better to keep
my geoserver install consistent with the one expanded in the war, in case
you need to rebuild later, so you don't lose any changes you may have made
before.

There is no data directory under it - it is empty.

That directory will actually be expanded if you run 'ant test', which runs
the built-in tomcat, placing all the files in the correct places.

There is a data directory under geoserver/misc. Is this what are meant
by the data dir under web root?

Same as before, you can edit the data in geoserver/misc/data/featureTypes,
and have the changes go into the war. Or you can go to where the war has
expanded, your webapps directory, and edit them there.

Please also note the install instructions are out of date for postgresql:
it now uses gmake not make.

Thanks, I'll change it.

Further, a minor but I think important point:
The instrcutions for installing postgis say:
"You should place PostGIS in your Postgresql 'contrib' directory and
follow the directions for installation there."
There would be less mistakes if it said:
"You should place PostGIS in your Postgresql 'contrib', change to the
postgresql directory and follow the directions for installation there."
I tried running mak and make install from the 'contrib' directory and
got some confusing results :slight_smile:

Sounds good, thanks for the catch.

I'll try to put these updates into the documentation soon, thanks for
emailing to clarify, and I apologize that it is confusing. And let me
know about the /tmp error, and I'll see what I can do as soon as possible.

good luck,

  Chris

Thanks Chris for this - it is very helpful.

now for the dumb questions :slight_smile:

I need to demonstrate Geoserver this (your thursday) to convince the team and our fundung agency
that it is a good thing to use. I have no suitable data and no easy way to get data into the database.
Can we use the sample road/rail data described in the geoserver meta data?
If so, can you please provide the prostgresql scripts and any data required to load the database.?
Note this would also serve to complete the example install instructions as at the moment people like me
do not have a complete example.

thanks,

chris

Chris Holmes wrote:

So it looks like I missed a few things the last time I updated the user 
installation files.  Sorry about that.

  
I downloaded 0.95 distro of geoserver and could not find a war file 
referred to in the user install instructions.

I created a geoserver.war file using ant after looking at the build.xml 
for the right tag.
    
Sorry about not answering that question, it was emailed to the geoserver 
list a little while ago, and I thought I had replied to list, but I only 
replied to the sender.  The answer to the question of 'where is the war?' 
Is that it must be created by running 'ant war'.  And if you update your 
misc/data/featureType directory at all then the command must be run again.

  
I deployed this to my servlet container -jboss and it deployed 
"successful" but there
was one error message that worried me:
some /tmp/.... file that it could not find/access (I will get the exact 
path if you want).
    
Yes, please get me the exact path.  It may be a jboss problem, as we have 
not tested at all with jboss.  If I have some time today I'll try to 
download jboss and see if I get the same problem.  Tomcat is by far the 
most tested servlet container, and we have also successfully tested resin, 
though not as extensively.  

  
In the user install instructions it says to put a configuration.xml file 
in "your web root" directory
then "geoserve/data".
Well, I am not sure if I know what is meant here.  There is  a 
webapps/ROOT directory in
the /usr/local/geoserver/server directory where I have installed 
geoserver.  Is this what is meant?
    
First, I'll tell you what you should do, second I'll tell you what is 
meant.  The thing to do is just edit the configuration.xml file in 
$GEOSERVER_HOME/misc/documents/.  When you do 'ant war' this configuration 
file will roll into the war, and will put itself in the right place when 
placed in the servlet container.  What is meant by 'your web root 
directory' is the place where you expand the war.  In the case of tomcat 
it is $CATALINA_HOME/webapps, and I'm pretty sure it's called webapps in 
resin too.  So you place the geoserver.war in the appropriate place, and 
then start up the servlet container, and it will expand to a /geoserver 
directory, that will have a /data subdirectory, which is where the 
configuration.xml file that you edited in geoserver/misc/documents ends 
up.  Which is to say that if you would like to edit the configuration 
without having to rebuild the war each time then you can just edit that 
file directly.  You can do the same for the featureTypes in the data 
directory.  I personally do not recommend it, as I find it better to keep 
my geoserver install consistent with the one expanded in the war, in case 
you need to rebuild later, so you don't lose any changes you may have made 
before.

  
There is no data directory under it - it is empty.
    
That directory will actually be expanded if you run 'ant test', which runs 
the built-in tomcat, placing all the files in the correct places.

  
There is a data directory under geoserver/misc.  Is this what are meant 
by the data dir under web root?
    
Same as before, you can edit the data in geoserver/misc/data/featureTypes, 
and have the changes go into the war.  Or you can go to where the war has 
expanded, your webapps directory, and edit them there. 

  
Please also note the install instructions are out of date for postgresql:
it now uses gmake not make.
    
Thanks, I'll change it.

  
Further, a minor but I think important point:
The instrcutions for installing postgis say:
"You should place PostGIS in your Postgresql 'contrib' directory and 
follow the directions for installation there."
There would be less mistakes if it said:
"You should place PostGIS in your Postgresql 'contrib', change to the 
postgresql directory and follow the directions for installation there."
I tried running mak and make install from the 'contrib' directory and 
got some confusing results :)
    
Sounds good, thanks for the catch.

I'll try to put these updates into the documentation soon, thanks for 
emailing to clarify, and I apologize that it is confusing.  And let me 
know about the /tmp error, and I'll see what I can do as soon as possible.

good luck,

	Chris

  

Also the link to the schema tutorial(in the install instructions) is broken,
The requested URL /user/schemaTutorial.htm was not found on this server.

chris

The easiest way to get sample data into geoserver is to use shapefiles and
the shp2pgsql utility, part of the postgis install, should be in the
pgsql/bin directory (I think). The US has a lot of freely available
shapefiles from the Census 2000 TIGER/Line Data, available from esri, at
http://www.esri.com/data/download/census2000_tigerline/index.html. I'll
add a section to the online docs about how to do that to the installation
guide. And I'll also send you some sql dumps with schemas of shapefiles
of new york that I've already put into postgis.

  Chris

On Wed, 4 Jun 2003, chris Thorne wrote:

Thanks Chris for this - it is very helpful.

now for the dumb questions :slight_smile:

I need to demonstrate Geoserver this (your thursday) to convince the
team and our fundung agency
that it is a good thing to use. I have no suitable data and no easy way
to get data into the database.
Can we use the sample road/rail data described in the geoserver meta data?
If so, can you please provide the prostgresql scripts and any data
required to load the database.?
Note this would also serve to complete the example install instructions
as at the moment people like me
do not have a complete example.

thanks,

chris

Chris Holmes wrote:

>So it looks like I missed a few things the last time I updated the user
>installation files. Sorry about that.
>
>
>
>>I downloaded 0.95 distro of geoserver and could not find a war file
>>referred to in the user install instructions.
>>
>>I created a geoserver.war file using ant after looking at the build.xml
>>for the right tag.
>>
>>
>Sorry about not answering that question, it was emailed to the geoserver
>list a little while ago, and I thought I had replied to list, but I only
>replied to the sender. The answer to the question of 'where is the war?'
>Is that it must be created by running 'ant war'. And if you update your
>misc/data/featureType directory at all then the command must be run again.
>
>
>
>>I deployed this to my servlet container -jboss and it deployed
>>"successful" but there
>>was one error message that worried me:
>>some /tmp/.... file that it could not find/access (I will get the exact
>>path if you want).
>>
>>
>Yes, please get me the exact path. It may be a jboss problem, as we have
>not tested at all with jboss. If I have some time today I'll try to
>download jboss and see if I get the same problem. Tomcat is by far the
>most tested servlet container, and we have also successfully tested resin,
>though not as extensively.
>
>
>
>>In the user install instructions it says to put a configuration.xml file
>>in "your web root" directory
>>then "geoserve/data".
>>Well, I am not sure if I know what is meant here. There is a
>>webapps/ROOT directory in
>>the /usr/local/geoserver/server directory where I have installed
>>geoserver. Is this what is meant?
>>
>>
>First, I'll tell you what you should do, second I'll tell you what is
>meant. The thing to do is just edit the configuration.xml file in
>$GEOSERVER_HOME/misc/documents/. When you do 'ant war' this configuration
>file will roll into the war, and will put itself in the right place when
>placed in the servlet container. What is meant by 'your web root
>directory' is the place where you expand the war. In the case of tomcat
>it is $CATALINA_HOME/webapps, and I'm pretty sure it's called webapps in
>resin too. So you place the geoserver.war in the appropriate place, and
>then start up the servlet container, and it will expand to a /geoserver
>directory, that will have a /data subdirectory, which is where the
>configuration.xml file that you edited in geoserver/misc/documents ends
>up. Which is to say that if you would like to edit the configuration
>without having to rebuild the war each time then you can just edit that
>file directly. You can do the same for the featureTypes in the data
>directory. I personally do not recommend it, as I find it better to keep
>my geoserver install consistent with the one expanded in the war, in case
>you need to rebuild later, so you don't lose any changes you may have made
>before.
>
>
>
>
>>There is no data directory under it - it is empty.
>>
>>
>That directory will actually be expanded if you run 'ant test', which runs
>the built-in tomcat, placing all the files in the correct places.
>
>
>
>
>>There is a data directory under geoserver/misc. Is this what are meant
>>by the data dir under web root?
>>
>>
>Same as before, you can edit the data in geoserver/misc/data/featureTypes,
>and have the changes go into the war. Or you can go to where the war has
>expanded, your webapps directory, and edit them there.
>
>
>
>>Please also note the install instructions are out of date for postgresql:
>>it now uses gmake not make.
>>
>>
>Thanks, I'll change it.
>
>
>
>>Further, a minor but I think important point:
>>The instrcutions for installing postgis say:
>>"You should place PostGIS in your Postgresql 'contrib' directory and
>>follow the directions for installation there."
>>There would be less mistakes if it said:
>>"You should place PostGIS in your Postgresql 'contrib', change to the
>>postgresql directory and follow the directions for installation there."
>>I tried running mak and make install from the 'contrib' directory and
>>got some confusing results :slight_smile:
>>
>>
>Sounds good, thanks for the catch.
>
>
>I'll try to put these updates into the documentation soon, thanks for
>emailing to clarify, and I apologize that it is confusing. And let me
>know about the /tmp error, and I'll see what I can do as soon as possible.
>
>good luck,
>
> Chris
>
>
>
>