Hang at gst_init on ubuntu impish docker
I have noticed that GStreamer on ubuntu impish (21.10) docker's image is completely not functional. I encountered this for the first time when the application I am developing hanged at gst_init
, but then I found out the issue seems to be more general.
After quite a long time the following error shows up:
External plugin loader failed. This most likely means that the plugin loader helper binary was not found or could not be run. You might need to set the GST_PLUGIN_SCANNER environment variable if your setup is unusual. This should normally not be required though.
Steps to reproduce
Run the ubuntu impish container:
docker run --rm -ti ubuntu:impish bash
Then inside the container, install some packages:
apt-get update && \
apt-get install -y \
libgstreamer1.0-0 \
gstreamer1.0-plugins-base \
gstreamer1.0-plugins-good \
gstreamer1.0-plugins-bad \
gstreamer1.0-plugins-ugly \
gstreamer1.0-tools \
libsoup2.4-1 \
libjson-glib-1.0-0 && \
rm -rf /var/lib/apt/lists/*
and try to run any GStreamer command:
gst-inspect-1.0
Expected results
List of plugins should show up.
Actual results
Nothing happens.
Logs
root@858159e36f63:/# GST_DEBUG=*:5 gst-inspect-1.0
0:00:00.000051516 5767 0x559a7f95cc00 INFO GST_INIT gst.c:586:init_pre: Initializing GStreamer Core Library version 1.18.5
0:00:00.000106367 5767 0x559a7f95cc00 INFO GST_INIT gst.c:587:init_pre: Using library installed in /usr/lib/x86_64-linux-gnu
0:00:00.000118483 5767 0x559a7f95cc00 INFO GST_INIT gst.c:605:init_pre: Linux 858159e36f63 5.10.47-linuxkit #1 SMP Sat Jul 3 21:51:47 UTC 2021 x86_64
0:00:00.000161279 5767 0x559a7f95cc00 DEBUG GST_MEMORY gstallocator.c:588:_priv_gst_allocator_initialize: memory alignment: 7
0:00:00.000262233 5767 0x559a7f95cc00 DEBUG GST_MEMORY gstallocator.c:565:gst_allocator_sysmem_init: init allocator 0x559a7f964840
0:00:00.000282350 5767 0x559a7f95cc00 DEBUG GST_MEMORY gstallocator.c:206:gst_allocator_register: registering allocator 0x559a7f964840 with name "SystemMemory"
0:00:00.000329897 5767 0x559a7f95cc00 INFO GST_INIT gstmessage.c:129:_priv_gst_message_initialize: init messages
0:00:00.000376177 5767 0x559a7f95cc00 DEBUG GST_ELEMENT_PADS gstelement.c:311:gst_element_base_class_init: type GstElement : factory (nil)
0:00:00.000433978 5767 0x559a7f95cc00 DEBUG GST_ELEMENT_PADS gstelement.c:311:gst_element_base_class_init: type GstBin : factory (nil)
0:00:00.000704149 5767 0x559a7f95cc00 INFO GST_INIT gstcontext.c:85:_priv_gst_context_initialize: init contexts
0:00:00.000905179 5767 0x559a7f95cc00 INFO GST_PLUGIN_LOADING gstplugin.c:325:_priv_gst_plugin_initialize: registering 0 static plugins
0:00:00.000988542 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:589:gst_registry_add_feature:<registry0> adding feature 0x559a7f981040 (bin)
0:00:00.000998713 5767 0x559a7f95cc00 DEBUG GST_REFCOUNTING gstobject.c:708:gst_object_set_parent:<bin> set parent (ref and sink)
0:00:00.001016416 5767 0x559a7f95cc00 DEBUG GST_ELEMENT_PADS gstelement.c:311:gst_element_base_class_init: type GstPipeline : factory 0x559a7f981120
0:00:00.001073959 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:589:gst_registry_add_feature:<registry0> adding feature 0x559a7f981120 (pipeline)
0:00:00.001081867 5767 0x559a7f95cc00 DEBUG GST_REFCOUNTING gstobject.c:708:gst_object_set_parent:<pipeline> set parent (ref and sink)
0:00:00.001089392 5767 0x559a7f95cc00 INFO GST_PLUGIN_LOADING gstplugin.c:233:gst_plugin_register_static: registered static plugin "staticelements"
0:00:00.001096143 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:473:gst_registry_add_plugin:<registry0> adding plugin 0x559a7f980060 for filename "(NULL)"
0:00:00.001109109 5767 0x559a7f95cc00 INFO GST_PLUGIN_LOADING gstplugin.c:235:gst_plugin_register_static: added static plugin "staticelements", result: 1
0:00:00.001155541 5767 0x559a7f95cc00 INFO GST_REGISTRY gstregistry.c:1755:ensure_current_registry: reading registry cache: /root/.cache/gstreamer-1.0/registry.x86_64.bin
0:00:00.001275454 5767 0x559a7f95cc00 INFO GST_REGISTRY gstregistrybinary.c:584:priv_gst_registry_binary_read_cache: Unable to mmap file /root/.cache/gstreamer-1.0/registry.x86_64.bin : Failed to open file “/root/.cache/gstreamer-1.0/registry.x86_64.bin”: open() failed: No such file or directory
0:00:00.001335200 5767 0x559a7f95cc00 INFO GST_REGISTRY gstregistrybinary.c:594:priv_gst_registry_binary_read_cache: Unable to read file /root/.cache/gstreamer-1.0/registry.x86_64.bin : Failed to open file “/root/.cache/gstreamer-1.0/registry.x86_64.bin”: No such file or directory
0:00:00.001345121 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1783:ensure_current_registry: Updating registry cache
0:00:00.001349222 5767 0x559a7f95cc00 INFO GST_REGISTRY gstregistry.c:1614:scan_and_update_registry: Validating plugins from registry cache: /root/.cache/gstreamer-1.0/registry.x86_64.bin
0:00:00.001352825 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1624:scan_and_update_registry: scanning paths added via --gst-plugin-path
0:00:00.001355917 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1647:scan_and_update_registry: GST_PLUGIN_PATH not set
0:00:00.001359489 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1659:scan_and_update_registry: GST_PLUGIN_SYSTEM_PATH not set
0:00:00.001364592 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1666:scan_and_update_registry: scanning home plugins /root/.local/share/gstreamer-1.0/plugins
0:00:00.001371845 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1380:gst_registry_scan_path_internal:<registry0> scanning path /root/.local/share/gstreamer-1.0/plugins
0:00:00.001381884 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1383:gst_registry_scan_path_internal:<registry0> registry changed in path /root/.local/share/gstreamer-1.0/plugins: 0
0:00:00.001386981 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1691:scan_and_update_registry: scanning main plugins /usr/lib/x86_64-linux-gnu/gstreamer-1.0
0:00:00.001390406 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1380:gst_registry_scan_path_internal:<registry0> scanning path /usr/lib/x86_64-linux-gnu/gstreamer-1.0
0:00:00.001565593 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1360:gst_registry_scan_path_level:<registry0> file /usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstequalizer.so not yet in registry
0:00:00.001601712 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1161:gst_registry_scan_plugin_file: Starting plugin scanner for file /usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstequalizer.so
0:00:00.001611500 5767 0x559a7f95cc00 DEBUG GST_POLL gstpoll.c:681:gst_poll_new: 0x559a7f959ca0: new controllable : 0
0:00:00.001645153 5767 0x559a7f95cc00 DEBUG GST_POLL gstpoll.c:848:gst_poll_add_fd_unlocked: 0x559a7f959ca0: fd (fd:4, idx:0)
0:00:00.001686231 5767 0x559a7f95cc00 DEBUG GST_POLL gstpoll.c:1014:gst_poll_fd_ctl_read_unlocked: 0x559a7f959ca0: fd (fd:4, idx:0), active : 1
0:00:00.001697756 5767 0x559a7f95cc00 DEBUG GST_REGISTRY gstregistry.c:1172:gst_registry_scan_plugin_file: Using scan-helper to load plugin /usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstequalizer.so
0:00:00.000105171 5768 0x55784e403a00 INFO GST_INIT gst.c:586:init_pre: Initializing GStreamer Core Library version 1.18.5
0:00:00.000166864 5768 0x55784e403a00 INFO GST_INIT gst.c:587:init_pre: Using library installed in /usr/lib/x86_64-linux-gnu
0:00:00.000176484 5768 0x55784e403a00 INFO GST_INIT gst.c:605:init_pre: Linux 858159e36f63 5.10.47-linuxkit #1 SMP Sat Jul 3 21:51:47 UTC 2021 x86_64
0:00:00.000250131 5768 0x55784e403a00 DEBUG GST_MEMORY gstallocator.c:588:_priv_gst_allocator_initialize: memory alignment: 7
0:00:00.000384427 5768 0x55784e403a00 DEBUG GST_MEMORY gstallocator.c:565:gst_allocator_sysmem_init: init allocator 0x55784e40c040
0:00:00.000414399 5768 0x55784e403a00 DEBUG GST_MEMORY gstallocator.c:206:gst_allocator_register: registering allocator 0x55784e40c040 with name "SystemMemory"
0:00:00.000499839 5768 0x55784e403a00 INFO GST_INIT gstmessage.c:129:_priv_gst_message_initialize: init messages
0:00:00.000587867 5768 0x55784e403a00 DEBUG GST_ELEMENT_PADS gstelement.c:311:gst_element_base_class_init: type GstElement : factory (nil)
0:00:00.000660414 5768 0x55784e403a00 DEBUG GST_ELEMENT_PADS gstelement.c:311:gst_element_base_class_init: type GstBin : factory (nil)
0:00:00.000976657 5768 0x55784e403a00 INFO GST_INIT gstcontext.c:85:_priv_gst_context_initialize: init contexts
0:00:00.001355397 5768 0x55784e403a00 INFO GST_PLUGIN_LOADING gstplugin.c:325:_priv_gst_plugin_initialize: registering 0 static plugins
0:00:00.001559286 5768 0x55784e403a00 DEBUG GST_REGISTRY gstregistry.c:589:gst_registry_add_feature:<registry0> adding feature 0x55784e428840 (bin)
0:00:00.001572123 5768 0x55784e403a00 DEBUG GST_REFCOUNTING gstobject.c:708:gst_object_set_parent:<bin> set parent (ref and sink)
0:00:00.001616523 5768 0x55784e403a00 DEBUG GST_ELEMENT_PADS gstelement.c:311:gst_element_base_class_init: type GstPipeline : factory 0x55784e428920
0:00:00.001650518 5768 0x55784e403a00 DEBUG GST_REGISTRY gstregistry.c:589:gst_registry_add_feature:<registry0> adding feature 0x55784e428920 (pipeline)
0:00:00.001685233 5768 0x55784e403a00 DEBUG GST_REFCOUNTING gstobject.c:708:gst_object_set_parent:<pipeline> set parent (ref and sink)
0:00:00.001700527 5768 0x55784e403a00 INFO GST_PLUGIN_LOADING gstplugin.c:233:gst_plugin_register_static: registered static plugin "staticelements"
0:00:00.001715835 5768 0x55784e403a00 DEBUG GST_REGISTRY gstregistry.c:473:gst_registry_add_plugin:<registry0> adding plugin 0x55784e427060 for filename "(NULL)"
0:00:00.001729126 5768 0x55784e403a00 INFO GST_PLUGIN_LOADING gstplugin.c:235:gst_plugin_register_static: added static plugin "staticelements", result: 1
0:00:00.001783320 5768 0x55784e403a00 DEBUG GST_REGISTRY gstregistry.c:1786:ensure_current_registry: Not updating registry cache (disabled)
0:00:00.001794770 5768 0x55784e403a00 INFO GST_REGISTRY gstregistry.c:1790:ensure_current_registry: registry reading and updating done, result = 1
0:00:00.001799909 5768 0x55784e403a00 INFO GST_INIT gst.c:806:init_post: GLib runtime version: 2.68.4
0:00:00.001837938 5768 0x55784e403a00 INFO GST_INIT gst.c:808:init_post: GLib headers version: 2.68.4
0:00:00.001906303 5768 0x55784e403a00 INFO GST_INIT gst.c:810:init_post: initialized GStreamer successfully
0:00:00.001918954 5768 0x55784e403a00 DEBUG default gsttracerutils.c:77:_priv_gst_tracing_init: Initializing GstTracer
0:00:00.001967126 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:681:gst_poll_new: 0x55784e400ca0: new controllable : 0
0:00:00.002098275 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:848:gst_poll_add_fd_unlocked: 0x55784e400ca0: fd (fd:3, idx:0)
0:00:00.002143148 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1014:gst_poll_fd_ctl_read_unlocked: 0x55784e400ca0: fd (fd:3, idx:0), active : 1
0:00:00.002165607 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:848:gst_poll_add_fd_unlocked: 0x55784e400ca0: fd (fd:0, idx:-1)
0:00:00.002175413 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:848:gst_poll_add_fd_unlocked: 0x55784e400ca0: fd (fd:7, idx:-1)
0:00:00.002179948 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1014:gst_poll_fd_ctl_read_unlocked: 0x55784e400ca0: fd (fd:7, idx:2), active : 1
0:00:00.002183512 5768 0x55784e403a00 DEBUG GST_PLUGIN_LOADING gstpluginloader.c:583:_gst_plugin_loader_client_run: Plugin scanner child running. Waiting for instructions
0:00:00.002215002 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1414:gst_poll_wait: 0x55784e400ca0: timeout :0:00:01.000000000
0:00:01.003660225 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1241:gst_poll_fd_has_error: 0x55784e400ca0: fd (fd:7, idx:2) 0
0:00:01.003711224 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1266:gst_poll_fd_can_read_unlocked: 0x55784e400ca0: fd (fd:7, idx:2) 0
0:00:01.003728499 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1195:gst_poll_fd_has_closed: 0x55784e400ca0: fd (fd:7, idx:2) 0
0:00:01.003734703 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1414:gst_poll_wait: 0x55784e400ca0: timeout :0:00:01.000000000
0:00:02.005232205 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1241:gst_poll_fd_has_error: 0x55784e400ca0: fd (fd:7, idx:2) 0
0:00:02.005285437 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1266:gst_poll_fd_can_read_unlocked: 0x55784e400ca0: fd (fd:7, idx:2) 0
0:00:02.005291897 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1195:gst_poll_fd_has_closed: 0x55784e400ca0: fd (fd:7, idx:2) 0
0:00:02.005296997 5768 0x55784e403a00 DEBUG GST_POLL gstpoll.c:1414:gst_poll_wait: 0x55784e400ca0: timeout :0:00:01.000000000