SAS Viya is the new kid on the block and the future for the SAS platform. It has a blazingly fast in-memory, scalable architecture and is built with developers in mind.
Here are some relevant tips & tricks to help from an app-development perspective.
This is necessary after configuring settings such as whitelisting. Log onto the box as an admin and execute the following commands:
sudo /etc/init.d/sas-viya-all-services stop # open top or htop and kill any redundant / remaining SAS processes sudo /etc/init.d/sas-viya-all-services start
Shared Account and Server re-use¶
Server pooling and the use of a shared OS account are both possible from Viya 3.5 - the documentation is here (and communities articles are available here and here)
If running on the SAS box, first
source /opt/sas/viya/config/consul.conf to set the SSL_CERT_FILE. Next, navigate to
To create your profile (if you haven't done this already) run
./sas-admin profile init.
./sas-admin auth login to authenticate (with your own credentials). Next,
./sas-admin compute credentials create and use the credentials you would like the new compute context to use (the equivalent of the SAS 9
To validate, you should see these creds on the
Now run the following command:
sudo systemctl restart sas-viya-runlauncher-default
Next up, log onto SASEnvironment Manager (as admin user), Contexts, View Compute Contexts. You can either create a new profile, or modify the existing "SAS Job Execution compute context".
Scroll down and add the following attribute / value pairs:
||the user id we used in the
||Time in seconds before the server times out. Will otherwise time out when there are no active sessions. Default is
||Contains the characters that the compute session should remove from any variable that is provided to a job for execution. By default, the following characters are removed: & (ampersand), ” (double quotation mark), ; (semicolon), ’ (single quotation mark), and % (percent sign). If set to "" the feature is disabled.|
With this feature enabled, your end user ID will be
SYS_COMPUTE_SESSION_OWNER instead of
Note - a server restart is not required.
The REST APIs are available here: https://developer.sas.com/apis/rest/.
When navigating the APIs, the returned JSON can be quite difficult to read:
Fortunately, plugins are available for chrome and firefox that can give you "prettified" JSON, like so: