# Ood shell inactive timeout

**URL:** <https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490>\
**Category:** Get Help\
**Created:** [August 25, 2025, 7:12pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490 "2025-08-25T19:12:12Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![fangpingmu](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/fangpingmu/32/532_2.png) [@fangpingmu](https://discourse.openondemand.org/u/fangpingmu)\
**Post date:** [August 25, 2025, 7:12pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/1 "2025-08-25T19:12:12Z")

</div>

OnDemand version: 4.0.6

[fangping@ondemand shell]$ pwd  
/etc/ood/config/apps/shell  
[fangping@ondemand shell]$ cat env

# /etc/ood/config/apps/shell/env

OOD\_SHELL\_INACTIVE\_TIMEOUT\_MS=600000

The connection to the shell session has been terminated in \< 1 minute. How can I increase the ood shell inactive timeout?

 ![Screenshot 2025-08-25 at 3.02.09 PM](https://us1.discourse-cdn.com/flex015/uploads/osc/original/2X/0/0dd45ec02276a0f89c6097d5e2e072b1871ded2d.png)

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [August 25, 2025, 7:17pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/2 "2025-08-25T19:17:14Z")

</div>

You have to enable ping pongs by setting the `OOD_SHELL_PING_PONG` environment variable. Otherwise, they’re disabled entirely.

> **[Customizations — Open OnDemand 4.0.0 documentation](https://osc.github.io/ood-documentation/latest/customizations.html#enable-and-configure-shell-ping-pong)**

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [August 26, 2025, 11:53am UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/3 "2025-08-26T11:53:53Z")

</div>

> [@jeff.ohrstrom](#):
>
> [Customizations — Open OnDemand 4.0.0 documentation](https://osc.github.io/ood-documentation/latest/customizations.html#enable-and-configure-shell-ping-pong)

We started to have this same issue recently. We have the time outs and the ping pongs enabled but it still is timing out rather quickly.

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [August 26, 2025, 5:14pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/4 "2025-08-26T17:14:22Z")

</div>

@DartCleek can you share your configurations? The timeout setting is in milliseconds not seconds - just an off the top guess as to what your issue may be.

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [August 26, 2025, 5:45pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/5 "2025-08-26T17:45:35Z")

</div>

Hey Jeff,

This did work for a period of time but we are not sure exactly when it broke.

We originally had the file in /etc/ood/config/apps/shell  
We have temporarily renamed the old directory to what you see below with shell being deleteme\_shell

[~]$ cat /etc/ood/config/apps/deleteme\_shell/env  
OOD\_SSHHOST\_ALLOWLIST=“redacted”  
OOD\_DEFAULT\_SSHHOST=“redacted”  
OOD\_SSH\_WRAPPER=/var/www/ood/apps/sys/shell/ssh-kerb

OOD\_SHELL\_INACTIVE\_TIMEOUT\_MS=3600000 # 1 hour  
OOD\_SHELL\_MAX\_DURATION\_MS=36000000 # 10 hours  
OOD\_SHELL\_PING\_PONG=true

We currently have the shell app at /var/www/ood/apps/sys/shell, and its environment settings are stored in a .env.local file there, not an env. Should we put those environment variables into an env file?

[rci8@]$ cat .env.local  
OOD\_SSHHOST\_ALLOWLIST=“\redacted”  
OOD\_DEFAULT\_SSHHOST=“redacted”  
OOD\_SSH\_WRAPPER=/var/www/ood/apps/sys/shell/ssh-kerb

OOD\_SHELL\_INACTIVE\_TIMEOUT\_MS=3600000 # 1 hour  
OOD\_SHELL\_MAX\_DURATION\_MS=36000000 # 10 hours  
OOD\_SHELL\_PING\_PONG=true

We had things working originally. At some point in the last month or two it times out very quickly.  
Initially the env file was in /etc/ood/config/apps/shell.  
We recently moved each app into its own git repository. That change broke some things; we have since fixed parts of it.  
After the change, we experimented and put the env file back in different places, but we didn’t notice the change that caused the timeout.

The OOD documentation directs us to use the /etc but for some reason we’re using /var. Not sure what the difference between the 2, we have all of our interactive apps under the  
/var/www/ood/apps/sys/shell

We’re not sure which location is authoritative for customizations. I wonder if the environment settings needed by the dashboard, shell, job composer, desktop, etc., should be placed in an env file under /etc/ood/config/apps/shell (system configuration), rather than inside /var/www/ood/apps/sys/shell/.env.local (app-local file).

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [August 26, 2025, 5:50pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/6 "2025-08-26T17:50:44Z")

</div>

The correct path is `/etc/ood/config/apps/shell/env` - you seem to have `deleteme_shell` folder which is incorrect.

Do not use `.env.local` in the `/var/www` path as this will be overwritten when you update OOD. Same goes for the shell wrapper - that will be deleted when you upgrade as well.

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [August 28, 2025, 5:24pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/7 "2025-08-28T17:24:56Z")

</div>

Thanks Jeff,

One of my colleagues did that because all of our apps are in the /var/www directory and we had did a move to put them in git. We had renamed the shell directory to deleteme\_shell in case we needed stuff there. Thank you!! I’ll bring this back to my team.

Edited to add we tried this again to just make sure, and we still time out within about 1minute to 90 seconds.

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [August 28, 2025, 8:48pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/8 "2025-08-28T20:48:36Z")

</div>

If you have the correct settings in `/etc/ood/config/apps/shell/env`, then I would look at the permissions of the file and ensure they’re readable by regular users.

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [August 29, 2025, 12:38pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/9 "2025-08-29T12:38:08Z")

</div>

> [@jeff.ohrstrom](#):
>
> /etc/ood/config/apps/shell/env

We did that, the file is readable by all. This worked for awhile but we’re not sure exactly when it broke. Sometime within the last 4-6 weeks

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [August 29, 2025, 1:05pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/10 "2025-08-29T13:05:26Z")

</div>

OK so if permissions are correct then I guess I’d have to confirm the contents of the file.

Also note that the login server could be kicking you off. As in, the ssh settings on the login server itself preclude you from keeping the connection open.

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [August 29, 2025, 6:18pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/11 "2025-08-29T18:18:43Z")

</div>

Thanks. Wouldn’t that happen when we were directly ssh’ed into the server without using OOD?  
I normally stay ssh’ed into the server for several hours and do not get kicked off. So I don’t think its the login server. I think we have an idea because we recently had moved a lot of our apps into git repositories, but not the shell so we’re going to do a rollback. Could this be a version issue with ood 4.0.6?

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [August 29, 2025, 7:31pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/12 "2025-08-29T19:31:19Z")

</div>

> [@DartCleek](#):
>
> Wouldn’t that happen when we were directly ssh’ed into the server without using OOD?

Yes, but I’m just tossing out guesses.

> [@DartCleek](#):
>
> Could this be a version issue with ood 4.0.6?

I don’t think so, I can’t replicate on our systems.

There’s something obvious that we’re missing. Something like it’s a windows formatted file and not being read correctly or something. Are there any errors in `/var/log/ondemand-nginx/$USER/error.log` when it boots up? Or maybe it’s as simple as a typo in the environment variable names that we’re just missing.

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [September 3, 2025, 3:58pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/13 "2025-09-03T15:58:51Z")

</div>

I was able to view the logs but there is a lot of noise in the logs but nothing that is standing out to me.

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [September 3, 2025, 5:00pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/14 "2025-09-03T17:00:23Z")

</div>

Can you share the contents of this file `/etc/ood/config/apps/shell/env`?

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [December 2, 2025, 4:17pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/15 "2025-12-02T16:17:14Z")

</div>

Sorry, Jeff, I just noticed this  
cat /etc/ood/config/apps/shell/env  
OOD\_SSHHOST\_ALLOWLIST=“\w+.redatcted.edu:\w+.hpcc.redacted”  
OOD\_DEFAULT\_SSHHOST=“servername.redacted.edu”  
OOD\_SSH\_WRAPPER=/usr/bin/ssh-kerb

OOD\_SHELL\_INACTIVE\_TIMEOUT\_MS=3600000 # 1 hour  
OOD\_SHELL\_MAX\_DURATION\_MS=36000000 # 10 hours  
OOD\_SHELL\_PING\_PONG=true

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [January 27, 2026, 4:19pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/16 "2026-01-27T16:19:49Z")

</div>

> [@DartCleek](#):
>
> /etc/ood/config/apps/shell/env

Sorry I didn’t get back to you quickly on this. If you’re still having timeout issues - then I’d check the permissions on `/etc/ood/config/apps/shell/env` to be sure it’s world readable. I.e., the app that’s running as a regular users UID has to be able to read it.

Beyond that I believe the config looks good.

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [January 27, 2026, 4:56pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/17 "2026-01-27T16:56:01Z")

</div>

Thanks. Jeff, we’ve checked all of that, and it is world-readable. It’s only the inactive timeout. We’re going to dig into a few more things on Thursday afternoon. We have a shell directory in two places and we want to test to see if removing it from one spot is what the issue is. We have one in the /etc/ood/config/apps/shell/env, and it also lives in /var/www/ood/apps/sys/shell; however, there is no env file. Though I can’t remember if that is expected or if there should be an env there as well.

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [January 27, 2026, 5:19pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/18 "2026-01-27T17:19:53Z")

</div>

> [@DartCleek](#):
>
> it also lives in /var/www/ood/apps/sys/shell;

I’d have to read the source code to see if it’s respected in this location. Regardless of whether it is or not, it’ll be overwritten when you update, so the `/etc` location is the proper spot for this file.

What version of OnDemand are you running? All this ping/pong and connectivity is only in 4.0. If you’re running a version less than that then none of those timeout/ping/pong settings are read or used.

---

<div class="post-metadata">

**Author:** ![DartCleek](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/dartcleek/32/2265_2.png) [@DartCleek](https://discourse.openondemand.org/u/DartCleek)\
**Post date:** [February 18, 2026, 4:30pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/19 "2026-02-18T16:30:11Z")

</div>

OnDemand version: 4.0.8 is the version we’re using; we’ve only ever had OOD live since version 4.0

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex015/uploads/osc/original/2X/b/bae70bd0ed39a3ae769c2108155f4cb3e9da8385.png) [@system](https://discourse.openondemand.org/u/system)\
**Post date:** [August 17, 2026, 4:30pm UTC](https://discourse.openondemand.org/t/ood-shell-inactive-timeout/4490/20 "2026-08-17T16:30:57Z")

</div>

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
