Link to a file on my NAS

Hello everyone,

It would be great to be able to insert in a note a link to a file on a NAS (shared with SMB) that would be usable from any system, which means would not mention any mount point or drive (which is system-specific).

Today my links that work on Windows won't work on Linux and vice-versa, whereas the file is the same !

Thanks

Grégory

Try using an "smb" link in the format:

[My NAS File](smb://user@server/share/file_name.pdf)

I have never used this before but I just tried it with Joplin on a Linux system authorised to access the share and it opened the file. I am not able to try Windows.

Hi,

I overcame this very same problem by using an app called rclone to mount shares. You can mount a folder by a specific name on Windows Linux and Mac. If you use this method the link is the same on each of the three platforms.

Thanks but for whatever reason it doesn't work on my system (LMDE) even though it is also authorised to access the share

First, how did you install rclone on linux? Hopefully you did not install it through the distro Repository because that is a very old one updateable version.

On the download page for rclone is a script that you can run on Linux that will download and install the latest version of rclone.

What are you using for a link in Joplin?

Where are you storing the attachment? On the nas server?

On Windows look at the link that it created from the note to where it put the file and make sure that that link is identical in Windows and Linux.

Windows and Linux need to be referencing the same location. It's important to know what folder the attachment goes into.

Windows is case insensitive when Linux is not so if there are any differences between Windows and Linux in the naming that could cause a problem too.

Here is some additional info that might help.

How to make attachments accessible across Windows + Linux
You must use Joplin sync (WebDAV, Joplin Server, filesystem sync, etc.).
Sync transfers:

notes
metadata
resources (attachments).

Good news: it actually works... but one has first to authenticate on SMB, for instance by pasting the link in the file manager (Nemo in my case)
Bad news: such links don't work on Windows (11 in my case) !

If you use rclone on Linux to mount the nas server to a folder that will take care of the SMB authentication on Linux.

The big key is to make sure you use the built-in Joplin synchronization feature on both operating systems to synchronize the attachments into Joplin so that both operating systems will see the files.

Joplin does not reference the file from its original location on the server it makes a copy of it into its own database and synchronizes it amongst the clients.

Unfortunately it's in a SQL database so you can't see the actual attachment in the file system like you can with other apps like obsidian. There you would see the actual file attachment directory.

Now I have access to a Windows 11 machine I can see you are right! It does seem odd that an smb:// link will not work on Windows to connect to Microsoft's own SMB service...

I did find a post online about how to make Windows use smb:// links but it involved registry hacking and a batch file, which is not ideal...

Maybe @LeoW's suggestion is something to try?

Thank you for your message @dpoulton !

I am interested in accessing my attached files seamlessly but will not move heaven and earth to do that, so indeed won't hack the registry and so on...
Thank you @LeoW for you solution too but, in the same respect, I am not keen to install software for the sole benefit of naming my files consistently.

Thanks to all !

Not sure i know what you mean about a required naming convention but take care in whatever direction you decide to go.

Just one last comment is if you are mapping a drive to the storage server from Windows and also from Linux rather than using a synchronization scheme that is the ultimate cause of your problem. In order to see documents on both windows and Linux you must choose an option for synchronization on both clients and synchronize them to the same location. That will give you your documents on both sides.