No protocol specified, No EGL Display, nvbufsurftransform: Could not get EGL display connection

Jetson Nano Dev Kit, DS 5.1

I’m catching these errors while opening my script, which runs fine with a display:

No protocol specified
No EGL Display 
nvbufsurftransform: Could not get EGL display connection

The installation was a headless installation and currently there is no HDMI monitor attached.

I’m running the things from an SSH shell and usually

export DISPLAY=:0

did do the job. Not so now.

ubuntu@jetson:~/dragonfly-safety/jetson-inference$ export DISPLAY=:0
ubuntu@jetson:~/dragonfly-safety/jetson-inference$ xrandr
No protocol specified
Can't open display :0

Same with export DISPLAY=:1

EDIT: More information on this: While in the headless installation it is NOT possible to make my script run, everything is fine after a non-headless installation. The script works even if the display is unplugged at boot.

There must be a problem with the headless installation of Deepstream 5.1 and some pipeline components. Please check this out.

Looks like it is similar to this:
Libargus will not start without DisplayPort connected - #6 by WayneWWW

Even though in headless mode , we would still suggest keep the drivers. Please check if you can keep nvgpu and nvdispay drivers.

Please check if you can keep nvgpu and nvdispay drivers.

I was using the SD image you provided. How am I supposed to keep drivers? I didn’t remove them

Please try without setting export DISPLAY=:0. On Jetson Nano + SD card image, we boot without connecting to display output, modify [sink0] to fakesink in


and execute:

nvidia@nvidia-desktop:/opt/nvidia/deepstream/deepstream-5.1/samples/configs/deestream-app$ deepstream-app -c source8_1080p_dec_infer-resnet_tracker_tiled_dispay_fp16_nano.txt

It runs well and does not hit No EGL Display error. Please give it a try.

That sounds reasonable. But would that not also mean, that I would not be able to plug a monitor later on, if I was doing the installation in headless mode?

If I think about a practical use case then I would not deploy a Jetson Nano setup in production with a monitor. But it could always be, that I would be happy to see a situation on screen instead of deriving information from software outputs. Would that be doable in such a situation? Could I just plugin a monitor and see something, even if I just have configured the system headlessly?

I mean your proposal would finally lead to a different launch and runtime behaviour: I would have to configure my pipeline differently (fakesink vs. real sink) depending on whether I would like to see something or not. I need to point out that this is not the case in my current deployment that was setup on an instance, which was configured initially in non-headless mode. Here I just suppress the display of metadata and the video does not show up. Gives btw. an additional win in inference rate of up to 5 fps…

Is there any way to determine, if a system has been setup in headless mode or not to derive this switch?

OK, to answer all my questions above:

  1. With the redirection to fakesink instead of nvosd the pipeline starts w/o problems even after a headless installation. So the “No EGL Display” is not displayed anymore

  2. Even a headless installation can later on launch xserver and display the overlay, if controlled by the script. Just “export DISPLAY:=0” has to be omitted then. I was not able to launch it from SSH, but after being logged in I could launch the script and display the video.

So everything is fine.