[Geoserver-users] GeoServer 1.7+ SQL Server Data Store Extension - problem

I’m new to GeoServer. We did install the GeoServer on a Windows 2008 machine. It runs. We added a small test SHP file FeatureType. So far, OK.

I downloaded the SQL extension. Installed the extension and SQL Server JDBC driver from Microsoft … restarted the server. When adding a DataStore I now see the SQL Server option. No matter what parameters I try, I always get an error “unable to obtain a connection”. The SQL server is on another server.

Any suggestions?

Dave Kimball

Telepartner International

860 368-4550 x243

Hi Dave. That sounds to me more like a firewall/connectivity issue more than a GeoServer issue. I would make sure that the server:port you are using for your SQL Server is open to the machine that's running GeoServer. (I haven't used a Windows Server past 2003, but the Windows Firewall keeps getting more aggressive in subsequent versions, so perhaps there's something there...)

Thanks,
Mike Pumphrey
OpenGeo - http://opengeo.org

Dave Kimball wrote:

I’m new to GeoServer. We did install the GeoServer on a Windows 2008 machine. It runs. We added a small test SHP file FeatureType. So far, OK.

I downloaded the SQL extension. Installed the extension and SQL Server JDBC driver from Microsoft .. restarted the server. When adding a DataStore I now see the SQL Server option. No matter what parameters I try, I always get an error “unable to obtain a connection”. The SQL server is on another server.

Any suggestions?

Dave Kimball

*Telepartner International*

860 368-4550 x243

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

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H

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

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Hi Dave,

Are you supplying a database name? If so try removing the database name. I believe this is an issue with how the driver connects to the database. If you can confirm this I will open a bug report for it.

-Justin

Dave Kimball wrote:

I’m new to GeoServer. We did install the GeoServer on a Windows 2008 machine. It runs. We added a small test SHP file FeatureType. So far, OK.

I downloaded the SQL extension. Installed the extension and SQL Server JDBC driver from Microsoft .. restarted the server. When adding a DataStore I now see the SQL Server option. No matter what parameters I try, I always get an error “unable to obtain a connection”. The SQL server is on another server.

Any suggestions?

Dave Kimball

*Telepartner International*

860 368-4550 x243

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

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H

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

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

I got same issue when I used the SQL Server SQLEXPRESS in local machine and.

I got same when entering a database or not.

Justin Deoliveira-6 wrote:

Hi Dave,

Are you supplying a database name? If so try removing the database name.
  I believe this is an issue with how the driver connects to the
database. If you can confirm this I will open a bug report for it.

-Justin

Dave Kimball wrote:

I’m new to GeoServer. We did install the GeoServer on a Windows 2008
machine. It runs. We added a small test SHP file FeatureType. So far, OK.

I downloaded the SQL extension. Installed the extension and SQL Server
JDBC driver from Microsoft .. restarted the server. When adding a
DataStore I now see the SQL Server option. No matter what parameters I
try, I always get an error “unable to obtain a connection”. The SQL
server is on another server.

Any suggestions?

Dave Kimball

*Telepartner International*

860 368-4550 x243

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

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco,
CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H

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

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco,
CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
View this message in context: http://www.nabble.com/GeoServer-1.7%2B-SQL-Server-Data-Store-Extension---problem-tp22282332p22625162.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

You may find this recent thread on the users list useful:

http://www.nabble.com/SQL-Server-2008-datastore-connection-td22461607.html

In it Geney states the steps gone through to get an up and running connection.

keith_c888 wrote:

I got same issue when I used the SQL Server SQLEXPRESS in local machine and.

I got same when entering a database or not.

Justin Deoliveira-6 wrote:

Hi Dave,

Are you supplying a database name? If so try removing the database name. I believe this is an issue with how the driver connects to the database. If you can confirm this I will open a bug report for it.

-Justin

Dave Kimball wrote:

I’m new to GeoServer. We did install the GeoServer on a Windows 2008 machine. It runs. We added a small test SHP file FeatureType. So far, OK.

I downloaded the SQL extension. Installed the extension and SQL Server JDBC driver from Microsoft .. restarted the server. When adding a DataStore I now see the SQL Server option. No matter what parameters I try, I always get an error “unable to obtain a connection”. The SQL server is on another server.

Any suggestions?

Dave Kimball

*Telepartner International*

860 368-4550 x243

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

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco,
CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H

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

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco,
CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

I created a SQL Server 2008 datastore, but got a problem when creating
FeatureTypes for it. I downloaed st99_d00.shp, st99_d00.shx, st99_d00.dbf
and then imported data to Postgre and SQL Server 2008 databases respective.

When creating a FeatureType by a PostGres datastore, geoServer populated
value to SRS and then Min/Max Long, Min/Max Lat after clicking Generate
button. Then I could see the map in Mini-map preview of the eanbled
FeatureTypes.

When create a FeatureType by a SQL Server datastore, I had to enter values
for SRS, Long, Lat myself. Then I clicked Submit, Apply, Save buttons.
Finally, I viewed the FeatureType. it shown window, background, zoom icon,
but no map. I draged and moved around inside the window several times, it
displayed error

java.lang.RuntimeException: java.lang.RuntimeException: java.io.IOException
java.lang.RuntimeException: java.io.IOException java.io.IOException null No
code "EPSG:0" from authority "European Petroleum Survey Group" found for
object of type "IdentifiedObject".

keith

keith_c888 wrote:

I got same issue when I used the SQL Server SQLEXPRESS in local machine
and.

I got same when entering a database or not.

Justin Deoliveira-6 wrote:

Hi Dave,

Are you supplying a database name? If so try removing the database name.
  I believe this is an issue with how the driver connects to the
database. If you can confirm this I will open a bug report for it.

-Justin

Dave Kimball wrote:

I’m new to GeoServer. We did install the GeoServer on a Windows 2008
machine. It runs. We added a small test SHP file FeatureType. So far,
OK.

I downloaded the SQL extension. Installed the extension and SQL Server
JDBC driver from Microsoft .. restarted the server. When adding a
DataStore I now see the SQL Server option. No matter what parameters I
try, I always get an error “unable to obtain a connection”. The SQL
server is on another server.

Any suggestions?

Dave Kimball

*Telepartner International*

860 368-4550 x243

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

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San
Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H

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

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco,
CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
View this message in context: http://www.nabble.com/GeoServer-1.7%2B-SQL-Server-Data-Store-Extension---problem-tp22282332p23176440.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

Hi Keith,

Could you include the entire stack trace. My first thought is that this could be some sort of wierd installation issue, but I would need to see the entire stack trace to be sure. Also knowing about your setup would help. Which versions of geoserver and the sql server extension you are using would help. Are you running in a servlet container like tomcat? or the standalone jetty version?

Thanks,

-Justin

keith_c888 wrote:

I created a SQL Server 2008 datastore, but got a problem when creating
FeatureTypes for it. I downloaed st99_d00.shp, st99_d00.shx, st99_d00.dbf
and then imported data to Postgre and SQL Server 2008 databases respective.

When creating a FeatureType by a PostGres datastore, geoServer populated
value to SRS and then Min/Max Long, Min/Max Lat after clicking Generate
button. Then I could see the map in Mini-map preview of the eanbled FeatureTypes.

When create a FeatureType by a SQL Server datastore, I had to enter values
for SRS, Long, Lat myself. Then I clicked Submit, Apply, Save buttons. Finally, I viewed the FeatureType. it shown window, background, zoom icon,
but no map. I draged and moved around inside the window several times, it
displayed error

java.lang.RuntimeException: java.lang.RuntimeException: java.io.IOException
java.lang.RuntimeException: java.io.IOException java.io.IOException null No
code "EPSG:0" from authority "European Petroleum Survey Group" found for
object of type "IdentifiedObject".

keith

keith_c888 wrote:

I got same issue when I used the SQL Server SQLEXPRESS in local machine
and.

I got same when entering a database or not.

Justin Deoliveira-6 wrote:

Hi Dave,

Are you supplying a database name? If so try removing the database name. I believe this is an issue with how the driver connects to the database. If you can confirm this I will open a bug report for it.

-Justin

Dave Kimball wrote:

I’m new to GeoServer. We did install the GeoServer on a Windows 2008 machine. It runs. We added a small test SHP file FeatureType. So far,
OK.

I downloaded the SQL extension. Installed the extension and SQL Server JDBC driver from Microsoft .. restarted the server. When adding a DataStore I now see the SQL Server option. No matter what parameters I try, I always get an error “unable to obtain a connection”. The SQL server is on another server.

Any suggestions?

Dave Kimball

*Telepartner International*

860 368-4550 x243

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

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San
Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H

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

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco,
CA
-OSBC tackles the biggest issue in open source: Open Sourcing the
Enterprise
-Strategies to boost innovation and cut costs with open source
participation
-Receive a $600 discount off the registration fee with the source code:
SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

Thanks for the replies. I've been distracted, hence my delay.

Removing the database name does allow me to continue to Apply/Save. I can
then select what looks like SQL internal table in the Creat New Feature Type
- for example "spt_datatype_info" or "sysconstraints".

(I'm running SQL data store 1.7.4 with GeoServer 1.7.3 .. the install says
these should be compatible) This server is SQL 2005. The GeoServer is
running otherwise without a problem.

So I feel closer, but not quite there. I'll play a bit with database name ..
maybe there is a way to create the datastore with a non-blank database
name???

Dave

Hi Dave,

Are you supplying a database name? If so try removing the database name.
  I believe this is an issue with how the driver connects to the
database. If you can confirm this I will open a bug report for it.

-Justin

--
View this message in context: http://www.nabble.com/GeoServer-1.7%2B-SQL-Server-Data-Store-Extension---problem-tp22282332p23561578.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

I believe this is resolved. Upon searching further among other posts I
learned that I could access the tables I care about if I create a speical
SQL user and configure the datatable with that user. Previously I was using
a system admin user ID which explains the default table being SQL internal
tables.

Adding a user names GeoServer, setting the default database for this user to
the one I needed ... success!

I'm sure this is documented somewhere, but I had missed it all together.

Dave
--
View this message in context: http://www.nabble.com/GeoServer-1.7%2B-SQL-Server-Data-Store-Extension---problem-tp22282332p23561953.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

Hi Dave,

Thanks for the info. I will add this to the trouble shooting section of our docs for sql server.

-Justin

Dave Kimball wrote:

I believe this is resolved. Upon searching further among other posts I
learned that I could access the tables I care about if I create a speical
SQL user and configure the datatable with that user. Previously I was using
a system admin user ID which explains the default table being SQL internal
tables.

Adding a user names GeoServer, setting the default database for this user to
the one I needed ... success!

I'm sure this is documented somewhere, but I had missed it all together.

Dave

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.