# RHEL9 Websockify

**URL:** <https://discourse.openondemand.org/t/rhel9-websockify/4221>\
**Category:** Get Help\
**Created:** [April 25, 2025, 3:08pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221 "2025-04-25T15:08:17Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![lh59281](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/lh59281/32/2748_2.png) [@lh59281](https://discourse.openondemand.org/u/lh59281)\
**Post date:** [April 25, 2025, 3:08pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221/1 "2025-04-25T15:08:17Z")

</div>

Hello, I am trying to get the interactive desktop application working on a RHEL9 Slurm cluster. I’ve run into a show stopper with websockify, it seems maybe OOD is hardcoded to look in `opt` for it?

From the log:

```auto
/var/spool/slurm/d/job04034/slurm_script: line 206: /opt/websockify/run: No such file or directory

```

Despite having version 0.11 installed via dnf on our compute nodes:

```auto
rpm -qa | grep python3-websockify
python3-websockify-0.11.0-1.el9.noarch

```

I’m assuming this is a path issue? We’re running TurboVNC as a VNC server.

Thanks!

Edit: from the launch script OOD generated:

```auto
start_websockify() {
  local log_file="./websockify.log"
  # launch websockify in background and redirect all output to a file.
  ${WEBSOCKIFY_CMD:-/opt/websockify/run} $1 --heartbeat=${WEBSOCKIFY_HEARTBEAT_SECONDS:-30} $2 &> $log_file &
  local ws_pid=$!
  local counter=0
  local max_timeout=${WEBSOCKIFY_TIMEOUT_SECONDS:-10}

```

Definitely looks like it’s getting the websockify path from here. Anyway to change where that looks?

---

<div class="post-metadata">

**Author:** ![lh59281](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/lh59281/32/2748_2.png) [@lh59281](https://discourse.openondemand.org/u/lh59281)\
**Post date:** [April 25, 2025, 3:34pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221/2 "2025-04-25T15:34:14Z")

</div>

Figured out a few things, namely that I can set this in the cluster definition:

```auto
  batch_connect:
    vnc:
      websockify_cmd: "/usr/bin/websockify"

```

That seems to work, the OOD script now:

```auto
start_websockify() {
  local log_file="./websockify.log"
  # launch websockify in background and redirect all output to a file.
  /usr/bin/websockify $1 --heartbeat=${WEBSOCKIFY_HEARTBEAT_SECONDS:-30} $2 &> $log_file &

```

However, it seems websockify 0.11 is throwing an error:

```auto
Traceback (most recent call last):
  File "/usr/bin/websockify", line 33, in <module>
    sys.exit(load_entry_point('websockify==0.11.0', 'console_scripts', 'websockify')())
  File "/usr/bin/websockify", line 25, in importlib_load_entry_point
    return next(matches).load()
StopIteration

```

So that changes the scope of this problem. I’ll keep digging on that, does OOD need an older or newer version of websockify? The documentation says 0.8+ but I know RHEL tends to be a bit behind.

---

<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:** [April 25, 2025, 3:38pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221/3 "2025-04-25T15:38:30Z")

</div>

OSC uses 0.11.0 though it’s through a module. Did you get 0.11.0 off of dnf/yum?

---

<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:** [April 25, 2025, 3:39pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221/4 "2025-04-25T15:39:20Z")

</div>

Also I’m wondering if that’s the full stack trace. It doesn’t appear to be.

---

<div class="post-metadata">

**Author:** ![lh59281](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/lh59281/32/2748_2.png) [@lh59281](https://discourse.openondemand.org/u/lh59281)\
**Post date:** [April 25, 2025, 3:55pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221/5 "2025-04-25T15:55:54Z")

</div>

> [@jeff.ohrstrom](#):
>
> OSC uses 0.11.0 though it’s through a module. Did you get 0.11.0 off of dnf/yum?

Yes, it came through DNF. Package was python3-websockify.

I agree on the stack trace, but that’s all that is in the websockify.log file from the job. Trying to get more information out of it.

---

<div class="post-metadata">

**Author:** ![lh59281](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/lh59281/32/2748_2.png) [@lh59281](https://discourse.openondemand.org/u/lh59281)\
**Post date:** [April 25, 2025, 5:40pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221/6 "2025-04-25T17:40:24Z")

</div>

I went down the virtual environment path with Websockify and that seemed to work. Something must missing from the RHEL compiled version. So for anyone reading this thread in the future you need to create a venv or Lmod to run Websockify, adjust the path in your cluster definition thusly:

```auto
  batch_connect:
    vnc:
      websockify_cmd: "/hpc/venv/websockify/bin/websockify"

```

I just did a quick and dirty virtual environment here. Just make sure this is shared out on NFS or otherwise accessible by your compute nodes.

---

<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:** [October 22, 2025, 5:41pm UTC](https://discourse.openondemand.org/t/rhel9-websockify/4221/7 "2025-10-22T17:41:24Z")

</div>

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