Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How to create a symlink to folder stored on unRAID?

Featured Replies

I am trying to create a symlink on a client computer that links to a folder on one of my unRAID disks.  The client computer is running XBMC which is based on Ubuntu.  I am trying to link to //Tower1/disk7/xbmc_thumbs/Thumbnails.  I have tried:

 

ln -s smb://Tower1/disk7/xbmc_thumbs/Thumbnails thumbnails

ln -s smb://192.168.1.20/disk7/xbmc_thumbs/Thumbnails thumbnails

ln -s //Tower1/disk7/xbmc_thumbs/Thumbnails thumbnails

ln -s //192.168.1.20/disk7/xbmc_thumbs/Thumbnails thumbnails

ln -s smb://Tower1/mnt/disk7/xbmc_thumbs/Thumbnails Thumbnails

ln -s //Tower1/mnt/disk7/xbmc_thumbs/Thumbnails Thumbnails

ln -s smb://192.168.1.20/mnt/disk7/xbmc_thumbs/Thumbnails Thumbnails

ln -s //192.168.1.20/mnt/disk7/xbmc_thumbs/Thumbnails Thumbnails

 

While each of these creates the symlink on the client computer, it doesn't seem to work like the link is correct.  Is there anything special I need to do because of unRAID?

...on a client computer...

Instea of...

ln -s //192.168.1.20/disk7/xbmc_thumbs/Thumbnails thumbnails

...why don't you do...

mount.cifs //192.168.1.20/disk7/xbmc_thumbs/Thumbnails thumbnails

Won't that do it for you?

 

  • Author

I have to admit ignorance on all things Linux so I don't know what that does.  What I'm trying to do is centralize the thumbnails for my HTPC.  Each client has them all stored locally in a folder named 'Thumbnails'.  I'm trying to create a link that the local client sees as that 'Thumbnails' folder but actually points to a folder on my server. Does that do what I'm wanting?

  • Author

I tried that and I get:

 

-bash: mount.cifs: command not found

 

I tried that and I get:

 

-bash: mount.cifs: command not found

 

 

That's strange.  I thought XBMC had CIFS.  What does it show when you type...

cat /proc/filesystems

Is cifs listed there?

 

Oh, Ubuntu!...  Try this:

sudo smbmount  //192.168.1.20/disk7/xbmc_thumbs/Thumbnails  /local_path_to/thumbnails

 

If there's no 'smbmount' then do this first:

sudo apt-get install smbfs

 

  • Author

What does that do?  I ask because this isn't a typical Ubuntu installation.  It's a stripped down version that my media software XBMC uses.  Why do you suggest this over a symlink.  Will they not work with unRAID?

  • Author

Also, doesn't that need a 'Thumbnails' folder on the XBMC client?  If so, XBMC will just read/write to that folder and negate what I want to do.  Unless I'm missing something.

 

Also, doesn't that need a 'Thumbnails' folder on the XBMC client?

Yes, and empty one.  If its not empty, the stuff in it will be hidden after the mount.

 

If so, XBMC will just read/write to that folder and negate what I want to do.

 

The server's Thumbnails folder will be mounted in the client's Thumbnails folder.  If you don't want to allow the client to write there, you can mount it as read-only. (smbmount -o ro ........)

Why do you suggest this over a symlink.

The link command can't take a unc path as source. Won't work as you discovered.

 

  • Author

I get this error:

mount error: can not change directory into mount target /Thumbnails

 

I get this error:

mount error: can not change directory into mount target /Thumbnails

 

Did you create the target folder? 

Is the target folder called /Thumbnails or /thumbnails ?

(Linux is case-sensitive)

 

  • Author

Yes, I created an empty folder named 'Thumbnails' on the client computer. From the location where the 'Thumbnails' folder should be, I ran:

 

sudo smbmount  //192.168.1.20/disk7/xbmc_thumbs/Thumbnails  /Thumbnails

 

That returned the mount error.

 

I don't know the answer to your question, RockDawg, but I just want to say that is one fine avatar.

From the location where the 'Thumbnails' folder should be, I ran:

sudo smbmount  //192.168.1.20/disk7/xbmc_thumbs/Thumbnails  /Thumbnails

 

The way you fully specified (starting with slash '/' ) the target directory, that means that it is under the root directory.

So it doesn't matter from what location you're typing the monut command.

But is the target really in your root directory?  What do you see when you type:

ls -la /

(^^these are small 'L's like in lemon)

 

I have the same setup, so maybe I can help..

(running mysql on the unraid box for the xbmc database and also created a shared thumbnail folder)

 

I created a folder called /mnt/xbmc on the xbmc machine (running xbmc live installed on hd)

Create a share on the unraid server called xbmc and put *(rw) into the Export (NFS) field

Create a directory in the xbmc share called Thumbnails (you can add other stuff too, I have a skin directory there as well)

then on the xbmc machine, edit /etc/fstab and added this:

192.168.234.10:/mnt/user/xbmc /mnt/xbmc nfs rw,hard,intr 0 0  (replace ip with your unraid server ip)

create a symlink in /home/xbmc/.xbmc/userdata/Thumbnails to /mnt/xbmc/Thumbnails

reboot the xbmc box...

 

I am sure there are easier and prettier ways of doing this, but this has worked for me very well..

  • Author

From the location where the 'Thumbnails' folder should be, I ran:

sudo smbmount  //192.168.1.20/disk7/xbmc_thumbs/Thumbnails  /Thumbnails

 

The way you fully specified (starting with slash '/' ) the target directory, that means that it is under the root directory.

So it doesn't matter from what location you're typing the monut command.

But is the target really in your root directory?  What do you see when you type:

ls -la /

(^^these are small 'L's like in lemon)

 

 

Here is what I get:

 

root@XBMCLive:/home/kevin/.xbmc/userdata# sudo smbmount  //192.168.1.20/disk7/xbmc_thumbs/Thumbnails  Thumbnails
mount error: can not change directory into mount target Thumbnails

 

I'll ask again. Where's the target? Show us with "ls -la" so we can see it exists.

 

  • Author

I have the same setup, so maybe I can help..

(running mysql on the unraid box for the xbmc database and also created a shared thumbnail folder)

 

I created a folder called /mnt/xbmc on the xbmc machine (running xbmc live installed on hd)

Create a share on the unraid server called xbmc and put *(rw) into the Export (NFS) field

Create a directory in the xbmc share called Thumbnails (you can add other stuff too, I have a skin directory there as well)

then on the xbmc machine, edit /etc/fstab and added this:

192.168.234.10:/mnt/user/xbmc /mnt/xbmc nfs rw,hard,intr 0 0  (replace ip with your unraid server ip)

create a symlink in /home/xbmc/.xbmc/userdata/Thumbnails to /mnt/xbmc/Thumbnails

reboot the xbmc box...

 

I am sure there are easier and prettier ways of doing this, but this has worked for me very well..

 

Unbelievably this isn't working for me either.  I'm miffed! I did every step you list and double-checked them all and still no thumbs show in XBMC.  

 

1. I created /mnt/xbmc on the XBMC machine (also Live installed on HD)

2. I created a 'xbmc' user sharein unRAID with your setting  in the Export (NFS) field.

3. I copied my existing Thumbnails folder into the newly created 'xbmc'

4. I edited /etc/fstab and copy/pasted the line you show

5. I created the 'Thumbnails' symlink in /home/kevin/.xbmc/userdata.  Not in /home/kevin/.xbmc/userdata/Thumbnails like you show.  I assume that was a typo.

6. I rebotted the XBMC machine, but no love.  No thumbnails display in XBMC.

 

I have one side question, if/when the symlink is created correctly, should I be able to see the contents when clicking on it in FileZilla FTP client or while navigating to the symlink folder in putty?

  • Author

I'll ask again. Where's the target? Show us with "ls -la" so we can see it exists.

 

 

Sorry, I'm trying a few different suggestions and I didn't respond to yours thoroughly enough.  The full target path I am dealing with is /home/kevin/.xbmc/userdata/Thumbnails.

 

root@XBMCLive:/home/kevin/.xbmc/userdata# ls -la /
total 84
drwxr-xr-x  21 root root  4096 2010-02-18 21:11 .
drwxr-xr-x  21 root root  4096 2010-02-18 21:11 ..
drwxr-xr-x   2 root root  4096 2010-02-06 16:36 bin
drwxr-xr-x   3 root root  4096 2010-02-18 21:23 boot
lrwxrwxrwx   1 root root    11 2010-01-23 22:40 cdrom -> media/cdrom
drwxr-xr-x  15 root root  3760 2010-04-27 19:48 dev
drwxr-xr-x  85 root root  4096 2010-04-27 19:48 etc
drwxr-xr-x   4 root root  4096 2010-04-25 17:04 home
lrwxrwxrwx   1 root root    33 2010-02-18 21:11 initrd.img -> boot/initrd.img-2.6.31-19-generic
lrwxrwxrwx   1 root root    33 2010-01-23 22:40 initrd.img.old -> boot/initrd.img-2.6.31-16-generic
drwxr-xr-x  15 root root  4096 2010-02-18 21:11 lib
drwx------   2 root root 16384 2009-12-26 15:29 lost+found
drwxr-xr-x   5 root root  4096 2009-12-26 15:30 media
drwxr-xr-x   3 root root  4096 2010-04-27 19:12 mnt
drwxr-xr-x   2 root root  4096 2009-12-26 15:30 opt
dr-xr-xr-x 120 root root     0 2010-04-27 19:48 proc
drwx------   5 root root  4096 2010-02-18 23:10 root
drwxr-xr-x   2 root root  4096 2010-04-26 21:29 sbin
drwxr-xr-x   2 root root  4096 2009-10-19 19:05 selinux
drwxr-xr-x   2 root root  4096 2009-12-26 15:30 srv
drwxr-xr-x  12 root root     0 2010-04-27 19:48 sys
drwxrwxrwt   5 root root  4096 2010-04-27 19:48 tmp
drwxr-xr-x  12 root root  4096 2009-12-26 15:29 usr
drwxr-xr-x  13 root root  4096 2010-01-23 22:41 var
lrwxrwxrwx   1 root root    30 2010-02-18 21:11 vmlinuz -> boot/vmlinuz-2.6.31-19-generic
lrwxrwxrwx   1 root root    30 2010-01-23 22:41 vmlinuz.old -> boot/vmlinuz-2.6.31-16-generic

 

 

 

 

 

  • Author

I don't know the answer to your question, RockDawg, but I just want to say that is one fine avatar.

 

Thanks!  Tesla was the man!

The full target path I am dealing with is /home/kevin/.xbmc/userdata/Thumbnails

So now it must be obvious to you why '/Thumbnails' as target is giving an error -- it isn't there.

 

  • Author

Yes, now I feel stupid!  I was expecting the command to create the Thumbnails folder like creating a symlink would do.  So stupid.  Thanks so much for your patience and help!

  • Author

I thought this was working, but it turns out it's not.  I just figured out that initially XBMC wouldn't write/save the thumbs to the mounted Thumbnail directory.  I wasn't sure why the newly scanned movies didn't show a thumb so I rebooted.  Everything then seemed to work fine.  It turns out that's because the mount/link is broken after a reboot and XBMC then just writes/saves the thumbs locally in the Thumbnail folder like it normally would.  Nothing is written to the server's Thumbnails folder.  So still no joy.

  • Author

I've been told that the lost mount on reboot is expected unless I put it in /etc/init.d/rc.local.  I didn't know that.  But that still leaves the other problem.

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.