When you attempt to connect to the local server or attempt to run code against the local server, error messages that are similar to the following might occur for SAS Enterprise Guide:
Server Execution Failed
A connection Server "Local" could not be established
If you receive either of these error messages, use the following steps to determine the root cause.
When you perform any of these steps, save the resulting information so that you can share it with SAS Technical Support if needed. Anytime that you need assistance with an error message, contact SAS Technical Support and provide the full error message and the results from the steps in this KB article.
Note Regarding the Microsoft Windows 10 Fall Creators Update for 2017
After you perform the Microsoft Windows 10 Fall Creators Update, SAS Enterprise Guide might not be able to connect to the local server. If SAS Enterprise Guide is unable to connect, first try to launch Base SAS®. If Base SAS launches without error, proceed to the section in this note that is titled "Register Base SAS as the Local COM Server." After completing those steps, you should be able to connect. If you are still unable to connect, contact SAS Technical Support.
Note: The examples that are used here are based on SAS® 9.4.
Examine the SAS® Enterprise Guide® Environment
This environment might display a more detailed message or a different error message that can help you debug the error.
- In SAS Enterprise Guide, select View ► Servers. Expand the Servers list and then expand Local.
- Select Help ► About SAS Enterprise Guide. Then click the Configuration Details link.
- In the Configuration Details dialog box that opens, look for SAS System Command and verify that a value is provided for it. If there is no value for SAS System Command, verify that Base SAS is installed on the machine. Select Start ► All Programs ► SAS ► SAS 9.4.
- If Base SAS is installed, proceed to the section that is titled "Register Base SAS As the Local COM Server."
- If Base SAS is not installed, you must install it for SAS Enterprise Guide to work.
Examine Base SAS®
- Select Start ► All Programs ► SAS ► SAS 9.4, and attempt to launch Base SAS. Check for any errors that occur at start-up, including any that appear in the log window. For SAS Enterprise Guide to function as intended, Base SAS must start without any errors.
- If Base SAS opens without errors, but a connection error still occurs for the local server, use the SAS® Integration Technologies Configuration utility to test the connection between SAS Enterprise Guide and Base SAS.
- Select Start ► All Programs ► SAS ► Utilities ► SAS Integration Technologies Configuration.
- When the utility launches, verify that the Test SAS Servers radio button is selected and click Next. The SAS Integration Technologies Configuration Wizard starts up.
- On the Choose How To Test page of the SAS Integration Technologies Configuration Wizard, verify that the Enter a SAS server definition manually radio button is selected and click Next.
- On the SAS Server page of the SAS Integration Technologies Configuration Wizard, on the Currently Testing menu, verify that the SAS Workspace Server option is selected. On the Connection Protocol menu, select COM. Then click Test.
- If you receive an error, send the full error message to SAS Technical Support.
Register Base SAS® as the Local COM Server
Note: For the following steps, you need administrative rights on your machine.
This section attempts to write the correct SAS® System command to the Windows Registry. Perform these steps at the command prompt.
- Close all open SAS applications, including any pop-up windows.
- Open a Windows command prompt: Click Start and enter cmd. Right-click cmd.exe and select Run as administrator.
- Navigate to your SAS installation directory, which is typically C:\Program Files\SASHOME\SASFoundation\9.4\.
- Run this command: sas.exe /unregserver.
- Now run this command: sas.exe /regserver.
- Attempt to connect in SAS Enterprise Guide to the local server. If you still receive an error, proceed to the next section.
Run the SAS® System Command from the SAS® Enterprise Guide® Configuration Details
In some cases, this section provides additional debugging information. The command that is being run is the same command that SAS Enterprise Guide uses to launch Base SAS. Perform the steps in this section at the Windows command prompt.
NOTE: SAH041001I Server SAS Workspace Server, State, starting
ERROR: IOM Error: COM CoInitializeSecurity failed in dosm with hr=-2147417831
NOTE: SAH049001I Server SAS Workspace Server, State, stopping
- If you see the errors shown above within the SAS window, run the following command during an administrative session at the Windows command prompt. This command resets your TCP/IP stack:
netsh winsock reset
- At the Windows command prompt, run the SAS System command without the -NOTERMINAL option. Your command should look similar to this:
c:\progra~1\sashome\sasfou~1\9.4\sas.exe -config c:\progra~1\sashome\sasfou~1\9.4\sasv9.cfg -objectserver -nologo –noprngetlist
- You might see the following message in the SAS window that pops up: "When the command completes, reboot your system for the change to take effect."
Final Steps
If you still receive any error, contact SAS Technical Support. Include the full error message that you received along with the results that you received from any of the above steps that you performed. Also, attach the SAS Enterprise Guide configuration details by following the steps below.
- Launch SAS Enterprise Guide and select Help ► About SAS Enterprise Guide.
- Click the Configuration Details link.
- Click Copy to Clipboard.
- Paste the configuration details into a blank text editor and attach this file to your Technical Support track.