Please help local system installation

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
12 лет назад
I am trying to install nop commerce 2.65 on my local machine with vista. Sql server 2012. I am unable to go past the first installation screen.

Setup failed: An error occurred while creating the database: CREATE DATABASE permission denied in database 'master'.

This is the error I am getting using windows authentication. I have used mixed mode authentication at the time of setup of sql.. can any one guide me what I need to do or  What I am doing wrong... Please an help will be grateful.

I even tried with "sa" and also a new user I created with all the permissions..
12 лет назад
Hi,

If the Database-Name you entered was master you should choose another name,
ensure, that the user you select has role of at least sysadmin, dbcreator
and (don't know if necessary, but it wont hurt if you do it)
if the database already exists that the user is added to the database-specific security tree.

hope this helps

Sonia
12 лет назад
Thanks for your help Sonia, I entered the database name as nop, I created the data base in the sql server management studio and added a login in the security tree will full permission.. I am trying what I am suppose to do, but its just baffling me.
12 лет назад
Whats the message now? you still get that error or is it different now?

SQL Server has two security trees.
One is for the whole DB Server and is located in tree

Servername -> Security -> Logins

Ensure, that the user has sysadmin, and securityadmin rights that should be enough for building,

The other one only for the database and is located :

Servername -> Databases -> [DB-Name] -> Security

You could set the user as dbowner

If you are using integrated security the user account that is using IIS to connect to the application needs to have the specific rights. I am not quite sure about who that would be, because for me I have not been able to find out, thats why I connect by sql server user and not integrated security, but IUSR and NetworkService is one of the suspects in that case.
If you use sql server user you need to ensure that the server is set in Security Properties

Servername -> Properties -> Security

to Sql Server and Windows Authentication
otherwise it wont work

For testing if you are even able to connect to the server you could build a simple
test.udl file on the db machine with the texteditor. Just ensure that its truely test.udl and not test.udl.txt
The file will only work with propper ending!

Just create in directory a file naming that and open it after creating. Select Sql Server driver and enter
connection data and click test connection.
If you are not able to connect there too, it may give you some more hint where to look.
12 лет назад
The following BKM (Best Known Method) is what I use for my local development environments:
1. Create a local database without requiring SQL Server.
    Open a command prompt using Administrator privileges.
    Documentation for the utility SqlLocalDB Utility is available here:
    http://msdn.microsoft.com/en-us/library/hh212961.aspx

    Microsoft Windows [Version 6.1.7601]
    Copyright (c) 2009 Microsoft Corporation.  All rights reserved.
    
    C:\Windows\system32>cd C:\workspace\nopCommerce_2.70_Source
    
    C:\workspace\nopCommerce_2.70_Source>"C:\Program Files\Microsoft SQL Server\110\Tools\Binn\SqlLocalDB.exe" create LocalDBnopCommerce
    LocalDB instance "LocalDBnopCommerce" created with version 11.0.
    
    C:\workspace\nopCommerce_2.70_Source>"C:\Program Files\Microsoft SQL Server\110\Tools\Binn\SqlLocalDB.exe" start LocalDBnopCommerce
    LocalDB instance "LocalDBnopCommerce" started.
    
    C:\workspace\nopCommerce_2.70_Source>"C:\Program Files\Microsoft SQL Server\110\ Tools\Binn\SqlLocalDB.exe" info LocalDBnopCommerce
    Name:               LocalDBnopCommerce
    Version:            11.0.2100.60
    Shared name:
    Owner:              xyz\Mark
    Auto-create:        No
    State:              Running
    Last start time:    11/30/2012 2:37:50 PM
    Instance pipe name: np:\\.\pipe\LOCALDB#329ED08A\tsql\query
    
    C:\workspace\nopCommerce_2.70_Source>
    
2. Installation wizard BKM settings for a local development environment:

.-----------------------------------------------
Store Information
Admin user email:        <email address>
Admin user password:  **********
Confirm the password: **********

Database information
.-----------------------------------------------
o Use built-in data storage (SQL Server Compact)
x Use SQL Server (or SQL Express) data base [Recommended]

.-----------------------------------------------
Create database if it doesn’t exist x
x Enter SQL connection value:  o Enter raw connection string (advanced)
Sql Server name: (localdb)\v11.0
Database name:  (localdb)\LocalDBnopCommerce
O Use SQL Server account  x Use integrated Windows authentication
Specify custom SQL Server collation: O
11 лет назад
Same problem NOP 3.0 database permissions error.
THIS IS NOT A NOPCOMMERCE ISSUE - BUT I COULD USE SOME DIRECTION


Still can not get something right.

Setting up 3.0 using ADMINISTRATOR account on local machine for pre post testing.

When using integrated Windows authentication - ERROR'S

After days of working with security settings, multiple web builds I still get error:

•Setup failed: An error occurred while creating the database: CREATE DATABASE permission denied in database 'master'.


I CAN GET THE DATABASE TO LOAD USING " SA " account, Using SQL Server account

I never ask for help, I always figure if out.

BUT I AM STUCK AND FIGURED I WOULD SEND UP A FLAG  - HELP



Notes:

I can create a data base in Sql Express 2012 using Win Authorization.

I can open it - modify it in SQL Sever management Studio ( Administrator ).

If I change name of Server String - DIFFERENT ERROR's appear so that tells
3.0 is trying to talk to SQL but permissions are the issue.

I can create a site using DB ( Use built-in data storage (SQL Server Compact))
supplied in NOPCOMMERCE also.


Questions:

1: Can someone tell me what permissions need to be set for DB connections to work locally.

2: How do I change the password in NOPCOMMERCE to match SQL.
If I change the password in SQL the connection is lost in NOP 3.0

3: Any help would be greatly appreciated.

4: Can I change from SQL to Win Identification after build ??
11 лет назад
hi,



Just a guess:
I suppose that the process is trying to access the database with
the user that the IIS webservice is running. Which would be - depending on your IIS version - IUsr, Network Service or whatever you put the service on.
If you use Windows Identity the applicationpool needs to run with this identity.
Check logs if you can see what user tries to create the database.
If you use full SqlServer you even can run Profiler to see this better.

To change the password which uses nop to connect to the database
you need to go to the nop folder AppData/Settings.txt

The neccessary persmissions would be db_datareader, db_datawriter at least
11 лет назад
OK


1: IUsr, Network Service = iis 7.5

2: If you use Windows Identity the applicationpool needs to run with this identity = ?

3: Check logs if you can see what user tries to create the database = SQL express or NOP 3.0 logs ?

4: neccessary persmissions would be db_datareader, db_datawriter =

WHO GETS PERMISSIONS, SYSTEM in IIS NT SERVICES in SQL ?



Does anyone have a permission list ??
SQL Express, NOPCOMMERCE Permissions for Idiots ???  


Thanks
11 лет назад
sorry for being confusing. I will try to explain better.

ERICKNIGHT wrote:

1: IUsr, Network Service = iis 7.5

So you run a IIS 7.5. Then if you have set your NOP-applicationpool IN IIS to ApplicationPoolIdentity, then IIS will try to access database with DefaultAppPool. So this user needs accessrights to the database.

http://www.iis.net/learn/manage/configuring-security/application-pool-identities

ERICKNIGHT wrote:

2: If you use Windows Identity the applicationpool needs to run with this identity = ?

The other way round.
IF you have set up applicationpool to run in ApplicationPoolIdentity Mode. then you need to give access DefaultAppPool
on the Database in Microsoft SQL Server Management Studio .

http://serverfault.com/questions/81165/how-to-assign-permissions-to-applicationpoolidentity-account

If you choose another user. Like for example a local Windows System User that you created for this or Network Service,
you need to grant this specific user access to the database in Microsoft SQL Server Management Studio.
Go to your main sql-server security tree, apply specific user
go to your db- security tree, apply specific user. grant db_datareader, db_datawriter.
Maybe you also need to grant permission to connect. I can't remember right now.
If you have trouble still you can try to give him sysadmin rights to see if it basically works. If it does, some other sort of additional right must be set. Like e.g. permission to remoteconnection or something like this.

ERICKNIGHT wrote:

3: Check logs if you can see what user tries to create the database = SQL express or NOP 3.0 logs ?

I meant Systemlogs.
Sometimes the dbms leaves info there on who tried to connect to it and why it was rejected.

ERICKNIGHT wrote:

4: neccessary persmissions would be db_datareader, db_datawriter =

WHO GETS PERMISSIONS, SYSTEM in IIS NT SERVICES in SQL ?

The one who is running your nop application pool on IIS!

If you still got trouble then you may try to set up the nop-applicationpool in IIS to run with a specific user and grant THIS specific user Database rights on your SQL Server Management console
11 лет назад
ERRORS IN SQL LOG

Error: 18456, Severity: 14, State: 38.

---

I have mirrored all permissions from SA to Administrator account with no luck

I am doing all work logged in as administrator for diagnostics

I have opened all the doors in IIS

It is a permission error in SQL
or
IIS APPPOOL
or
BOTH


SQL Express Log file

Error: 18456, Severity: 14, State: 38.

--

Note that the SQL Server Profiler tool NOT AVAILABLE with 2012 Exp edition

--

When I open NOP 3.0 that was created using SA Account works fine log reads

" Source - spid56, Message Starting up database "  ReportServer$SQKECPRESSTempDB".
then starts database



When I open Win Auth Site - Log Reads

" login failed fro user " IIS APPPOOL\TESTNOP03". Reason: failed to open the explicitly specified database " TESTNOP03". [CLIENT:<LOCAL MACHINE>]


Again - It all works with the SQL SA Account
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.