Licensing FAQ
On this page
- Do I have to switch to license files? Can I continue to activate with my key?
- What do I need to know about file permissions and location on my servers?
- How do I use the license file in containers?
- I’m currently using a floating license. What are my next steps to switch to a license file?
- I’m currently using a traditional license key. What are my next steps to switch to a license file?
- How do I renew a server activated with a license file?
- How to tell if my license file is correct or if there is something wrong with my license file?
- I’m running in an HA or load-balanced environment, how do I apply the license file there?
- How can licensing fail when using a license file?
- Do I need to restart my server to pick up a license file change?
- Can I use a license file for Posit Workbench in AzureML or Posit Workbench for Google Cloud Workstations?
This page provides answers for frequently asked questions (FAQs) and solutions related to product licensing across Posit enterprise and hosted products.
This section applies to servers activated with license files. Posit denotes license files with the name in the following format:
<expiration-date>_<product-code>_<organization>_<license-key>.lic
Do I have to switch to license files? Can I continue to activate with my key?
While you receive both a license key and a license file with every new purchase, expansion, or renewal, license files are the recommended method for activation. License files reduce the chance of unexpected expiration and activation issues caused by network issues in customer environments. They’re also much more resilient when used in ephemeral, container-based, or air-gapped environments, and resolve the need for floating license servers. Read more about license files in the License File Activation for Posit Products white paper.
While Posit recommends activation via license files, other methods for activation using license keys is still supported.
What do I need to know about file permissions and location on my servers?
To activate via a license file, the *.lic
file must be present in the /var/lib/<rstudio-product>
directory, where <rstudio-product>
is one of rstudio-server
, rstudio-connect
, or rstudio-pm
depending on the product installed.
This file must be readable by the root user and the RunAs1 service user defined for the product. By default, the RunAs2 user is rstudio-server
for Posit Workbench and rstudio-pm
for Posit Package Manager, but the customer can modify these.
Posit Connect always runs as the root user, so it’s the only user that needs access to the license file as described in the Posit Connect Admin Guide. We recommend using 0600
permissions to ensure only those service users can read the file.
If your permissions are incorrectly set, you may receive log messages indicating that there was an error verifying your license activation. The Errors in verifying the license activation section describes this error and its solution.
How do I use the license file in containers?
There are multiple ways to apply the license file to a container. Posit recommends mounting the license file at runtime with Docker, or to mount a secret in Kubernetes with the contents of the license file. This is the usual way of including a file into a container at runtime. Then, refer to the file’s location in an entry-point script that specifies the license file and launches the product. An alternative method is to place the license file on a network share. Many product instances can load it from there. Securely store the license file so unprivileged users can’t read it.
If you are using Posit Docker images, use the following environment variables:
RSW_LICENSE_FILE_PATH
: Set the variable to the location of the attached license file, which is accessible to your container, e.g., /etc/rstudio-server/license.lic
.
RSC_LICENSE_FILE_PATH
: Set the variable to the location of the attached license file, which is accessible to your container, e.g., /etc/rstudio-connect/license.lic
.
RSPM_LICENSE_FILE_PATH
: Set the variable to the location of the attached license file, which is accessible to your container, e.g., /etc/rstudio-pm/license.lic
.
If you are using Posit Helm charts, follow the recommended procedures in each product’s README:
For Docker images, the Helm templates set the product-specific variables mentioned above.
I’m currently using a floating license. What are my next steps to switch to a license file?
If you are currently using a floating license server, the license is no longer activated on a separate floating license server. Instead, the license activates directly on the Posit product host server.
To renew your activation using a license file, first transfer the new license file to the Posit product host server. Then, perform the following steps with slightly different commands per product to turn off activations through the floating license server:
Modify the product-specific configuration file so that the
<license type>
variable islocal
instead ofremote
. This forces the server to look for a local key activation instead of the activation coming from a lease with the floating license server.Clear the floating license server information out of the license-manager (run only the commands relevant to your Posit product to disable floating license activation):
Modify the
server-license-type
value in/etc/rstudio/rserver.conf
to belocal
instead ofremote
:/etc/rstudio/rserver.conf
server-license-type=local
Run the following command to remove any record of the floating license server from the Posit Workbench host server:
sudo rstudio-server license-manager clear-license-server
Modify the
Licensing.LicenseType
value in/etc/rstudio-connect/rstudio-connect.gcfg
to belocal
instead ofremote
:/etc/rstudio-connect/rstudio-connect.gcfg
[Licensing] LicenseType = local
Run the following command to remove any record of the floating license server from the Posit Connect host server:
sudo /opt/rstudio-connect/bin/license-manager clear-license-server
Modify the
Licensing.LicenseType
value in/etc/rstudio-pm/rstudio-pm.gcfg
to belocal
instead ofremote
:/etc/rstudio-pm/rstudio-pm.gcfg
[Licensing] LicenseType = local
Run the following command to remove any record of the floating license server from the Posit Package Manager host server:
sudo /opt/rstudio-pm/bin/license-manager clear-license-server
Finally, run the license file activation commands for your product. These commands are available in each product’s respective administration guide using the following links:
After successfully activating all product host servers that your floating license server provided activation leases for with a license file, you are free to decommission your floating license server.
I’m currently using a traditional license key. What are my next steps to switch to a license file?
To renew your activation using a license file:
Transfer the updated license file to the Posit product host server.
Then, follow the procedures in the product guides linked below to remove the record of the license key’s activation from the server:
Once the previous license has been successfully deactivated, run the activation commands for your product. These commands are available in each product’s respective administration guide using the following links:
How do I renew a server activated with a license file?
To renew your activation using a license file, first transfer the new license file received from Posit during renewal to the Posit product host server. Then, run the following command to remove the old license file from the server location:
rm /var/lib/<rstudio-product>/<old-license-file>.lic
Where <rstudio-product>
is one of rstudio-server
, rstudio-connect
, or rstudio-pm
, depending on the product installed.
Run the activation commands for your product after removing the file. These commands are available in each product’s respective administration guide using the following links:
How to tell if my license file is correct or if there is something wrong with my license file?
Confirm the format of your license file by the output from running the cat
command:
-----BEGIN RSTUDIO LICENSE-----
<some lines of encrypted text> -----END RSTUDIO LICENSE-----
Since the file contains encrypted text, you may not notice anything is wrong with your license file unless you encounter an error during activation. The license file reports missing information section covers the most common issues for a corrupt license file.
I’m running in an HA or load-balanced environment, how do I apply the license file there?
d
Apply the license file to each server instance within your cluster, just as you would with a traditional license key. The following links to each product’s respective administration guides provide the activation commands:
How can licensing fail when using a license file?
The license file reports missing information
Reported error:
Error reading license file: (29): The license file is missing information.
Likely cause:
Commonly, the error displays if the file contains incorrect extra line terminators when opening the file on a Microsoft Windows machine.
The output from the file command can confirm this:
file rdp1.lic
rdp1.lic: ASCII text, with CRLF line terminators
The license file should return the following:
file rdp2.lic
rdp2.lic: ASCII text
Solution:
Attempt to redownload the file sent with your licenses to get a fresh copy of the file or use the dos2unix
command (installed on Ubuntu with sudo apt install dos2unix
) to fix the line endings.
Errors in verifying the license activation
Reported error:
ERROR Error verify: (19): The product is activated however the license manager is currently unable to connect to the license server to verify the activation.
Likely cause:
This is a common indication that something is amiss with your file permission or file ownership settings for the license file located in the /var/lib/<rstudio-product>
directory.
Solution:
Configure your permissions so both root and the product’s RunAs3 service user can read the license file in the /var/lib/<rstudio-product>
directory. The What do I need to know about file permissions and location on my servers? section describes this.
License files hosted on a network share drive have an unexpected expiration
Reported error:
Unexpected messages in the logs indicating that your license has expired despite having a valid license file hosted on a network drive and symbolically linked into the /var/lib/<rstudio-product>
directory.
Likely cause:
The license file location is on a networked location rather than stored locally on the Posit product server host and the connection to the networked location terminates.
Solution:
Locally diagnose why the networked location terminates and ensure that the /var/lib/<rstudio-product>/<license-file>.lic
file is available before the Posit product instance start.
Unexpected expiration when there is a valid license key applied to the server but an expired license file exists
Reported error:
Unexpected messages in the logs indicating that your license has expired despite having activated with a valid license key.
Likely cause:
Your Posit product server has previously activated with a license file that expired, but you’re attempting to renew the server with a valid license key. The presence of a license file in the /var/lib/<rstudio-product>/
directory always overrides other activation methods (e.g., activation via a license key). A server with an expired license file always presents the activation status of the license file, not the valid license key.
Solution:
Remove the old license file from the server location using the following command:
rm /var/lib/<rstudio-product>/<old-license-file>.lic
and then restart the server.
Where <rstudio-product>
is one of rstudio-server
, rstudio-connect
, or rstudio-pm
, depending on the product installed.
This removes the expired license file from the server and allows the updated license key to activate the Posit product.
Do I need to restart my server to pick up a license file change?
To pick up any licensing change, Posit enterprise products require a restart, including when using or moving to license files.
Can I use a license file for Posit Workbench in AzureML or Posit Workbench for Google Cloud Workstations?
No, these products continue to use license keys on these platforms.
Footnotes
The method to modify the RunAs user setting varies depending on the Posit Team product. By default, the RunAs user is
rstudio-server
for Posit Workbench andrstudio-pm
for Posit Package Manager.The Posit Connect service always runs as the
root
user, so it’s the only user that needs access to the license file as described in the Posit Connect Admin Guide.↩︎The method to modify the RunAs user setting varies depending on the Posit Team product. By default, the RunAs user is
rstudio-server
for Posit Workbench andrstudio-pm
for Posit Package Manager.The Posit Connect service always runs as the
root
user, so it’s the only user that needs access to the license file as described in the Posit Connect Admin Guide.↩︎The method to modify the RunAs user setting varies depending on the Posit Team product. By default, the RunAs user is
rstudio-server
for Posit Workbench andrstudio-pm
for Posit Package Manager.The Posit Connect service always runs as the
root
user, so it’s the only user that needs access to the license file as described in the Posit Connect Admin Guide.↩︎