Notebooks consume resources on the machines running in your ArcGIS Notebook Server site. Because these resources are limited, ArcGIS Notebook Server has administrative settings to restrict their usage.
ArcGIS Notebook Server uses containers—virtualized operating systems—to isolate each notebook author's environment. Containers allow each author to use a subset of your server resources without their work or resource use interfering with others. These containers are allocated and maintained by the Docker component running on your machine.
Each notebook author is allocated one container, which is opened when they open their first notebook. Only the notebook author can work in their container, and the computer resources they use in their container are isolated from other containers.
When the container opens, its virtual operating system and settings are configured through a container image. This is one of two container images you received from Esri.
Included with this container image is a notebook runtime, which is a collection of Python modules and dependencies. The contents of the runtime are available in each notebook that runs in the container.
The container image used depends on the notebook author's privileges in the portal as follows:
- Authors who've been granted the Create and edit notebooks privilege only have their container loaded with the Standard container image. The Standard notebook runtime for their notebooks includes ArcGIS API for Python and several hundred third-party Python libraries.
- Authors who've also been granted the Advanced notebook privilege have their container loaded with the Advanced container image. The default notebook runtime for their notebooks is the Advanced runtime, which includes all modules from the Standard runtime along with ArcPy and its related libraries. They have the option to specify an individual notebook's runtime and can use either the Standard or the Advanced runtime in their notebooks.
By default, a container is allocated a certain amount of RAM and a certain number of CPU core shares. These default resource limits are determined by the runtime being run by the container as follows:
- The Standard runtime allots 1 CPU core and 4 GB of RAM per container.
- The Advanced runtime allots 2 CPU cores and 6 GB of RAM per container.
As an ArcGIS Notebook Server administrator, monitor the number of notebook authors working in your site and which runtime each is using. Depending on these factors, you may need or want to change the resource limits set for ArcGIS Notebook Server.
On Linux deployments of ArcGIS Notebook Server, the Docker Engine on your machine has access to all of the CPU cores and disk space on your machine.
Update the resources used by each runtime
As an administrator, you can update the maximum CPU and memory that's available per container by changing the resources that each notebook runtime uses by default. If there are multiple users authoring notebooks concurrently, you can monitor your site's usage and adjust these settings as necessary using ArcGIS Notebook Server Manager.
- Sign in to your ArcGIS Enterprise portal as an administrator and open ArcGIS Notebook Server Manager.
- Open the Settings page and click Runtimes.
- Select the runtime with the resource limits you want to update, and click the Edit icon.
- Update the Max CPU (in cores) and/or Max memory (in GB) values for the runtime.
- Click Save to confirm the update.
Monitor your running containers
Because each container in your ArcGIS Notebook Server site uses computing resources while running, you should regularly monitor the active containers in your site and their level of activity. You can use resources in the ArcGIS Notebook Server Administrator Directory to view information about your site's running containers and notebooks.
For a quick view of each container, you can also use ArcGIS Notebook Server Manager.
There is a known failure when accessing container statistics through the ArcGIS Notebook Server Administrator Directory or Manager. You can use the docker stats command from a terminal on your Notebook Server machine to get Docker container statistics. For more information, see the Docker documentation.
If a running container has not been used recently, or if you know its owner has completed their work with notebooks, you can use the directory to terminate the container. Doing so will not delete the notebook portal items and does not prevent the portal member from opening a new container. The terminated container will no longer consume memory or CPU.
- Sign in to the ArcGIS Notebook Server Administrator Directory. The URL is formatted https://notebookserver.domain.com:11443/arcgis/admin.
- Browse to system > containers.
The containers resource page lists each running container, with the user name of the portal member who owns the container shown in parentheses.
- Click a container link to open its information resource.
On the container's resource page, you can view information about it.
- Click Container Sessions to view a list of notebooks running in the container.
Each notebook has one kernel, which serves as its computation engine for all operations. Note the value given for each kernel's last_activity; this timestamp indicates how recently each notebook has been accessed, run, or edited.
- If you identify a container that is running but is unused, consider terminating it. Optionally, from the container's resource page, click Terminate Container, and confirm the operation.
This stops and destroys the running container; it's an irreversible operation. The next time that the portal member opens an ArcGIS Notebook, a new container will open.