Author Topic: Add SSHFS to the options for file server.  (Read 6288 times)

tekoholic

  • Veteran
  • ***
  • Posts: 96
    • View Profile
Add SSHFS to the options for file server.
« on: November 16, 2009, 06:07:43 am »
I've set up my all-Ubuntu network with no file-sharing, for security, other than the default Samba/NFS shares set up by LinuxMCE (I simply haven't had the time to research disabling them).  We use SSHFS and AutoFS for all our file-sharing in the home.

I have set up SSHFS with AutoFS on my LMCE 0810 Hybrid, to a working 4 TB server that must remain stable and unchanged, where all my family's media is held.  However, I've searched these forums and wiki for the last few weeks, and cannot find ANY reference to how this might be done via the web-gui, and having just set it up manually, I've no idea whether the media sync will happen automatically.

All files in share are VISIBLE via the web-gui, but none have been added to DB as yet.

Is there any specific reason for not having SSHFS as one of the integrated options for file-shares?  Any ideas on how this might be easily accomplished?

jimbodude

  • Guru
  • ****
  • Posts: 372
    • View Profile
Re: Add SSHFS to the options for file server.
« Reply #1 on: November 16, 2009, 04:11:35 pm »
I'm not sure I see where there is a security risk using Samba and NFS on a private home LAN...  Especially for multimedia.  That's probably why SSH isn't an option.  If I'm not mistaken, you take a performance hit going to SSH, which may cause streaming issues.  I don't remember the technical details though...

Not to say that it's a bad idea to have SSH - just trying to understand where you're coming from...

tekoholic

  • Veteran
  • ***
  • Posts: 96
    • View Profile
Re: Add SSHFS to the options for file server.
« Reply #2 on: November 16, 2009, 11:50:43 pm »
In part, I have SSH access to a few friends' media collections, mostly music.  All accounted for, I've got direct and immediate access to nearly 10 TB of media, my own 2.5 included.  I could, if I chose to, download their collections to my Hybrid, and in the case of videos, usually do.  But, I use SSHFS nearly exclusively, for internal network sharing as well, and just want to stick with a stable, secure (encrypted) standard across the board.

In the case of a performance hit, I'm not sure I've got anything to worry about there, as all my hardware is well in excess of the recommended system spec...  I've actually had to REMOVE RAM, due to the lack of amd64 support as yet, and spread the extra out among the MD's.  Also, according to some (such as OP in this thread: http://ubuntuforums.org/showthread.php?t=1090085), SSHFS performs much BETTER than NFS, in regards to the network...

Anyhow, it seems that I was incorrect in my assumption that I had set up the SSHFS / AutoFS correctly.  I had access to all the media, until reboot, at which time the /etc/auto.master file was over-written for some unknown reason, and has been each reboot since.

edit:  added reference...
« Last Edit: November 17, 2009, 03:45:10 pm by tekoholic »

jimbodude

  • Guru
  • ****
  • Posts: 372
    • View Profile
Re: Add SSHFS to the options for file server.
« Reply #3 on: November 17, 2009, 04:36:28 pm »
...Yes, the auto.master is generated on the fly by LinuxMCE based on what storage devices are in the database.  You would need to create an SSH file share device for this to work properly.

I'm not sure what, exactly, would be involved to add SSH functionality, but here's some starting points:
http://wiki.linuxmce.org/index.php/Storage_Devices
http://wiki.linuxmce.org/index.php/Howto:_Using_Network_Shares

Take a look at the similarities and differences between how Windows/Samba and NFS shares are handled - that might also provide some clues.  It seems to me that most of the plumbing should already be there for this, and the models provided by Samba and NFS handling should provide a good guide on where to go for SSH.

Enigmus

  • Veteran
  • ***
  • Posts: 132
    • View Profile
Re: Add SSHFS to the options for file server.
« Reply #4 on: December 10, 2009, 02:05:42 pm »
I currently have a trusted and DMZ sections of my network.  I have setup rsync scripts to sync media (over ssh) on the untrusted to the LMCE network.  This works, but it would be nice to SSH media connections supported within the LMCE framework.

tschak909

  • LinuxMCE God
  • ****
  • Posts: 5549
  • DOES work for LinuxMCE.
    • View Profile
Re: Add SSHFS to the options for file server.
« Reply #5 on: December 10, 2009, 02:35:31 pm »
Patches always welcome.

-Thom

Enigmus

  • Veteran
  • ***
  • Posts: 132
    • View Profile
Re: Add SSHFS to the options for file server.
« Reply #6 on: December 17, 2009, 07:32:33 pm »
LOL, I'm sure they are, but at that point it wouldn't be submitting this as an idea.  It would just be announced as a new patch in the dev queue.