Export (0) Print
Expand All

Configuring DCOM for SQL Debugging

SQL debugging uses Distributed COM (DCOM) to communicate between a client computer and the database server. Therefore, you must configure DCOM to allow a remote user to attach the debugger to a process on the server.

Caution   Because of security considerations on a computer running SQL Server, you may want to restrict debugging access to a specific group or user. You should avoid giving access to Everyone, because this allows access to any user on the network. The following DCOM configuration procedures enable SQL debugging for individual users on the SQL Server 7.0 computer. (Because of differences in security models, SQL Server 2000 does not check individual DCOM permission for remote debugging.)
Note   If you add an account for a remote user to debug on the local SQL Server, local users will no longer be able to debug on the local SQL Server unless you use dcomcnfg.exe to add their user accounts.
Note   Depending on your operating system, it may be necessary to configure DCOM access permissions for SQL debugging even if the SQL Server connected to is on the local machine.

Windows 2000

To configure DCOM on the server for SQL debugging

You may need to download and install DCOM first. If so, go to http://www.microsoft.com/com/resources/downloads.asp for the latest version.

You must have administrator privileges on the machine where you are configuring DCOM.

  1. From the Start menu, choose Run.
  2. In the Open box, type dcomcnfg.exe.
  3. Click OK.

    The Distributed COM Configuration Properties dialog box appears.

  4. Choose the Default Security tab.
  5. In the Default Access Permissions, click the Edit Default button.
  6. The Registry Value Permissions dialog box appears. If the group or user who needs access does not appear in the list of permissions, click the Add button.
  7. In the Add Users and Groups dialog box, Add Names box, choose the group or user who needs access from the Names list or type it in the Add Names box.
  8. With the group or user name selected, choose Allow Access from the Type of Access list.
  9. Click OK.
  10. If SYSTEM does not appear in the list of permissions, click the Add button again.
    1. In the Add Users and Groups dialog box, Add Names box, choose SYSTEM from the Names list or type it in the Add Names box.
    2. With SYSTEM selected, choose Allow Access from the Type of Access list.
    3. Click OK.
  11. If you changed any settings in this procedure, restart SQL Server.

Windows XP

To configure DCOM on the server for SQL debugging

You may need to download and install DCOM first. If so, go to http://www.microsoft.com/com/resources/downloads.asp for the latest version.

You must have administrator privileges on the machine where you are configuring DCOM.

  1. From the Start menu, choose Run.
  2. In the Open box, type dcomcnfg.exe.
  3. Click OK.

    The Component Services dialog box appears.

  4. In the left pane of the Component Services dialog box, expand the Component Services node and find Computers.
  5. Expand the Computers node and find the computer for which you want to configure DCOM.
  6. Right-click the computer and choose Properties from the shortcut menu.
  7. In the Properties dialog box, select the Default COM Security tab.
  8. Under Access Permissions, click Edit Default.

    The Access Permission dialog box appears.

  9. If the group or user who needs access does not appear in the list of permissions, click Add.

    The Users, Computers, or Groups dialog box appears.

    1. In the Enter the object names to select box, type the name of the group or user who needs access.
    2. Click OK.

      The user is now added to the list.

  10. If SYSTEM does not appear in the list of permissions, click Add.

    The Users, Computers, or Groups dialog box appears.

    1. In the Enter the object names to select box, type:
      SYSTEM  
      
    2. Click OK.

      SYSTEM is now added to the list.

  11. In the Access Permission, select Allow for each user you added.
  12. Click OK to close the Properties dialog box.
  13. If you changed any settings in this procedure, restart SQL Server.

See Also

Setting Up SQL Debugging | Debug Settings and Preparation | Configuring DCOM for Remote Debugging | Troubleshooting SQL Debugging Setup

Show:
© 2014 Microsoft