BookmarkSubscribeRSS Feed

Keeping the SAS Administration Command-Line interfaces up-to-date

Started ‎11-25-2019 by
Modified ‎11-25-2019 by
Views 3,799

The sas-admin command-line interface ships with Viya software. But you don't need to create whole new Viya deployment to get updates. The latest version is available for download from In this post I will review how to check what updates are available, and install and update the downloadable version of the command-line interface.


You can download the command-line interface(CLI) from There are versions for Linux, Mac, and Windows. I keep the Windows version on my laptop so that I can connect to various SAS Viya environments and perform administrative tasks. When there are updates, I download a new version and unzip it to a directory on my laptop.


Getting an updated executable is just the first step. The sas-admin executable is the wrapper; the main functionality of the CLI is surfaced via plug-ins. You can use the CLI to check on the status of your local plug-ins, add new plug-ins, and update existing plug-ins. Plug-ins are installed from a repository. To see what repository you are configured to use, run the command.


sas-admin.exe plugins list-repos



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


This is the default SAS hosted repository. If you navigate to the url, you can see information on the plug-ins available in the repository.


You can check the status of your locally installed plug-ins using the following command.


sas-admin plugins list-repo-plugins


The command outputs all the plug-ins available in the repository and also compares them to the plugins installed locally. In the output of the command plug-ins are flagged with an indicator that reflects their status:

  • asterix( *) : plugin is installed locally and the version in the repository is the same as the version installed
  • accent (^): plugin is installed locally and the version in the repository is more recent than the version installed
  • no indicator the plugin is available in the repository but has not been installed locally.




In my environment the output shows:

  • not installed dataexplorer, fonts and job
  • updates available authorization, folders and identities
  • up-to-date audit, cas, configuration, licenses, qkbs and reports

To install a new plug-in, for example fonts, use the install command:


sas-admin plugins install --repo SAS fonts




It is the same command to update a plugin, but the output is a little different as it provides information about the versions it is upgrading from and the new version.


sas-admin plugins install --repo SAS authorization




The output indicates that the authorization plug-in was updated from version 1.2.1o to 1.2.18


The plug-ins are installed, by default, in the .sas sub-directory of the users home directory.


You can only install one plug-in at a time but some simple shell scripting allows you to install or update all plug-ins from a particular repository. Change directory to the directory where you installed the sas-admin executable and then run the code.




cd /opt/admincli082018
for p in $($PWD/sas-admin plugins list-repo-plugins | awk 'NR > 3 { print $1 }' )
$PWD/sas-admin plugins install --repo SAS ${p#"*"}


On WINDOWS (thank you Gilles Chrzaszcz for the Windows scripting)


cd c:\admincli082019
for /F "skip=3 delims= " %i in ('%cd%\sas-admin.exe plugins list-repo-plugins') do (for /f "tokens=1* delims=^*" %j in ('echo %i') do %cd%\sas-admin.exe plugins install -repo SAS %j))


The plug-ins are backward and forward compatible, and can be updated more often than Viya releases. It can be very useful to grab the latest version. To see how to use the CLI checkout my previous article.


For me, the impetus to upgrade was new functionality in the folders plug-in which can now list the root level Viya folders.


sas-admin --output text folders list-members --path /




The SAS Administration CLI is a great feature of the Viya software and new functionality is being added all the time. I hope you found this post useful. For more information on using the CLI, check out the following:

Version history
Last update:
‎11-25-2019 07:19 PM
Updated by:



SAS is headed back to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team.

Interested in speaking? Content from our attendees is one of the reasons that makes SAS Innovate such a special event!

Submit your idea!

Free course: Data Literacy Essentials

Data Literacy is for all, even absolute beginners. Jump on board with this free e-learning  and boost your career prospects.

Get Started

Article Tags