How To Add Db_owner Role To Newly Created Users - Plesk

Skip to content

Knowledge Base

How to add db_owner role to newly created users
 
databasedatabasesfeaturesgointerface

Question

How to add db_owner role to newly created MSSQL users?

Answer

Starting from Plesk version 12, MS SQL users created through Plesk interface are not provided with db_owner role for security reasons. This is to harden SQL service security againts various attack, for example, SQL injection.

In order to change this behavior for server wide perform the following steps:

  1. Connect to the server via RDP;

  2. Open the file panel.ini located in the folder %plesk_dir%adminconf (Just paste this path in Windows Explorer to open) in any text editor.

    Note: If the panel.ini file does not exist, create it by copying the sample configuration file panel.ini.sample to panel.ini.

    Add the following settings to the %plesk_dir%adminconfpanel.ini:

    [databaseManagement]features.roles.mssql.readWrite = db_owner,db_datareader,db_datawriter,db_backupoperator,db_ddladmin

  3. Run the following CMD command to apply the changes to all the MSSQL servers:

    C:> "%plesk_cli%repair.exe" --update-mssql-users-permissions

    Note: the existing users will obtain a new role as well.

Refer to the documentation Database User Roles and Permissions for more details.

For one particular database it's possible to assign db_owner role via Microsoft SQL Management Studio Express:

  • Open Microsoft SQL Management Studio Express
  • Navigate to Security > Logins > Right-click the db user and select Properties
  • In properties go to User Mappings
  • Click on the database and check that the options db_owner and Public are selected.
Read the full article Related Posts

How to Host a Go App on Plesk

Read More »

Plesk with Centralized Database and Network File System

Read More »

The Comfortable Advantages of the Hosting Control Panel

Read More » Knowledge Base

How to reset a password for the ‘sa’ user of a Microsoft SQL Server instance on a server with Plesk

Read More »

How to add a new instance of existing MS SQL Server to Plesk

Read More »

mssqlmng.exe, DNSMng.exe, php.exe and pmm-ras.exe are marked as infected by Microsoft Security / Windows Defender

Read More »

How to add an already installed Microsoft SQL server in Plesk

Read More »

Hosting Wiki

  • Django
  • Content Security Policy ( CSP )
  • DBMS Interface
  • Server Redundancy
  • Google Cloud CDN
  • PostgreSQL
  • Bare Metal Server
  • MySQL
  • Oracle VM Server
  • Server Virtualization Software
  • Windows Server
  • MSSQL
  • MongoDB
  • SQL
  • Plesk
  • SQL database
  • NoSQL Database
  • Web Server
  • DNS Server

Install How to add db_owner role to newly created users extension

Hostname or IP or URL of your Plesk instance:

Host Go to install

Tag » Add Db_owner Role Sql Server