?
Solved

SQL 2005

Posted on 2011-02-15
5
Medium Priority
?
277 Views
Last Modified: 2012-06-21
I have a web site someone setup using asp. it is trying to connect to my SQL 2005 server. i know next to nothing about SQL 2005 and asp, but so far i got the web page up, ( it's on a windows 2003 server running IIS6 with aspnet 2 ). the person that made this stie is no longer with the company and i can't contact him. he made a login link on the site , and i found the login name and password by going to the SQL 2005 server and opening the user's table. however, when i open the website through IIS manager, and click the login link, then put in my user name and password i get this error
"login failed for user 'USER\DOMAINNAME$' ( i changed the user name and domain name to the generic names you see here)
I found on google something about messing with the web.config file, and i tried that, but due to my lack of knowledge, i only managed a new error
"login failed for user ". The user is not associated with a trusted SQL server connection.
that was when i changed integrated security=false from true in the web.config. i want to use windows security, not sql. any ideas?
0
Comment
Question by:JeffBeall
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 13

Expert Comment

by:dwkor
ID: 34901203
Open management studio, go to security section/logins and create the new login for specific windows DOMAIN user. By default it would try to use IIS process account so you probably need to change it there too. Next, go to the user mapping tab and give user access to the database and just in case to tempdb.

Next, open www.connectionstrings.com and make sure that connection string is correct for that setup.



0
 
LVL 1

Author Comment

by:JeffBeall
ID: 34901503
"Open management studio, go to security section/logins and create the new login for specific windows DOMAIN user."

I'm pretty sure I already did this.

"By default it would try to use IIS process account so you probably need to change it there too."

I have no idea what you mean?
what would try to use IIS process accout?, what is the IIS process account? So i need to change what where?
0
 
LVL 13

Accepted Solution

by:
dwkor earned 2000 total points
ID: 34901579
Your ASP.Net application is hosted under IIS. So technically it's running under security credentials of that process. So you need to impersonate.. Take a look at this link: http://msdn.microsoft.com/en-us/library/ff647396.aspx
0
 
LVL 1

Author Comment

by:JeffBeall
ID: 34910939
in SQL server management studio I've tried setting the nt authority\network service in the database, security, users. and checked db_datareader, and db_datawriter. also, i think another problem i had was the website is on my test server which was on a different domain than my SQL server. so i moved my test server to the same domain as my sequel server, but i am STILL getting this error
"login failed for user 'domainname\machinename$"
no matter what user i use it has the above error. also, i think it is weird that the login shows the domainname and the machinename instead of the domainname\username.
0
 
LVL 1

Author Closing Comment

by:JeffBeall
ID: 34911206
i FINALLY figured this out, the clue was right in front of me. the error said domainname\MACHINEname. I had to give access to the COMPUTER name, not a user! it is finally working!
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
It is possible to export the data of a SQL Table in SSMS and generate INSERT statements. It's neatly tucked away in the generate scripts option of a database.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question