[GeoNetwork-users] Conection Postgres and Geoserver port's configuration

Good Morning/afternoon/night,

I'm doing a final work master's degree about Geonetwork. I modified *
config.xml* in (C:\Archivos de programa\Apache Software
Foundation\Tomcat5.5\webapps\geonetwork\WEB-INF)

In order to try to configured Postgresql conection but I Can’t. Paste de
code:

<resources>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- mckoi standalone -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="true">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>BayACrsQ</user>

                                               <password>Qf7Po9T0</password>

<driver>com.mckoi.JDBCDriver</driver>

<url>jdbc:mckoi://localhost:9157/</url>

                                               <poolSize>10</poolSize>

                                   </config>

                        <activator
class="org.fao.geonet.activators.McKoiActivator"><configFile>WEB-INF/db/db.conf</configFile></activator></resource>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- mysql -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="false">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>admin</user>

                                               <password>admin</password>

<driver>com.mysql.jdbc.Driver</driver>

<url>jdbc:mysql://$WEBSERVER_HOST/geonetwork</url>

                                               <poolSize>10</poolSize>

<reconnectTime>3600</reconnectTime>

                                   </config>

                        </resource>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- oracle -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="false">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>admin</user>

                                               <password>admin</password>

<driver>oracle.jdbc.driver.OracleDriver</driver>

                                               <url>jdbc:oracle:thin:@IP
:1521:fs</url>

                                               <poolSize>10</poolSize>

                                   </config>

                        </resource>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- postgresql -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="true">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>postgres</user>

<password>artemisia</password>

<driver>org.postgresql.Driver</driver>

<!--

jdbc:postgresql:database

jdbc:postgresql://host/database

jdbc:postgresql://host:port/database

                                               -->

                <url>jdbc:postgresql:geonetwork</url>

                                               <poolSize>10</poolSize>

                                    </config>

                        </resource>

                <!-- - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - -->

                        <!-- sqlserver 2008 -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="false">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>www-data</user>

                                               <password>www-data</password>

<driver>com.microsoft.sqlserver.jdbc.SQLServerDriver</driver>

<url>jdbc:sqlserver://SERVER;database=geonetwork;integratedSecurity=false;</url>

                                               <poolSize>10</poolSize>

                                   </config>

                        </resource>

            </resources>

I would like to see the shapefiles in Geonetwork, but I don’t know how to
see my database postgis in Geonetwork.

Another problem is to visualice two maps wich are in the main page of
geonetwork. I work in localhost:8080 with geonetwork and localhost:8090
with geoserver. I modified *config-gui.xml *(C:\Archivos de
programa\Apache Software Foundation\Tomcat
5.5\webapps\geonetwork\WEB-INF\config-gui.xml) Paste the code:

<mapSearch options="{projection: 'EPSG:4326', maxExtent: new
OpenLayers.Bounds(-180,-90,180,90), units: 'degrees', restrictedExtent: new
OpenLayers.Bounds(-180,-90,180,90)}">

  <layers>

    <layer server="http://localhost:8090/geoserver/topp/wms&quot; tocName="USA1"
params="{layers: 'topp:states', transparent: 'true', format: 'image/png'}"
options="{}" />

    <layer server="http://localhost:8090/geoserver/wms&quot; tocName="Ortophoto"
params="{layers: 'gn:world', format: 'image/jpeg'}" options="{isBaseLayer:
true}" />

  </layers>

</mapSearch>

  <!-- Configuration for map viewer

    mapViewer/@options: OpenLayers options hash as expected in new
OpenLayers.Map(div, options)

    proj/crs: Projections used in mapViewer

        code CSR code

        default Indicates the default CRS (values: 0, 1)

    scales: array with scales to show in scale selector control. Empty
array, uses scales created from map configuration

    layers/layer:

        server url of the server

        tocName layer name in map

        params OpenLayers params hash as expected in new
OpenLayers.Layer.WMS(name, url, params, options)

        options OpenLayers options hash as expected in new
OpenLayers.Layer.WMS(name, url, params, options)

-->

  <mapViewer options="{projection: 'EPSG:4326', maxExtent: new
OpenLayers.Bounds(-180,-90,180,90), units: 'degrees', restrictedExtent: new
OpenLayers.Bounds(-180,-90,180,90)}">

  <layers>

    <layer server="http://localhost:8090/geoserver/nurc/wms&quot; tocName="UUS
Image" params="{layers: 'nurc:Img_Sample', transparent: 'true', format:
'image/png'}" options="{}" />

    <layer server="http://localhost:8090/geoserver/topp/wms&quot;
tocName="Ortophoto" params="{layers: 'topp:states', format: 'image/jpeg'}"
options="{isBaseLayer: true}" />

  </layers>

  <scales values="[7500000, 5000000, 2500000, 1000000, 750000, 500000,
250000, 100000, 75000, 50000, 25000, 10000, 7500, 5000, 2500, 1000]" />

  <!--scales values="" /-->

  <proj>

    <crs code="EPSG:4326" default="1" name="WGS84 (lat/lon)" />

  </proj>

  <servers>

    <server name="NASA JPL OneEarth Web Mapping Server (WMS)" url="
http://wms.jpl.nasa.gov/wms.cgi?&quot; />

    <server name="NASA Earth Observations (NEO) WMS" url="
http://neowms.sci.gsfc.nasa.gov/wms/wms?&quot; />

    <server name="DEMIS World Map Server" url="
http://www2.demis.nl/mapserver/wms.asp?&quot; />

    <server name="Geoserver" url="http://localhost:8090/geoserver/wms?&quot; />

  </servers>

</mapViewer>

Any idea to solve both problems.

I’ll appreciate your help.

Víctor

Hi Victor

First Mckoi is still enabled
See the line under the Mckoi heading - <resource enabled="true">

Change this to <resource enabled="false">

Next configure the connection paramaters under the heading Postgresql and
ensure it is enabled (which it current is at the moment)
Hope that helps

Regards,
Luke Bassett

On Tue, Oct 2, 2012 at 6:54 AM, <victor.fernandez.gayan@anonymised.com> wrote:

Good Morning/afternoon/night,

I'm doing a final work master's degree about Geonetwork. I modified *
config.xml* in (C:\Archivos de programa\Apache Software
Foundation\Tomcat5.5\webapps\geonetwork\WEB-INF)

In order to try to configured Postgresql conection but I Can’t. Paste de
code:

<resources>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- mckoi standalone -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="true">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>BayACrsQ</user>

<password>Qf7Po9T0</password>

<driver>com.mckoi.JDBCDriver</driver>

<url>jdbc:mckoi://localhost:9157/</url>

                                               <poolSize>10</poolSize>

                                   </config>

                        <activator

class="org.fao.geonet.activators.McKoiActivator"><configFile>WEB-INF/db/db.conf</configFile></activator></resource>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- mysql -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="false">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>admin</user>

                                               <password>admin</password>

<driver>com.mysql.jdbc.Driver</driver>

<url>jdbc:mysql://$WEBSERVER_HOST/geonetwork</url>

                                               <poolSize>10</poolSize>

<reconnectTime>3600</reconnectTime>

                                   </config>

                        </resource>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- oracle -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="false">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>admin</user>

                                               <password>admin</password>

<driver>oracle.jdbc.driver.OracleDriver</driver>

                                               <url>jdbc:oracle:thin:@IP
:1521:fs</url>

                                               <poolSize>10</poolSize>

                                   </config>

                        </resource>

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <!-- postgresql -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="true">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>postgres</user>

<password>artemisia</password>

<driver>org.postgresql.Driver</driver>

<!--

jdbc:postgresql:database

jdbc:postgresql://host/database

jdbc:postgresql://host:port/database

                                               -->

                <url>jdbc:postgresql:geonetwork</url>

                                               <poolSize>10</poolSize>

                                    </config>

                        </resource>

                <!-- - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - -->

                        <!-- sqlserver 2008 -->

                        <!-- - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - -->

                        <resource enabled="false">

                                   <name>main-db</name>

<provider>jeeves.resources.dbms.DbmsPool</provider>

                                   <config>

                                               <user>www-data</user>

<password>www-data</password>

<driver>com.microsoft.sqlserver.jdbc.SQLServerDriver</driver>

<url>jdbc:sqlserver://SERVER;database=geonetwork;integratedSecurity=false;</url>

                                               <poolSize>10</poolSize>

                                   </config>

                        </resource>

            </resources>

I would like to see the shapefiles in Geonetwork, but I don’t know how to
see my database postgis in Geonetwork.

Another problem is to visualice two maps wich are in the main page of
geonetwork. I work in localhost:8080 with geonetwork and localhost:8090
with geoserver. I modified *config-gui.xml *(C:\Archivos de
programa\Apache Software Foundation\Tomcat
5.5\webapps\geonetwork\WEB-INF\config-gui.xml) Paste the code:

<mapSearch options="{projection: 'EPSG:4326', maxExtent: new
OpenLayers.Bounds(-180,-90,180,90), units: 'degrees', restrictedExtent: new
OpenLayers.Bounds(-180,-90,180,90)}">

  <layers>

    <layer server="http://localhost:8090/geoserver/topp/wms&quot;
tocName="USA1"
params="{layers: 'topp:states', transparent: 'true', format: 'image/png'}"
options="{}" />

    <layer server="http://localhost:8090/geoserver/wms&quot;
tocName="Ortophoto"
params="{layers: 'gn:world', format: 'image/jpeg'}" options="{isBaseLayer:
true}" />

  </layers>

</mapSearch>

  <!-- Configuration for map viewer

    mapViewer/@options: OpenLayers options hash as expected in new
OpenLayers.Map(div, options)

    proj/crs: Projections used in mapViewer

        code CSR code

        default Indicates the default CRS (values: 0, 1)

    scales: array with scales to show in scale selector control. Empty
array, uses scales created from map configuration

    layers/layer:

        server url of the server

        tocName layer name in map

        params OpenLayers params hash as expected in new
OpenLayers.Layer.WMS(name, url, params, options)

        options OpenLayers options hash as expected in new
OpenLayers.Layer.WMS(name, url, params, options)

-->

  <mapViewer options="{projection: 'EPSG:4326', maxExtent: new
OpenLayers.Bounds(-180,-90,180,90), units: 'degrees', restrictedExtent: new
OpenLayers.Bounds(-180,-90,180,90)}">

  <layers>

    <layer server="http://localhost:8090/geoserver/nurc/wms&quot; tocName="UUS
Image" params="{layers: 'nurc:Img_Sample', transparent: 'true', format:
'image/png'}" options="{}" />

    <layer server="http://localhost:8090/geoserver/topp/wms&quot;
tocName="Ortophoto" params="{layers: 'topp:states', format: 'image/jpeg'}"
options="{isBaseLayer: true}" />

  </layers>

  <scales values="[7500000, 5000000, 2500000, 1000000, 750000, 500000,
250000, 100000, 75000, 50000, 25000, 10000, 7500, 5000, 2500, 1000]" />

  <!--scales values="" /-->

  <proj>

    <crs code="EPSG:4326" default="1" name="WGS84 (lat/lon)" />

  </proj>

  <servers>

    <server name="NASA JPL OneEarth Web Mapping Server (WMS)" url="
http://wms.jpl.nasa.gov/wms.cgi?&quot; />

    <server name="NASA Earth Observations (NEO) WMS" url="
http://neowms.sci.gsfc.nasa.gov/wms/wms?&quot; />

    <server name="DEMIS World Map Server" url="
http://www2.demis.nl/mapserver/wms.asp?&quot; />

    <server name="Geoserver" url="http://localhost:8090/geoserver/wms?&quot; />

  </servers>

</mapViewer>

Any idea to solve both problems.

I’ll appreciate your help.

Víctor

------------------------------------------------------------------------------
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
_______________________________________________
GeoNetwork-users mailing list
GeoNetwork-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geonetwork-users
GeoNetwork OpenSource is maintained at
http://sourceforge.net/projects/geonetwork

--

*Luke Bassett*
* <lukembassett@anonymised.com>*Melbourne Australia

Thanks Luke Bassett!

It helped a lot

--
View this message in context: http://osgeo-org.1560.n6.nabble.com/Conection-Postgres-and-Geoserver-port-s-configuration-tp5005689p5006623.html
Sent from the GeoNetwork users mailing list archive at Nabble.com.