Author |
Topic |
barnsley
Starting Member
34 Posts |
Posted - 2014-06-27 : 07:23:23
|
I am try to create a user in SQL 2008.It is for a DotNetNuke (DNN) CMS.I have put this problem on DNN forum, but nobody seems to understand the problem :- I think this is a SQL issue.we are using: windows 2008 r2, SQL 2008, ASP.net4, and IIS7.I believe that because we are using Windows 2008 r2 that we must prefix our username with iis appPool\ However, this results in an error when using the backslash...ERROR is something like this:"...iis apppool\[myUserName] is not a valid name because it contains invalid characters error code: 15006..."any ideas as to why this is please?mark. |
|
James K
Master Smack Fu Yak Hacker
3873 Posts |
Posted - 2014-06-27 : 10:40:13
|
The correct syntax is [apppool\myUserName], but I am not commenting on whether or not that is the correct username to provide.As an aside, in SQL, there is the concept of a login - which is a server level entity that allows someone to connect to the sever and then there are users which are entities associated with databases. A user can be associated with a login, which then would give that login access to the resources on the database accessible to that user. http://msdn.microsoft.com/en-us/library/ms181127.aspx |
|
|
barnsley
Starting Member
34 Posts |
Posted - 2014-06-27 : 11:51:53
|
thanks,I tried both "iis apppool\myUserName"and"apppool\myUserName"I get the same error.It is for creating a new loginmark. |
|
|
James K
Master Smack Fu Yak Hacker
3873 Posts |
Posted - 2014-06-27 : 14:00:32
|
I suspect that neither of them is correct. SQL Server allows two types of authentications - SQL Authentication or Windows Authentication. The format I suggested earlier is for Windows Authentication. You can create a login for [DomainName\LoginName] if there is a domain called "DomainName" and a windows user in that domain named "LoginName". Also, you do need the square brackets as I had indicated.Another way to understand what is going on might be to run SQL Profiler. It is under the Performance Tools group in Programs -> Microsoft SQL Server xxxx. It will let you see all the queries coming into the server. So you will be able to see what your client application is sending to the SQL Server when you request a new login be created. |
|
|
barnsley
Starting Member
34 Posts |
Posted - 2014-06-30 : 04:46:44
|
I'm confused...according to this page:http://www.dnnsoftware.com/wiki/page/install_dotnetnukesection 5.iit says:' ...For Windows 7 or Windows 2008R2 running IIS 7.5 you'll need to add the application pool ie; "IIS AppPool\{AppPoolName}" (without the quotes). 'I also believe its possible to use the above login for both Windows and SQL Authentication.(I'm not familiar with SQL Profiler, so not sure how this could help in this situation.)mark. |
|
|
James K
Master Smack Fu Yak Hacker
3873 Posts |
Posted - 2014-06-30 : 10:24:24
|
I am not familiar with DNN, so all my suggestions are purely based on looking at what the SQL Server might be seeing. When DNN documenation suggests that you should use "IIS AppPool\{AppPoolName}", they are likely to correct, because if my guess is correct, their application code will take that string from you and change it according to what their business rules are and according to what they think they need to send to SQL Server. Since we don't have visibility into what they might be doing with the string, there is no point in guessing what it should be. You will need to do what their documentation says.Then, the question to be figured out is whether the error message is coming from SQL Server or DNN application layer. If it is coming from DNN, you will need to ask the DNN support for help. If it is coming from SQL Server, still they should help you figure out what the issue is, but you might be able to assist. That is where SQL profiler comes into play.SQL profiler helps you see what queries are coming into the SQL Server. If you see a request to create a login coming into the SQL Server, and if you post that query, we can figure out whether that is a valid query from the perspective of SQL Server. |
|
|
barnsley
Starting Member
34 Posts |
Posted - 2014-07-01 : 07:54:46
|
Thanks for your input anyway.AS for the DNN side of things... I'm only at the database set up part of things, and it is possible to set this up first before installing the DotNetNuke CMS and 'perhaps' even before the IIS part of things.Although, the only example I've seen where the database is set up before IIS (and also using SQL Authentication) - shows the login name not being prefixed by the 'iis appPool\' name.The example where the 'iis appPool\' name is used... uses Windows Authentication. (I'm still waiting to hear if it's possible to prefix the 'iis appPool\' name AND ALSO use SQL Authentication.)AS for SQL Profiler... I've run a few traces whilst attempting to create this login, but in the Trace - it doesn't tell me a great deal - it says:--*CREATE LOGIN--------------------in the trace window, with no real information/error message. It lists the server name and NTUsername etc.I've posted on a DNN forum and nobody seems to know the answer. I've also Googled and again, no luck.So, I thought it would more of a SQL issue.mark. |
|
|
barnsley
Starting Member
34 Posts |
Posted - 2014-07-03 : 05:07:39
|
I've found my answer here:http://www.dnnsoftware.com/forums/forumid/107/threadid/503908/scope/postsapparently I don't have to use 'iis appPool\myName' when using - windows 2008 r2, SQL 2008, ASP.net4, and IIS7.5I can still use SQL Authentication and a use a login name without the 'iis appPool' prefex!(thanks for your input James)mark. |
|
|
|