DNS Server Error when Hitting Database?

K

KCHighland

We have an ASP.NET application that permits anonymous access and runs
as the IUSR account. The application accesses a SQL Server database
located on a different server. All the data access code is in a .NET
DLL that the ASP.NET application references. When accessing the
database, we use SQL Server authentication, passing in the name and
password of a SQL Server account created specifically for the
application. The SQL Server account in question is an owner for the
database it needs to access.

When we try to access the application, however, a DNS error occurs on
the logon page (the first page you hit). The logon page has code to
retrieve a list of facilities from the database. If we comment out the
code that retrieves the facility list, the site works just fine, and we
go right in (although the facility list is predictably empty).

We are quite stumped about this. We know that this is a common scenario
(separate machines for database and web server). But we do not know why
the system can't access the database. We suspect that it's because the
IUSR account doesn't have access to our DNS server, but we're not
certain. We tried changing the database settings to use IP addresses in
lieu of machine names, but that didn't work either.

Any ideas that anyone might have would be greatly appreciated.

Thanks in advance!
 
G

Guest

Troubleshoot it.

1) Install sql query analyzer on your web server running IIS
2) Can you connect to the sql server from it?
3) If not, why?
4) The connection string is everything, also are you hard mapping in your
code, or are you using domain name resolution? Show me your connection
string, and also the ip and computer names and I may be able to help you
better. Remeber, start with the simplest form of the problem, can I connect
to the databse from the computer it is on... another computer...
 
S

Scott Allen

Hi KC:

What is the specific error message you are seeing? You may be getting
the IE "version" of the error, which will be mind numbingly useless.

Remove friendly error messages in IE ( Tools -> Options -> Advanced ->
and un-check 'Show friendly HTTP error messages'). After that you may
also need to modify web.config to display the full details of the
error.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,226
Members
46,815
Latest member
treekmostly22

Latest Threads

Top