In Ubuntu, obsidian://... URLs open the vault but not the file

Things I have tried

I found multiple forum posts on similar issues and then found Amir’s great blog on setting up Linux access to obsidian://… URLs. Thanks Amir

I also found this thread on investigating the libva error but it’s a very deep rabbit hole and I didn’t get very far. libva error: vaGetDriverNameByIndex() failed with unknown libva error,driver_name=(null) · Issue #1349 · intel/media-driver · GitHub

xdg-open obsidian://open?vault=infrastructure&file=Test

This opens the correct Obsidian Vault. Unfortunately,
It fails to open the target file
The following log messages and error show up

Loading updated app package 
/home/username/.config/obsidian/obsidian-1.1.9.asar
Checking for update using Github
libva error: vaGetDriverNameByIndex() 
failed with unknown libva error, driver_name = (null)
[27924:1225/200238.868244:ERROR:viz_main_impl.cc(188)] 
Exiting GPU process due to errors during initialization

My Environment:

  • Google Cloud VM
  • Ubuntu 22.04
  • KDE Plasma desktop
  • ~/.config/applications/obsidian.desktop
[Desktop Entry]
Name=Obsidian
Exec=/opt/obsidian %u
Terminal=false
Type=Application
Icon=/opt/obsidian-icon.png
StartupWMClass=obsidian
X-AppImage-Version=1.0.3
Comment=Obsidian
Categories=Office;
MimeType=text/html;x-scheme-handler/obsidian;

Note: /opt/obsidian => /opt/Obsidian-1.0.3.AppImage

What I’m trying to do

I’m trying to get Obsidian URLs working on Linux.
Eg. obsidian://open?vault=infrastructure&file=Test (infrastructure/Test.md exists)

xdg-open obsidian://open?vault=infrastructure&file=Test

Successfully opens Obsidian to the correct Vault but then fails to open the file Test.md


Here’s Amir’s great blog on setting up Linux access to obsidian://… URLs. Thanks Amir

Path Correction: ~/.local/share/applications/obsidian.desktop

SOLVED! Looks like my problem was missing the quotes. With quotes this works
xdg-open “obsidian://open?vault=infrastructure&file=Test”

1 Like

That seems sensible since the ampersand, &, is used to trigger runming the job in the background, and then you just set an environment variable…

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