GNOME Bugzilla – Bug 763359
XDG_RUNTIME_DIR not set in the environment
Last modified: 2016-03-09 06:53:01 UTC
I am using gst-rtsp-server-1.2.3 in Ubuntu 14.04 to stream video from webcam to another laptop. The working gstreamer pipeline that I used is $ sudo /home/ubuntu/Downloads/gst-rtsp-server-1.2.3/examples/test-launch "v4l2src device=/dev/video0 ! x264enc tune=zerolatency ! rtph264pay name=pay0 pt=96". However, the video stream is delayed for 5 seconds. I suspect this might be caused by CPU encoding, so I try to use gstreamer-vaapi 1.6.0 so that GPU will do the encoding task. I replace the x264enc with vaapiencode_h264 and the pipeline becomes $ sudo /home/ubuntu/Downloads/gst-rtsp-server-1.2.3/examples/test-launch "v4l2src device=/dev/video0 ! vaapiencode_h264 rate-control=vbr tune=high-compression ! rtph264pay name=pay0 pt=96". But when I run the pipeline, the following error is shown. Another laptop also not able to open the video stream. ubuntu@ubuntu-lenovo:~$ sudo /home/ubuntu/Downloads/gst-rtsp-server-1.2.3/examples/test-launch "v4l2src device=/dev/video0 ! vaapiencode_h264 rate-control=vbr tune=high-compression ! rtph264pay name=pay0 pt=96" stream ready at rtsp://192.168.0.134:554/test error: XDG_RUNTIME_DIR not set in the environment. libva info: VA-API version 0.35.0 libva info: va_getDriverName() returns 0 libva info: Trying to open /usr/local/lib/dri/i965_drv_video.so libva info: Found init function __vaDriverInit_0_32 libva info: va_openDriver() returns 0 error: XDG_RUNTIME_DIR not set in the environment. error: XDG_RUNTIME_DIR not set in the environment. error: XDG_RUNTIME_DIR not set in the environment.
It's libva or the backend that prints this. Please report this against libva, but it seems more like a setup problem on your system. Ubuntu should've set this for you already.