Licensing: How To Apply Licenses
Apply New Licenses (Linux)
Apply New Licenses Using Ansible
You apply a new SAS license when your current license has expired, or when you are adding new SAS products to your deployment. If your deployment was performed using Ansible, you can use Ansible to apply a new license. Ansible applies your new license to the CAS controllers—primary and backup—and also to the SAS programming run-time environment.
- Log on to your Ansible controller machine with a user that meets the requirements in Set Up the User Account that Deploys the Software in SAS Viya for Linux: Deployment Guide.
- Move the current license
files into a backup location.
Copies of your current license files should reside in your Ansible playbook directory (sas_viya_playbook/, by default).
The license files are named, SASViyaV0300_order-number_site-number_Linux_x86-64.jwt and SASViyaV0300_order-number_Linux_x86-64.txt.
- SAS distributes renewal
licenses to customers as file attachments in a renewal order email
(ROE). Make sure that your new license files (a .txt file and a .jwt
file) reside in your Ansible playbook directory.
Note: Some SAS Viya products use the text file (.txt). Other products use the JSON web token file (.jwt). Both SAS Cloud Analytic Services (CAS) and the SAS programming run-time environment use the same license.
- Modify your Ansible
playbook to point to the new license files.
Open sas_viya_playbook/vars.yml, locate
LICENSE_FILENAMEandLICENSE_COMPOSITE_FILENAME, and replace the current license file name with the corresponding new license file name.Note: The JSON web token license file (.jwt) is also referred to as a composite license.Here is an example:
# The name of the license file on the Ansible machine. LICENSE_FILENAME: "SASViyaV0300_09MMMV_Linux_x86-64.txt" # The name of the composite license file on the Ansible machine. # If both files are present, the playbook will use the # composite license file. LICENSE_COMPOSITE_FILENAME: "SASViyaV0300_09MMMV_70180938_Linux_x86-64.jwt" - Run the following Ansible
command for the default inventory file:
ansible-playbook -vvv apply-license.ymlIMPORTANT If you deployed additional CAS servers, run theansible-playbookcommand with the-ioption using the appropriate inventory file.CAS sessions created after you apply the new license automatically update with license information from the new license.
- Verify that your SAS Cloud Analytic Services license has been renewed by following the steps in View SAS Cloud Analytic Services License Information.
- Verify that your SAS programming run-time license has been renewed by following the steps in View SAS Programming Run-Time License Information.
- If you deployed additional CAS servers, then perform Step 5 – Step 6 on your additional controller and your additional backup controller machines.
- If you deployed CAS
servers in a multi-tenant environment, then use the following command
for each tenant that you want to license:
ansible-playbook -i inventory.ini -e "@<tenentID>_vars.yml" utility/apply-cas-tenant-license.yml - If your deployment includes SAS Visual Investigator, you must also perform additional steps described in the SAS Visual Invesitgator documentation.
Apply New Licenses Manually
You apply a new SAS license when your current license is about to expire, or when you are adding new SAS products to your deployment. You must apply your license to all CAS controllers—primary and secondary—and also to the SAS programming run-time environment.
- On the machine where the SAS programming run-time environment is deployed, log on as a user that meets the requirements in Set Up the User Account that Deploys the Software in SAS Viya for Linux: Deployment Guide.
- Move the current license
files into a backup location.
Your current license files reside in /opt/sas/spre/home/SASFoundation/.
The license file is named license.
- SAS distributes renewal
licenses to customers as file attachments in a renewal order email
(ROE). Make sure that your new license files (a .txt file and a .jwt
file) reside in location that is accessible from your SAS programming
run-time machine.
Note: Some SAS Viya products use the text file (.txt). Other products use the JSON web token file (.jwt). Both SAS Cloud Analytic Services (CAS) and the SAS programming run-time environment use the same license.
- Run the following command
to apply the license to your SAS programming run-time environment:
sudo su -s "/bin/sh" -c "/opt/sas/spre/home/SASFoundation/utilities/bin/apply_license /path/SASViyaVrelease-number_order-number_site-number_Linux_x86-64.jwt" saswhere path is the location where the new license file resides.
Here is an example:
sudo su -s "/bin/sh" -c "/opt/sas/spre/home/SASFoundation/utilities/bin/apply_license /opt/sas/installfiles/SASViyaV0300_09MMMV_70180938_Linux_x86-64.jwt" sasYou receive a message that your license has been applied.
- Verify that your SAS programming run-time license has been renewed by following the steps in View SAS Programming Run-Time License Information.
- On the machine where the CAS controller is deployed, log on as a user that meets the requirements in Set Up the User Account that Deploys the Software in SAS Viya for Linux: Deployment Guide.
- Make sure that your
new license files (a .txt file and a .jwt file) reside on your CAS
controller machine in the following directory: /opt/sas/viya/config/etc/cas/default/.
IMPORTANT On machines that contain additional CAS servers, the path for the license file is /opt/sas/viya/config/etc/cas/cas-instance-name.
- Update the symbolic
link for sas_license.txt to point to the new CAS license file. (This
should be the .jwt file.)
Here is an example:
cd /opt/sas/viya/config/etc/cas/default ln -sf SASViyaV0300_09MMMV_70180938_Linux_x86-64.jwt sas_license.txtHere is an example for an additional CAS server:
cd /opt/sas/viya/config/etc/cas/casserver2 ln -sf SASViyaV0300_09MMMV_70180938_Linux_x86-64.jwt sas_license.txtCAS sessions created after you apply the new license automatically update with information from the new license file.
- If you are running a multi-tenant deployment and have multiple CAS servers on a single machine, repeat Step 7 – Step 8 for each tenant instance of the CAS server (for example, /opt/sas/tenant-1/config/etc/cas/default, /opt/sas/tenant-2/config/etc/cas/default, and so on).
- If you have a distributed CAS server, repeat Step 6 – Step 8 for each CAS worker node machine.
- Verify that your SAS Cloud Analytic Services license has been renewed by following the steps in View SAS Cloud Analytic Services License Information.
- If you deployed a CAS backup controller (also referred to as a secondary controller), then perform Step 7 – Step 11 on your backup controller machine.
- If you deployed additional CAS servers, then perform Step 7 – Step 11 on your additional controller and your additional backup controller machines.
- Check the administration documentation for your SAS Viya products in case there are additional steps required for applying a license. Specifically, if your deployment includes SAS Visual Investigator, you must also perform additional steps described in the SAS Visual Invesitgator documentation.
Apply New SAS Data Agent Licenses
SAS Data Agent has special licensing instructions. Apply a new SAS Data Agent license with the following steps:
- Determine which machines are assigned to the DataAgent host group. This information is found in the sas_viya_playbook/inventory.ini file.
- On each of these machines, copy the new text license file to /opt/sas/viya/config/etc/dagentsrv/default/setinit.txt.
- Ensure that ownership of this file is sas:sas and Read and Write permissions are set to mode 660.
- Restart the sas-viya-dagentsrv-default service.
In multi-tenant environments,
repeat these steps for each tenant to update the file at /opt/sas/tenant/config/etc/dagentsrv/default/setinit.txt,
set the owner of the file as the tenant administrator, and restart sas-tenant-dagentsrv-default on
each tenant.
Apply New Licenses (Windows)
You apply a new SAS license when your current license is about to expire, or when you are adding new SAS products to your deployment. The license file is used by both SAS Foundation and SAS Cloud Analytic Services (CAS).
- Log on to the SAS Viya machine as a user that is a member of the Windows Administrators group.
- Move the current license
files into a backup location.
Copies of your current license files should reside in the directory where your SAS Viya deployment scripts were created.
TipIf you followed the recommendation in the SAS Viya for Windows: Deployment Guide your deployment scripts and license files reside underneath \sas\install.The license files are named, SASViyaV0300_order-number_Win_x64_Wrkstn_Srv.jwt and SASViyaV0300_order-number_Win_x64_Wrkstn_Srv.txt.
- SAS distributes renewal
licenses to customers as file attachments in a renewal order email
(ROE). Make sure that your new license files (a TXT file and a JWT
file) reside in the same directory as your SAS Viya deployment scripts.
Note: Some SAS Viya products use the text file (TXT). Other products use the JSON web token file (JWT). Both SAS Cloud Analytic Services (CAS) and SAS Foundation use the same license.
- Change to the deployment
scripts directory, open the file, vars.psd1, and modify the license
file names to match the new license file name.
Here is an example:
COMPOSITE_LICENSE_FILENAME = "SASViyaV0300_09ML1N_70196364_Win_x64_Wrkstn_Srv.jwt" LICENSE_FILENAME = "SASViyaV0300_09ML1N_Win_x64_Wrkstn_Srv.txt" - Run the following command
to apply your new SAS license:
setup.bat -apply-licenseCAS sessions created after you apply the new license are not automatically updated with the new license information. You must restart CAS for the new license to take effect. Note that this behavior is different on Windows and Linux.
- Verify that your SAS Foundation license has been renewed by following the steps in View SAS Programming Run-Time License Information.
- Verify that your SAS Cloud Analytic Services license has been renewed by following the steps in View SAS Cloud Analytic Services License Information.