{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "bcdbec86",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-10-02T14:46:56.912063Z",
     "iopub.status.busy": "2026-10-02T14:46:56.911792Z",
     "iopub.status.idle": "2026-10-02T14:46:56.916917Z",
     "shell.execute_reply": "2026-10-02T14:46:56.916268Z"
    },
    "papermill": {
     "duration": 0.008218,
     "end_time": "2026-10-02T14:46:56.917585+00:00",
     "exception": false,
     "start_time": "2026-10-02T14:46:56.909367+00:00",
     "status": "completed"
    },
    "tags": [
     "remove-input",
     "active-ipynb",
     "remove-output"
    ]
   },
   "outputs": [],
   "source": [
    "try:\n",
    "    from openmdao.utils.notebook_utils import notebook_mode  # noqa: F401\n",
    "except ImportError:\n",
    "    !python -m pip install openmdao[notebooks]"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "9da48c23",
   "metadata": {
    "papermill": {
     "duration": 0.001004,
     "end_time": "2026-10-02T14:46:56.919675+00:00",
     "exception": false,
     "start_time": "2026-10-02T14:46:56.918671+00:00",
     "status": "completed"
    },
    "tags": []
   },
   "source": [
    "# Quick Reference: OpenMDAO-Related Environment Variables\n",
    "\n",
    "In some cases, the way in which OpenMDAO operates is up to the preferences of the user.\n",
    "At this time, rather than using a preferences file, these optional OpenMDAO behaviors are based on the values of environment variables.\n",
    "\n",
    "Some of these environment variables are interpreted as either being \"truthy\" or \"falsey\".\n",
    "For OpenMDAO, an environment variable is considered `False` if it takes on one of the following values:\n",
    "- '0'\n",
    "- 'false'\n",
    "- 'no'\n",
    "- 'off'\n",
    "- 'none'\n",
    "- ''\n",
    "\n",
    "These are all string values and OpenMDAO interprets them in a case-insensitive way.\n",
    "Note that, for OpenMDAO, the empty string means that an unset environment variable will be interpreted as `False`.\n",
    "\n",
    "**Any other environment variable value other than those above is interpreted as `True`**.\n",
    "\n",
    "## User-Facing Environment Variables\n",
    "\n",
    "| Environment Variable | Description | See Also |\n",
    "| --- | --- | --- |\n",
    "| OPENMDAO_INVALID_DESVAR_BEHAVIOR | Specifies default driver behavior if the initial design variables are out of bounds. | [Paraboloid](examples_paraboloid:specifying_initial_values) |\n",
    "| OPENMDAO_REPORTS | May be boolean-like or the names of the desired reports to be generated. | [Reports](features:reports:report_system:controlling_reporting_using_an_environment_variable) |\n",
    "| OPENMDAO_USE_MPI | Set to True to force an exception when MPI is needed but mpi4py is unavailable. | [Controlling MPI](features:debugging:controlling_mpi) |\n",
    "| OPENMDAO_WORKDIR | Top-level directory for OpenMDAO outputs. Defaults to current working directory if not set. | [Reports System](reports_system:directory) |\n",
    "| OPENMDAO_NO_RELEVANCE | Turns off relevance. Sometimes useful when debugging OpenMDAO internals. |  |\n",
    "| OPENMDAO_DUMP | Dumps trace information and/or output of om_dump function to file, optionally by rank and/or PID. |  |\n",
    "| OPENMDAO_DISABLE_RICH | Prevents OpenMDAO from using colorized output with the rich python package. |  |\n",
    "| USE_PROC_FILES | Set to True to cause stdout/err from each MPI process to be written to `[rank].out`. | [Controlling MPI](features:debugging:controlling_mpi) |\n",
    "| OMPI_MCA_rmaps_base_oversubscribe | Set to '1' to fix **there are not enough slots available in the system** issue for some versions of MPI. | [Controlling MPI](features:debugging:controlling_mpi) |\n",
    "| OMPI_MCA_btl=self,tcp | Set to 'self,tcp' to fix **A system call failed during shared memory initialization that should not have...** error in some version of MPI | [Controlling MPI](features:debugging:controlling_mpi) |\n"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "1d527540",
   "metadata": {
    "papermill": {
     "duration": 0.001074,
     "end_time": "2026-10-02T14:46:57.040263+00:00",
     "exception": false,
     "start_time": "2026-10-02T14:46:57.039189+00:00",
     "status": "completed"
    },
    "tags": []
   },
   "source": []
  }
 ],
 "metadata": {
  "celltoolbar": "Tags",
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.13.14"
  },
  "papermill": {
   "default_parameters": {},
   "duration": 1.00698,
   "end_time": "2026-10-02T14:46:57.256365+00:00",
   "environment_variables": {},
   "exception": null,
   "input_path": "/home/runner/work/OpenMDAO/OpenMDAO/openmdao/docs/openmdao_book/other_useful_docs/environment_vars.ipynb",
   "output_path": "/home/runner/work/OpenMDAO/OpenMDAO/openmdao/docs/_executed_book/other_useful_docs/environment_vars.ipynb",
   "parameters": {},
   "start_time": "2026-10-02T14:46:56.249385+00:00",
   "version": "2.7.0"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}