Can you share USB Thumb Drive via SMB and NFS at the same time? - [GIVING UP]


Recommended Posts

Is it possible to mount a USB thumb drive outside the array as a permanent share as both NFS and SMB at the same time?

 

If so, how?  link to instructions?  I found some articles about mounting regular drives outside the array but nothing with the steps start to finish.

 

I have a database used for a video Jukebox made up of about 44,000 files but is only 4GB in size.  For future expansion I want something that is about 16GB in size.  I really think based on its use, it would be better to use solid state media and really don't want that mixed in the same drive as really large media files.  It does need to be available as an NFS share (which I still need to learn to use) for the media player to function properly, but also needs to be on SMB for my windows based software to keep it updated.  It is not critical for it to be in the protected array.  It can be easily recreated if there was a hardware failure.

 

EDIT - The below problem is solved, now back to the above question.

Link to comment
  • 4 months later...

Well, what I was intending to use this for got put on the back burner for a while, until tonight I gave this a shot, but have a couple problems.

 

1. I installed SNAP following the instructions through unMENU.  Everything seemed to go fine.  However, when I rebooted the unRAID, unMENU no longer works.  //server:8080 brings up a could not connect error.  I've been using a shortcut forever so I cant have any address wrong. 

 

2. Snap works, but seems to only share as an SMB share.  I really need to share out this USB thumb drive as both an NFS and SMB share outside the array. 

Link to comment

I have never manually changed my go script.  The only changes would have been made the the snap install done through unMENU.

 

I opened my go script file and this is what I found.

 

#!/bin/bash

# Start the Management Utility

/usr/local/sbin/emhttp &

 

cd /boot/packages && find . -name '*.auto_install' -type f -print | sort | xargs -n1 sh -c

 

/boot/unmenu/uu/boot/config/snap/snap.sh -b

 

I made a backup of the original and added

cd /boot/unmenu

./uu

to the bottom.

 

Booting fine now.  I guess somehow snap went over the unmenu start-up lines.

 

Of course now I'm back to the first problem.  Can Snap create a NFS Share at all?  Can I get a single folder to be shared in both SMB and NFS at the same time?  If not with Snap, is there another way?

 

This is preferably a small drive (such as a USB Flash).  It's used for a video jukebox database that currently has 45,000 files and is only 4 GB in size.  I want to get something about 16 GB in size to allow for room to expand.  It's definitely not critical data so not worried about it being in the protected array and updating anything with that many files I just assume it not be.  If the drive went bad this can be re-created by the software in an hour or so.  The database that it is created from IS inside the array.

 

Thanks for all the help!

 

Link to comment

I did one other maintenance related item on a HD tonight (wdidle3 for a WD EARLS). All went fine.

 

I had my monitor connected and watched the startup.  At the end I noticed this error.

 

/var/tmp/go: line7: /boot/unmenu/uu/boot/config/snap/snap.sh: Not a directory

 

looks a whole lot like what I was talking about above.  Everything seems to be working fine, though I'm not using the thumbddrive right now that snap is set up for.  I'm not sure if snap is now working fine or not. 

 

Is this a bad command line somewhere I need to fix?

Link to comment

#!/bin/bash

# Start the Management Utility

/usr/local/sbin/emhttp &

 

cd /boot/packages && find . -name '*.auto_install' -type f -print | sort | xargs -n1 sh -c

 

/boot/unmenu/uu/boot/config/snap/snap.sh -b

 

Looks like there's a new line missing from part way through the last line...

 

This makes more sense...

 

/boot/unmenu/uu

 

/boot/config/snap/snap.sh -b

 

 

Link to comment

Looks like there's a new line missing from part way through the last line...

 

This makes more sense...

 

/boot/unmenu/uu

 

/boot/config/snap/snap.sh -b

 

Yes, I missed that thanks.  Revised it to look like this, deleting my added lines as well.

 

#!/bin/bash

# Start the Management Utility

/usr/local/sbin/emhttp &

 

cd /boot/packages && find . -name '*.auto_install' -type f -print | sort | xargs -n1 sh -c

 

/boot/unmenu/uu

/boot/config/snap/snap.sh -b

 

Looks like it did the trick.

Link to comment

#!/bin/bash

# Start the Management Utility

/usr/local/sbin/emhttp &

 

cd /boot/packages && find . -name '*.auto_install' -type f -print | sort | xargs -n1 sh -c

 

/boot/unmenu/uu/boot/config/snap/snap.sh -b

 

Looks like there's a new line missing from part way through the last line...

 

This makes more sense...

 

/boot/unmenu/uu

 

/boot/config/snap/snap.sh -b

 

Hi.  Yeah SNAP appends to the go file and isn't expecting the missing newline in yours.

 

SNAP doesn't have any way to do nfs connections.  But you could add bash code in the after_share event to make the nfs connection.

 

Sent from my SPH-M900 using Tapatalk

Link to comment

 

Hi.  Yeah SNAP appends to the go file and isn't expecting the missing newline in yours.

 

SNAP doesn't have any way to do nfs connections.  But you could add bash code in the after_share event to make the nfs connection.

 

Sent from my SPH-M900 using Tapatalk

 

This surpasses my knowledge of Linux.  Is this easy to explain how to do? Are there instructions anywhere?

Link to comment

 

Hi.  Yeah SNAP appends to the go file and isn't expecting the missing newline in yours.

 

SNAP doesn't have any way to do nfs connections.  But you could add bash code in the after_share event to make the nfs connection.

 

Sent from my SPH-M900 using Tapatalk

 

This surpasses my knowledge of Linux.  Is this easy to explain how to do? Are there instructions anywhere?

 

Why do you need NFS?

Link to comment

 

Hi.  Yeah SNAP appends to the go file and isn't expecting the missing newline in yours.

 

SNAP doesn't have any way to do nfs connections.  But you could add bash code in the after_share event to make the nfs connection.

 

Sent from my SPH-M900 using Tapatalk

 

This surpasses my knowledge of Linux.  Is this easy to explain how to do? Are there instructions anywhere?

 

I'll try to come up with some bash code for making a nfs connection between unRAID and another linux (or a second unRAID) machine. 

Link to comment

 

I'll try to come up with some bash code for making a nfs connection between unRAID and another linux (or a second unRAID) machine.

 

I am trying to connect to the same USB thumb drive (on the unRAID server) from a Dune player via NFS and from a Win7 machine via SMB.  I have the process to use from the Dune, but don't have the ability to share the USB thumb drive on unRAID via NFS and SMB.  As noted above it would probably make the most sense for it not to bein the array so was looking at Snap.  I am not familiar with "bash code" so not sure whatit would door how it works.

 

If it can accomplish this, your help is most appreciated.  Thanks for your time either way.

Link to comment

Why do you need NFS?

 

Not easy to explain briefly but will give it a shot.  I have to back up and explain how this application works.

 

I have a Dune player that I use to access my movies / music stored on my unRAID sever, and am about to add a second player.  I use a program called Zappiti to create a Jukebox database to surf the video collection.  It basically creates a GUI using the movie graphics to surf the collection.  Right now the database is stored on a thumb drive attached to the dune, but when I add a second (and eventually 3rd) player, it is much better to keep the database centrally located so I don't have to update it in multiple locations.

 

So I want to store this fairly large database on a shared drive.  I really don't want the long hesitation to access it when a conventional drive wakes up, so solid state media makes the most sense.  I only need about 16GB of space available for it and would prefer not to lose a hard drive bay, so that brings me to a USB thumb drive.  Since the software can recreate the database in about 20 minutes, I really don't need it inside the array. 

 

So now to answer the question about NFS.  You can only open one SMB share at a time on any given machine. So i cant have the database on one share and then open media from a different share when the database is already open.  The obvious fix for this is to have the database inside the same share name as the media.  However my media is in 2 different shares (one for tv shows and one for movies) so there would always Be one that doesn't work.  This was a lack of foresight on my part when I built my unRAID server, but never the less I am here.  I could change how the shares are structured so they both come out of a common Media share.  However, one shortcoming of Zappiti is that if you change a share name at all, it has to complete re-scrape that part of the collection.  While most of that is automated, grouping them together is largely manual.  This would take many hours, probably over a few days.  Re-scraping is completely different than just recreating the database.  Scraping looks at each media file and lines it up with a large database of movies and graphics onthe net.  It's very similar to what windows media player does when it catalogs your music collection. All of this is really about me trying to find an alternative to re-scraping the collection.  You can open the database in an NFS share, and then be free to open the media in any SMB share out there.  However, then I need to be able to access the database from the Win7 machine to keep it updated as new media is added.  So the same spot needs to be accessed via SMB and NFS.

 

So that was probably more info than you wanted, but I am not sure how else to answer it.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.