Jaa


How to Grant Permissions for Running Scripts

When a project is configured to run "Before and After" scripts, these scripts may fail with the error "Access is denied". This will occur if the following conditions are true:

  • Before Send and After Send scripts. The staging project is being started from a remote computer and the user starting the project is not an administrator on the remote computer.

  • Before Receive and After Receive scripts. The staging project is connecting to the destination server by using the credentials of a user who is not an administrator on the destination server.

These scripts are run by using Cmd.exe. By default, only administrators or the user who is signed in to the system can run this executable.

You must explicitly grant "Read & Execute" permission to Cmd.exe if the user in question is the user who tries to start the project remotely, or if that user runs the project or the credentials specified in the project for connecting to the destination server.

A similar problem may occur when you try to execute VBScript scripts if Cscript.exe is the default script host on the server. If this is the case, replace Cmd.exe with Cscript.exe in the following procedure.

To grant permissions for running scripts on the local computer

  1. In Internet Explorer, open %windir%\system32 (for example, C:\WINDOWS\System32).

  2. In the Details pane, right-click cmd.exe, and then click Properties.

  3. In the cmd.exe Properties dialog box, on the Security tab, click Add.

  4. In the Select Users, Computers, or Groups dialog box, in the Enter the object names to select box, type the name of the user to whom you want to grant permissions, and then click OK.

  5. In the cmd.exe Properties dialog box, on the Security tab, in the Permissions for Administrators box, select the Allow check box for Read & Execute, and then click OK.

See Also

Other Resources

How to Add a Script File to a Staging Project

Changing the Script Files for a Staging Project