What's the trick to accessing NFS shares with Android XBMC?
#1
Hi, hoping someone can help me here:

I've been running XBMC quite well on my ATV2 for a while and recently I got an MK808B Android stick that I've installed XBMC on it. I've tried both the RC2 build and today's experimental build with hardware acceleration (this stick runs the Mali400 GPU). For the life of me, I can't get access to the NFS shares on my server. I've tried browsing, and it can see the top-level share folders but it can't navigate into them. I've also tried inserting the same exact share definition that my ATV2 has in sources.xml into the Android's sources.xml, and I still can't access it. In other words, the same share that works flawlessly in iOS won't come up in Android. Any ideas?

This is a Windows 2008 Server running the Windows native NFS server. According to the Windows Event Viewer the shares are getting correctly mounted when I try to browse them in XBMC, but I get nothing in XBMC.

I've seen the XBMC wiki and apparently Android NFS should be working since Beta 3? Any ideas on how I can troubleshoot this?

Thanks!

Reply
#2
xbmc.log is needed. Its most likly about userid mapping - so the server configuration is the fault (keep in mind - atv2 connects with uid 501 - not sure which uid your droid is using ...).
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
#3
(2013-01-21, 12:40)Memphiz Wrote: xbmc.log is needed. Its most likly about userid mapping - so the server configuration is the fault (keep in mind - atv2 connects with uid 501 - not sure which uid your droid is using ...).

Thanks for the response, much appreciated. You were correct, this turned out to be a user mapping issue. I had forgotten that I spent quite a bit of time on user mapping when I configured iOS XBMC, and I did in fact have a user mapped to UID 501 on my Active Directory server. In Android it appears that each app runs in its own UID. It took a little time, but I eventually determined the UID of the XBMC app, and assigned a new user with that UNIX credential to my domain. Boom, everything started working immediately! The only way I could get the XBMC's UID in Android was to install an app called "Quick System Info", which lists all apps and gives info about them. I believe the UID for an app is permanent, so I should be all set, perhaps until I reinstall it.

For anyone else's info, following was the debug info that I was seeing in the XBMC log upon trying to connect (before fixing the mapping issue):

08:01:36 T:1701152184 DEBUG: : trying mouse action leftclick
08:01:36 T:1738219888 DEBUG: NFS: Context for 192.168.1.140/Movies not open - get a new context.
08:01:36 T:1738219888 DEBUG: NFS: Connected to server 192.168.1.140 and export /Movies
08:01:36 T:1738219888 DEBUG: NFS: chunks: r/w 32768/32768
08:01:36 T:1738219888 ERROR: Failed to open(//) opendir call failed with "NFS: READDIRPLUS of // failed with NFS3ERR_ACCES(-13)"
08:01:36 T:1701152184 ERROR: - Error getting nfs://192.168.1.140/Movies/
08:01:36 T:1701152184 ERROR: CGUIDialogFileBrowser::GetDirectory(nfs://192.168.1.140/Movies/) failed
08:01:36 T:1701152184 DEBUG: Unfocus WindowID: 10126, ControlID: 450


Reply
#4
Thanks awp0, I spent ages trying to resolve this issue and your post is spot on.

Downloaded "Quick System Info" and got the correct UID to map for the NFS server.

Now my Gotham XBMC on android is playing via wifi without stopping, using a windows XP laptop as the NFS server.

Thanks again.
Reply
#5
So, Quick System Info shows that xbmc is running with the user id 10000 on my FireTV.
Still, I have fundamental problems and questions.

The Admin-User-ID on my NFS Server (iMac) has UID 501. The "-mapall=501" entry in my NFS-exports-file is supposed to map any client user as this Server-User, who has the necessary permissions. So I do not understand at all why the client-ID matters in any way.

Nevertheless, I added another user on my iMac with the UNIX-UID 10000.

Now I tried "-mapall=10000", but still it does not enable xbmc to access the NFS-Shares (they are displayed in xbmc, but the connection does not succeed).

Can you post the configuration of your shares (as contained in the exports-file)?
Romanes eunt domus
Reply
#6
Because you need to ensure that user 10000 has access on filesystem level (e.x. after mapping the uid you must change the filesystem permissions on the exported folders).
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
#7
Hi Memphiz,

I explicitly added the new User to the Permissions of the folders in OSX, but still the problem exists.

For example, the entries in exports now are "-alldirs -mapall=10000 192.168.1.100"
Still, the nfs-paths are shown in xbmc, but cannot be accessed.
I always restart the nfsd-service on my iMac after making changes.

I still do not understand why the extra user has to be added, the way I understood your wiki and the "-mapall"-string
is that ANY client that tries to connect via NFS will be mapped as e.g. 501 (the active user-UID on my iMac with admin status)...

Also, I checked again if the -n flag is set, which it is (although I did not need this string while using xbmc on the ATV2, where nfs was working fine).
Romanes eunt domus
Reply
#8
Yep the mapall to 501 should be enough. The error you are seeing in the log file still points to filesystem level permissions are wrong. (i don't want to annoy you Wink - its what the log says ...).

Post an "ls -al" of one of the folders you are not able to access from XBMC. (with the user id 501 in place - the 10000 is unneeded in normal use cases - its only needed if you want to lock your 501 out from the shares while granting XBMC access to it for example).
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

Logout Mark Read Team Forum Stats Members Help
What's the trick to accessing NFS shares with Android XBMC?0