• 1
  • 2
  • 3
  • 4(current)
  • 5
  • 6
  • 12
[AppleTV2] NFS on Apple TV 2?
#46
darkscout Wrote:...
It looks like mountd is running on privileged ports.

Memphiz Wrote:...
PS: i think you could have missed the "insecure" option - but only a rough guess...

You two are absolute wizards Smile
Did some reading, seems that is the case.

I'll return once I find the right keyword to throw at the /etc/exports to accept "insecure" mount requests.
It's slightly different on *BSDs NFS server implementation. It wont accept the keyword insecure.

[edit]
It ought to be 'nfs_reserved_port_only="NO"' in /etc/rc.conf on the BSD box. It apparently isn't enough. I'm still getting those entries in the log file.
However, as long as those entries are there I can only conclude it isn't an XBMC problem. So thank you for your help! Smile
Conclusion: XBMC doesn't mount as root -> it's using ports > 1024 (so called unprivileged ports). FreeBSDs NFS implementation does not allow mounts from ports > 1024 (unprivileged ports) per default. The recommended way to disable this didn't work for me - may work for others.
Reply
#47
what about "sysctl -w vfs.nfs.nfs_privport=0" ... would be great if you would get it to work ... then i could add it to the wiki Wink ... we can't do much about it ... XBMC runs as unprivileged user on iOS and it can't use ports <1024 Sad
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much: click here
HowTo setup NFS for Kodi: NFS (wiki)
HowTo configure avahi (zeroconf): Avahi_Zeroconf (wiki)
READ THE IOS FAQ!: iOS FAQ (wiki)
Reply
#48
jackolantern Wrote:i am trying allegro NFS on my windows 7 box since SMB does not report netbios to windows and SMB shares freak out. anyone had any experience with this?

i havn't experience with it ... but same to you ... if you get it running - post your config so that i could add it to the wiki ...
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much: click here
HowTo setup NFS for Kodi: NFS (wiki)
HowTo configure avahi (zeroconf): Avahi_Zeroconf (wiki)
READ THE IOS FAQ!: iOS FAQ (wiki)
Reply
#49
Memphiz Wrote:what about "sysctl -w vfs.nfs.nfs_privport=0" ... would be great if you would get it to work ... then i could add it to the wiki Wink ... we can't do much about it ... XBMC runs as unprivileged user on iOS and it can't use ports <1024 Sad

That oid isn't present on the FreeNAS version I'm running [0.7.2 Sabanda (revision 5872)]:
Code:
jr-nas:~# sysctl -w vfs.nfs.nfs_privport
sysctl: unknown oid 'vfs.nfs.nfs_privport'


But I'll make sure to add the solution to this thread once I find it. I have a busy work week ahead of me, so I should have plenty of time to google :p
Reply
#50
i've read that one should add "-n" when starting mountd ... don't know how to do that ... but maybe you could just kill your mountd and restart per hand with mountd -n or something like that (i'm not giving up...)

maybe add it like this to /etc/rc.conf

mountd_flags="-n"
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much: click here
HowTo setup NFS for Kodi: NFS (wiki)
HowTo configure avahi (zeroconf): Avahi_Zeroconf (wiki)
READ THE IOS FAQ!: iOS FAQ (wiki)
Reply
#51
Memphiz Wrote:i've read that one should add "-n" when starting mountd ... don't know how to do that ... but maybe you could just kill your mountd and restart per hand with mountd -n or something like that (i'm not giving up...)

maybe add it like this to /etc/rc.conf

mountd_flags="-n"

That actually did the trick. I stopped the mountd, and started with -n.

Relevant entries in rc.conf:
Code:
nfs_server_flags="-u -t -n 4"
nfs_server_enable="YES"
nfs_reserved_port_only="NO"
...
mountd_flags="-n"
mountd_enable="YES"

I'm unsure if sequence is important. FreeBSD isn't my OS of choice to say the least.

Now at least I can mount it before xbmc crashes - but let's attribute that to the nightly and a less-than-clean userdata dir.
Code:
..
10:32:55 T:98398208 M:121573376   DEBUG: SECTION:LoadDLL(libnfs.1.0.0.dylib)
10:32:55 T:98398208 M:121573376   DEBUG: Loading: /var/stash/Applications/XBMC.frappliance/Frameworks/libnfs.1.0.0.dylib
10:32:55 T:98398208 M:121561088   DEBUG: NFS: Connected to server 192.168.1.200 and export  (chunks: r/w 32768/32768)
..


I'll restart my NAS now and make sure everything autostarts correctly.

Memphiz & darkscout, you two deserve a beer if you ever visit Denmark Wink
Reply
#52
was there before 2 years *hrhr* ... well for the crash it would be great to have the crashlog ... the current crashes we noticed where all the same and should be fixed in trunk already - but would be nice to have a look at it to be sure (for getting the crashlog have a look at the first link in my sig ...)
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much: click here
HowTo setup NFS for Kodi: NFS (wiki)
HowTo configure avahi (zeroconf): Avahi_Zeroconf (wiki)
READ THE IOS FAQ!: iOS FAQ (wiki)
Reply
#53
can someone tell me what my etc/exports file should look like on OSX to share an entire drive via NFS?

is this ok:

/Volumes/toshiba320gb -alldirs *(rw,all_squash,insecure,async,no_subtree_check,no_ac1)

Or is that more like linux verbiage instead?

when i try to add a source (editing "none") to ATV on 4.2.2 XBMC 10.0-9 official like this:

nfs://192.168.1.106/toshiba320gb

it crashes XBMC right away.
Reply
#54
trevorcobb Wrote:can someone tell me what my etc/exports file should look like on OSX to share an entire drive via NFS?

is this ok:

/Volumes/toshiba320gb -alldirs *(rw,all_squash,insecure,async,no_subtree_check,no_ac1)

Or is that more like linux verbiage instead?

when i try to add a source (editing "none") to ATV on 4.2.2 XBMC 10.0-9 official like this:

nfs://192.168.1.106/toshiba320gb

it crashes XBMC right away.

Check the Wiki but BSD/OS X is very different than Linux.

'man exports' from the command line should do it.

Also for "insecure" startup with the -N flag.

Everything is 'flags' with the BSDs. And I think alldirs is superfluous, because you're not actually mounting each folder.

/Volumes/toshiba320gb * -mapall=[user]

*user being who 'owns' the files on toshiba.

That's really all you need.
Code:
GRANT ALL PRIVILEGES ON `xbmc_%`.* TO 'xbmc'@'%';
IF you have a mysql problem, find one of the 4 dozen threads already open.
Reply
#55
My Linux exports are like this and it works

/srv/raid2Ter/Myndir 192.168.10.0/24(rw,async,no_root_squash,no_subtree_check,insecure)

I tried skipping the insecure part and then my ATV2 did not mount.

However NFS was causing ATV2 to crash all the time for me.( much more then on ftp:// and SMB:

So I could not get any relative speed benchmarks on streaming.

Saved my sources.xml.nfs Smile so I can do an easy switch on a later date.
Reply
#56
crash log please ... see my sig - first link for howto do it ... trevorcobb your source path is wrong ... you have to put the fullpath after the slash ... and the exports is for linux ... take a look at my second link in my sig for getting pointers for howto setup nfs on macosx... am back in 3 days and hope you figured it out then Wink
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much: click here
HowTo setup NFS for Kodi: NFS (wiki)
HowTo configure avahi (zeroconf): Avahi_Zeroconf (wiki)
READ THE IOS FAQ!: iOS FAQ (wiki)
Reply
#57
darkscout Wrote:/Volumes/toshiba320gb * -mapall=[user]

*user being who 'owns' the files on toshiba.

That's really all you need.

when I type "id" in terminal on my osx machine that is serving the shared drive, it tells me that my username "trevorcobb" = UID 501.

i understand that the user mobile on the ATV2 is also UID 501.

So do I put

/Volumes/toshiba320gb * -mapall=501

??

Also, in your later post you talk about including the full path after the slash in XBMC on my ATV2. so it should be:

nfs://192.168.1.106/Volumes/toshiba320gb

??

thanks for all your help!
Reply
#58
trevorcobb Wrote:when I type "id" in terminal on my osx machine that is serving the shared drive, it tells me that my username "trevorcobb" = UID 501.

i understand that the user mobile on the ATV2 is also UID 501.

So do I put

/Volumes/toshiba320gb * -mapall=501

??

Also, in your later post you talk about including the full path after the slash in XBMC on my ATV2. so it should be:

nfs://192.168.1.106/Volumes/toshiba320gb

??

thanks for all your help!

Well, I guess if that's the case in reality you really don't even need to map the user.

And yes, you need the full path as such.
Code:
GRANT ALL PRIVILEGES ON `xbmc_%`.* TO 'xbmc'@'%';
IF you have a mysql problem, find one of the 4 dozen threads already open.
Reply
#59
How do you deal with spaces in the nfs path name?
I was dumb and included a space within my external drive's name.

in xbmc on the atv2 would it just be:
nfs://10.0.1.101/Volumes/Drive Name

or do i need to use a \ or single or double quotes?
could i alter my /etc/export to share the /Volumes directory instead?
Reply
#60
k, one more question gents...

i have an NFS share working from OSX 10.7 Lion GM to XBMC 10.0-9 on ATV2 4.2.2 using the advice I received above (thank you!!!!!!), I just can't see any subdirectories in that share. i can only see actual files listed there.

what can i do to make it so that all the subdirectories and files they contain are visible over NFS?

This is how my /etc/exports looks btw...

/Volumes/toshiba320gb -mapall=501 -alldirs

(when I had the * added in it wouldn't show up under showmounts)
Reply
  • 1
  • 2
  • 3
  • 4(current)
  • 5
  • 6
  • 12

Logout Mark Read Team Forum Stats Members Help
[AppleTV2] NFS on Apple TV 2?0