Sunday, February 19, 2012

Cant connect to SQL server at work from home project

HI All,

i have copied a project from work i am working on and have created the same project at home in visual studio.net - everything is the same as it is at my work - for some reason though i cannot connect to the servers from my home project

can anyone help me with this - i get the message "SQL Server does not exist or access denied"

my web config has exactly the same set up with a key in appSettings as

<add key="My_Connection" value="User ID=myID;Password=myPassword;Initial Catalog=myCatalog;Data Source=xx.xx.xx.xx" />

can anyone tell me why i would not be able to even see my work database from home?

thanks in advance

GilesbAre you trying to point to the databases that are at work or new ones that you have created at home?

If they are at home have you checked to ensure that all the correct logins have been recreated?

If you are pointing to databases at work then it is likely that you can't access from outside of the work network.|||Few things u need to check.
1) Is there a firewall protecting your "Work" LAN? If yes, ask your system administrator to open the SQL port in your firewall and be sure to ask your system administrator to set a rules to restrict for your IP address or connecting by VPN.
2) You ve to configure your connection through Client utility. Specify a server name and External network IP address. That will direct your application to call external IP address.|||Sounds like someone where you work might actually know what they're doing. You shouldn't be able to connect unless connected by VPN. If you can, then you have bigger problems then the fact you copied your work project to a home computer. If you have permissions to work from home, have the network admins grant you remote user access and set you up to use the VPN. If not, either work more hours at work, or explain to your bosses why you can't work from home.|||Thanks for your help guys but i dont think i would need a VPN to merely access a database just to "login" as it were - basically i have an asp.net project that runs fine when testing at work - servers are at work, but when i run it from home i cant get a connection - should be just like running the site from home and hooking in to the database right ?

I am fairly new to the database scene - will ask someone at wotk whether any special configuration is required

thanks once again to all that replied

Gilesb|||Okie, yes and at the same time a resounding no!

If your home computer were part of the work network then yes, it would be exactly the same but it is not. If you VPN in to the work network then yes, you would be part of the same network.

To put a sql server onto your network with open ports to the real world is asking for trouble (yeah, there are probably ways of making sure it is mostly secure, but only mostly...). I'd estimate 90% of SQL Servers are safely hidden behind firewalls to prevent anything other then the machines on the internal network connecting to it.

No comments:

Post a Comment