2 Get Started: Installation
This chapter outlines the minimum steps to install RStudio Package Manager. More information on each step is available in subsequent chapters. Your environment will likely require one or more additional steps.
2.1 Need Help?
RStudio is happy to provide support for anyone using the product.
To focus on building the best products, RStudio does not provide installation or professional services. If you require such assistance, please refer to our certified partners.
RStudio support is limited to our professional products. If your question is related to R, R code, or specific R packages, please visit https://community.rstudio.com.
If your question is related to RStudio Package Manager, you can open a support ticket by:
- Running the command
/opt/rstudio-pm/bin/run-diagnostics. Note, if you have not been able to download the software, skip this step. If you unpacked the software in a non-default location, navigate to that directory and use
- If the cause of the problem is not evident to you, send an email to firstname.lastname@example.org with:
- Your name and company
- Your goal
- What you have tried
- The current error
- The diagnostics output from step 1
RStudio support is via email, see our SLA for details.
Please review the necessary system requirements, account privileges, and internet access requirements prior to installing RStudio Package Manager.
2.2.1 System Requirements
- Red Hat Enterprise Linux/CentOS Linux 6.0+
- Red Hat Enterprise Linux/CentOS Linux 7.0+
- SUSE Enterprise Linux 12 SP3+
- Ubuntu 14.04
- Ubuntu 16.04
- Ubuntu 18.04
RStudio Package Manager should run on a server with a minimum of 2GB of RAM. Package sources can be lazily cached from CRAN or eagerly downloaded. RStudio Package Manager recommends 50-200GB of disk storage.
2.2.2 Internet Access Requirements
RStudio Package Manager acts as a “bridge” between offline servers running R and upstream package sources like CRAN. RStudio Package Manager should be installed on a server in the network with outbound access to:
See Repository Syncing for more details on what information is downloaded from the RStudio CRAN service.
RStudio Package Manager can be configured to use a HTTP proxy to access the internet, see Outbound Proxy for more details.
Additional steps are necessary if your internal servers can not access an online server through your internal network. See the appendix on running RStudio Package Manager in an air-gapped environment.
2.2.3 Root Requirements
RStudio Package Manager does not run as root, see 2.2.4. By default, root privileges are required to:
- Install RStudio Package Manager
- Start and Stop RStudio Package Manager via the service daemons
- Activate the RStudio Package Manager license
RStudio Package Manager can be installed and licensed without requiring root privileges. Instructions are available in the appendix.
2.2.4 RunAs User
RStudio Package Manager starts and runs under an unprivileged account. It never requires root.
The installer creates a user account and group named
rstudio-pm and runs the
RStudio Package Manager service under this account. If you wish to change the
account under which the service runs, please see C.
Download and install RStudio Package Manager for your platform. These
commands will install the product into
/opt/rstudio-pm. See E to install
into a non-default location or to perform a non-root install.
# for ubuntu sudo apt-get install gdebi-core wget https://s3.amazonaws.com/rstudio-package-manager/rstudio-pm_1.0.0-7.deb sudo gdebi 1.0.0-7.deb
# for redhat and centos wget https://s3.amazonaws.com/rstudio-package-manager/rstudio-pm-1.0.0-7.x86_64.rpm sudo yum install --nogpgcheck rstudio-pm-1.0.0-7.x86_64.rpm
# for suse wget https://download-url/rstudio-pm-1.0.0-7.x86_64.rpm sudo zypper --no-gpg-checks install rstudio-pm1.0.0-7.x86_64.rpm
2.4 Initial Configuration
RStudio Package Manager settings are controlled by a configuration file located
/etc/rstudio-pm/rstudio-pm.gcfg by default. At a minimum, complete the
Address property within the
Server section, by specifying the URL used to
access RStudio Package Manager.
; /etc/rstudio-pm/rstudio-pm.gcfg [Server] Address = http://r-packages.example.com
http://r-packages.example.com with the value appropriate to your
There are many other default options you may want to configure now or at a later point, such as:
- The on-disk location where data will be stored, default:
- The database where essential metadata should be stored, default: built-in SQLite.
- Important security settings settings such as HTTPS certificates and ports, default: HTTP on port 4242.
For multi-node or highly available (HA) setups, please refer to the REQUIRED config settings listed at 12.
Verify the status of your license using:
If you have a license key, activate the license using
/opt/rstudio-pm/license-manager activate LICENSE_KEY
LICENSE_KEY with the value of your license key. If your server is
offline or you need more information, consult 2.5.
2.6 Restart RStudio Package Manager
After changing the configuration file or license you must restart the RStudio Package Manager service. Follow the instructions for your operating system:
# for Ubuntu 16.04, Ubuntu 18.04, RHEL/CentOS 7, SUSE 12 sudo systemctl stop rstudio-pm sudo systemctl start rstudio-pm
# for Ubuntu 14.04 and REHL/CentOS 6 sudo stop rstudio-pm sudo start rstudio-pm
2.7 Visit the web UI
You should be able to visit RStudio Package Manager in a web browser. The
default port is 4242, so navigate to:
RStudio Package Manager should present a welcome page, though no repositories
are yet available.
2.8 Try out the CLI
You should be able to invoke the admin CLI by running:
/opt/rstudio-pm/bin/rspm list. If you are not able to use the CLI, ensure
your user is a member of the
sudo usermod -aG rstudio-pm USER, replacing
USERwith your username. This command will add
- Close the terminal or SSH session and begin a new session.
- In the new session, run the command
groupsto enumerate the groups the current user is a member of. Confirm that
- Re-run the command:
Note, you can elect a different group to grant access to the CLI, see C.
2.9 Next Steps
Now that RStudio Package Manager is installed, you can complete the second part of the setup by configuring RStudio Package Manager for your desired use case. Follow the instructions in Get Started: Configuration.