BookmarkSubscribeRSS Feed

Lessons from the SAS 9.4 Deployment Manager (Hotfix, Uninstall, Unconfigure)

Started 2 weeks ago by
Modified 2 weeks ago by
Views 172

Using the SAS Deployment Manager to manage your SAS 9.4 deployment is relatively straightforward. The documentation is comprehensive and the prompts in the application are self-explanatory. Still, there’s always something new to learn in the unlikeliest of places. In this post I’ll be going through some of the SAS Deployment Manager functions I used in the creation of the Implementing Grid Manager on SAS 9.4M8 workshop. We’ll cover the basics of these functions, then I’ll throw in some tips, tricks, or different ways you could use them to accomplish your SAS deployment goals.

 

Applying a Hotfix

 

The Implementing Grid Manager on SAS 9.4M8 workshop I was working on has a non-standard license. There’s a few things about it that are different than what you’d see on a customer site since we need it to fit our specific purposes for education, and one of those things just happened to cause a bug where SAS Foundation couldn’t verify our grid license (which is required to run jobs that leverage grid servers). Luckily, this particular issue has been addressed in a hotfix! Unluckily, this hotfix is not automatically applied as part of the initial deployment. No big deal. We can apply it ourselves.

 

01_RK_Picture-304191736-Picture.png

Select any image to see a larger version.
Mobile users: To view the images, select the "Full" version at the bottom of the page.

 

Selecting “Apply Hot Fixes” takes us through a couple of windows where all you must do is give the SAS Deployment Manager a hot fix package directory (the place where your hotfix is stored) then select and apply the appropriate fix. Of course, prior to this you will have had to download a hotfix, which you can do from the following link: SAS Hot Fix Downloads. When selecting a hotfix from this link there will be instructions on how to install, some are as easy as running the SAS Deployment Manager, and others have some manual steps to be completed after. If you need help finding a hotfix for your environment, then this tool: SAS Hot Fix Analysis, Download and Deployment Tool | SAS Support may be able to help you (provided you’re on SAS 9.3 or SAS 9.4).

 

For my issue I was looking at applying hotfix N3W005. The specifics of the fix aren’t important, but it is important to note that this hotfix requires no extra manual steps after running the SAS Deployment Manager. Applying the fix is easy enough, but I didn’t want my students to have to fire up the SAS Deployment Manager to fix an issue with their environment. So, we can have some fun with response files:

 

"C:\Program Files\SASHome\SASDeploymentManager\9.4\sasdm.exe" -record -responsefile C:\filelocation\N3W005_hotfix_response_file.txt

 

In the command prompt on the windows client, I used a command much like this one to record a “response file” called N3W005_hotfix_response_file.txt (to make it clear to users what it is, but there’s no required naming convention). A response file is just a text output of each parameter you selected while you go through the prompts of the SAS Deployment Manager. Most often you’ll see them used to repeatedly install SAS without having to manually enter the same deployment information each time, but you can make a response file to do anything that the SAS Deployment Manager can do! In this example we make one to apply a single hotfix, but you could apply as many as you want.

 

After running through the prompts: selecting “Apply Hot Fix”, specifying the location of the fix, and applying the appropriate fix (N3W500)... I can give the resulting response file (N3W005_hotfix_response_file.txt) to students in their own environment and have them run this command:

 

"C:\Program Files\SASHome\SASDeploymentManager\9.4\sasdm.exe" -quiet -responsefile

C:\filelocation\N3W005_hotfix_response_file.txt

 

The above command uses the response file I generated to “quietly” run the SAS Deployment Manager in the background, allowing the student to apply the much-needed hotfix in seconds without impacting the flow of their learning. In this way this fix is treated like a prerequisite task, much like downloading required libraries or packages through the command line.

 

There’s more you can do and more to know when applying hotfixes, read the documentation to learn more: SAS Help Center: Apply Hot Fixes outside of an Installation

 

That documentation even details a way to apply a hotfix directly from the command line using the location of the fix as a parameter. I stuck with the response file method because it’s what I know best, but it goes to show that with SAS there's usually more than one solution to a given problem.

 

Uninstalling SAS

 

With SAS 9.4M9 coming up, now is a good time to learn a little bit about uninstalling SAS. Going through the old uninstall-reinstall is a nice backup plan if something goes wrong with an update on your environment. It’s a bit like the classic “turn it off and on again”. Of course, this is more of a last resort, but it’s a great tool to have in the arsenal. Being able to fully eliminate specific SAS products from your system can also be an effective strategy for testing an initial deployment; Should bugs arise you could use the uninstall feature to isolate and identify problems.

 

02_RK_Picture-846657678-Picture.png

 

Much like applying the hotfix, the uninstall process is straightforward. Simply select which products to uninstall and let the SAS Deployment Manager do the work. However, there are additional manual steps to be taken after, which include removing certain SAS directories and configurations. These steps are important because they remove items that stay behind after you uninstall, which could interfere with subsequent SAS deployments.

 

SAS Help Center: Uninstalling Your SAS Software provides the following post-SAS-Deployment-Manager steps:

 

  • On UNIX and z/OS:
    • For the SAS Installer account, delete the directory $HOME/.SASAppData.
    • Delete your SAS installation directory (SASHome).
  • On Windows:
    • Delete your SAS configuration directory (for example, C:\SAS\Config\Lev1).
    • Delete all SAS Windows Start menu shortcuts for the All Users user and the SAS Installer user (for example, delete the SAS directory under C:\Documents and Settings\All Users).
    • Delete the SAS directory under \Users\SAS-Installer-ID\AppData\Local\SAS for the SAS Installer user.
    • Delete the SAS directory under \Users\All Users\AppData\Local\SAS for the All Users user. This removes an additional copy of the sdwpreferences.txt file that might interfere with a subsequent deployment of SAS.
    • Delete the SAS directory under C:\ProgramData. This removes an additional copy of the sdwpreferences.txt file that might interfere with a subsequent deployment of SAS.
    • Delete all SAS services definitions. For more information, refer to your Windows documentation.
    • Delete the following Windows Registry keys:
      • HKEY_LOCAL_MACHINE\SOFTWARE\SAS Institute Inc.\Common Data
      • HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAS Institute Inc.\Common Data

 

You’ll notice that for Unix and most of the Windows steps you’re simply deleting directories. Of note, though, are the two bullets at the end of the round of Microsoft Windows instructions: “Delete service definitions” and “Delete Windows Registry keys”. Deleting SAS service definitions on Windows is fairly tedious. The “services” app (found by typing “services” in the Windows search menu) allows you to see all your service definitions in a nice long list, but you cannot delete them from this app’s UI. I went and created a small loop for use in Windows PowerShell (in administrator mode) to delete all service definitions that start with “SAS”. Assuming you’re doing a full uninstall, this loop should be sufficient... and save some time!

 

Get a list of all services that start with “SAS” for you to check over:

 

Get-Service | Where-Object { $_.Name -like "sas*" } | ForEach-Object {

 

Write-Output "$($_.Name)"

 

}

 

Actual deletion script (handle with care):

 

Get-Service | Where-Object { $_.Name -like "sas*" } | ForEach-Object {

 

sc.exe delete $_.Name

 

}

 

Alternatively, you can delete service definitions one at a time using ‘sc delete “[service name]”’ in the command prompt and ‘Remove-Service -Name "[service name]"’ in PowerShell.

 

For deleting Windows Registry keys you can refer to your windows documentation, but on environments I’m familiar with (Windows 10 and Windows 2022 server) you find the “Registry Editor” app and scroll down to the bottom to see the HKEY_LOCAL_MACHINE\ folder. Then go from there and remove the two keys specified in the SAS documentation. Fair warning: There’s going to be about a million subfolders, but they’re in alphabetical order by default and you’ve got the map to get there in the form of those folder paths.

 

Unconfiguring your SAS Deployment

 

I’m more familiar with those manual steps after the uninstall, but there does exist a “Remove Configuration” option in SAS Deployment Manager that I think could be good to include in this post. There’s no real tip or trick from me here, just a link to the documentation: SAS Help Center: Removing a SAS Configuration and some reasons I can think of to use this function.

 

If you were troubleshooting your environment and a particular SAS product wasn’t working as you’d expect... I might look at the unconfigure option rather than uninstall as a start for fixing issues. Unconfiguring is less potentially damaging when compared to uninstalling, as the documentation for it considers dependencies. Also, unconfiguring stops the product, server, or service selected instead of just removing it. Most associated files are deleted, but you keep log files which might help with testing.

 

There are other reasons to run a “Remove Configuration”, but I’ll let the documentation speak for itself!

 

Related Links:

 

SAS Hot Fix Downloads

 

SAS Hot Fix Analysis, Download and Deployment Tool | SAS Support

 

SAS Help Center: Apply Hot Fixes outside of an Installation

 

SAS Help Center: Uninstalling Your SAS Software

 

SAS Help Center: Removing a SAS Configuration

 

 

Find more articles from SAS Global Enablement and Learning here.

Version history
Last update:
2 weeks ago
Updated by:
Contributors

sas-innovate-white.png

Missed SAS Innovate in Orlando?

Catch the best of SAS Innovate 2025 — anytime, anywhere. Stream powerful keynotes, real-world demos, and game-changing insights from the world’s leading data and AI minds.

 

Register now

SAS AI and Machine Learning Courses

The rapid growth of AI technologies is driving an AI skills gap and demand for AI talent. Ready to grow your AI literacy? SAS offers free ways to get started for beginners, business leaders, and analytics professionals of all skill levels. Your future self will thank you.

Get started

Article Tags