I missed to specify the default location for the data file and the log file while installing SQL SERVER . So when I created a database and did not specify the default location for the files it will be created on the location defined in the server settings. So if we want always the data files and log files to be created on a particular location we can
change the server properties through SSMS - > Database Settings -> Database default locations .
However this requires the sql instance to be restarted for the changes to take effect.
This blog is created to add all the information and experiences that I have learnt while working on MS sql server as a DBA. The blog is also updated frequently with the real world problem that I encounter hands on at work and the resolutions to resolve them. I hope this blog will be of some use to you and you will revisit. Thank you for stopping by and you are welcome to leave comments.
Friday, June 8, 2018
Thursday, June 7, 2018
Adding missing permission to a folder for the MSSQL$instance account
I had to move the data files from one driver to another. After moving the data files when I brought the database online it gave"Access denied" error and I found out that the reason was that the MSSQL$instance account did not have permission to the data file.
I right clicked on the folder and on the security tab tried to add the user to give the missing permission but could not locate the user. I had to do the following to find the user in the user list
To add the missing permissions
chose the local computer and type in "NT SERVICE\MSSQL$instance
I right clicked on the folder and on the security tab tried to add the user to give the missing permission but could not locate the user. I had to do the following to find the user in the user list
To add the missing permissions
chose the local computer and type in "NT SERVICE\MSSQL$instance
Subscribe to:
Posts (Atom)