VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

iOS, iPad, iPhone, tvOS specific usage questions
ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 02 Jul 2020 23:35

I've seen several historical threads on these problems but can't figure out if there are any canonical solutions:

(1) No matter what I do, VLC for Apple TV always prompts me for username/password, even when I chose to save them. Is this a bug? Any workarounds?

(2) I often get "empty folder" after connecting to an SMB share, often after being prompted to log in again. Is there any systematic way to troubleshoot and eliminate this problem?

Alternatively, if I set up my SMB share as anonymous (guest ok / guest only), such that "anonymous login" from VLC works, is there any way to save this setting so I don't need to navigate to "anonymous login" every time I select the share?

My SMB share is served from an Ubuntu Linux box, FWIW.

fkuehne
Developer
Developer
Posts: 7264
Joined: 16 Mar 2004 19:37
VLC version: 0.4.6 - present
Operating System: Darwin
Location: Germany
Contact:

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby fkuehne » 04 Jul 2020 12:19

1) This is a bug and it's (finally!) fixed for the next update.

2) This should be resolved by the fix for 1).
VideoLAN
Felix Paul Kühne
Medic. VLC developer for appleOS since before you were born.
Blog: https://www.feepk.net

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 24 Jul 2020 01:11

Is there any workaround for the empty folder problem in the meantime? Makes it impossible to play content. Or any ETA on the fix?

summit48
Blank Cone
Blank Cone
Posts: 61
Joined: 07 May 2016 02:58

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby summit48 » 24 Jul 2020 04:05

See changelog link:

https://code.videolan.org/videolan/vlc- ... /Docs/NEWS

There are other Credentials issues with Network Shares that I have observed, I will wait for the upcoming update to see if they are fixed.
Last edited by summit48 on 24 Jul 2020 04:12, edited 1 time in total.

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 24 Jul 2020 04:12

Does that mean it’s been released and submitted to the App Store for approval?

summit48
Blank Cone
Blank Cone
Posts: 61
Joined: 07 May 2016 02:58

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby summit48 » 24 Jul 2020 04:18

If you are keen maybe sign up as a Beta Tester.

https://testflight.apple.com/join/bbyXP6Lx

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 24 Jul 2020 04:29

If you are keen maybe sign up as a Beta Tester.

https://testflight.apple.com/join/bbyXP6Lx
Thanks for the tip! Just tried it from the iPhone and the empty folder problem seems fixed. Will try on Apple TV shortly.

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 07 Aug 2020 04:48

Just tried the testflight version on latest gen Apple TV. Still getting "empty folder" for every share. I also tried exporting a folder as a NFS share and connecting through the new NFS functionality--"empty folder" with that as well.

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 10 Aug 2020 15:39

Does anyone have any suggestions of things I could tweak server-side for my SMB share or NFS export to avoid the "empty folder" problem? When I first installed VLC on AppleTV I didn't always see this error, but now I get it 100% of the time so I'm unable to play any content. Same issue with the latest stable release as well as the latest release available in TestFlight; same with SMB and NFS.

summit48
Blank Cone
Blank Cone
Posts: 61
Joined: 07 May 2016 02:58

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby summit48 » 11 Aug 2020 10:32

ATV-4K-32GB
tvOS: 13.4.6 (17L570)
VLC-tvOs: 3.0.10 (392)

I have tested accessing Public Folders on Win10 Pro -1909 & OS X 10.11.6.

I only get the empty folder displayed for a split second on OS X and none on Win10.

The credentials not being saved is annoying, but using a ATV Remote App on the iPhone makes it a little bit easier.

I only type Username: guest, once using the keyboard on the iPhone App and Save. As long as I don't power the ATV OFF I just select LOGIN the next time (all the fields can be blank).

What version of Ubuntu are you running?

Rory
Blank Cone
Blank Cone
Posts: 14
Joined: 22 May 2016 02:09

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby Rory » 11 Aug 2020 17:10

Hopefully this fix gets released soon. Been over a month of this annoying issue.

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 11 Aug 2020 17:37

I'm on fully updated Ubuntu 20.04.1 LTS.

I did find a fix, though. For NFS, it turns out I just needed to tweak options on the server in /etc/exports:

Code: Select all

/home/path 192.168.4.0/255.255.0.0(ro,subtree_check,sync,all_squash,insecure)
seems to work.

For SMB, I'm able to connect to the share through the "Connect to Server Generic" option (VLC logo icon) on the left under "Local Network". The same server also shows up as an SMB share immediately to the right of the "generic" option with the file cabinet icon and title "MOVIES SMB". I've tried logging in as an authenticated user, logging in as "guest", and using "anonymous login" on this icon and they all give an "empty folder" result. For testing purposes, the share itself is configured to allow guest/anonymous access, as well as username/password authenticated login. Also, no matter what I put in for those settings on the SMB share, it always goes back to empty settings the next time I select it -- even if I chose "save" on my last session.

summit48
Blank Cone
Blank Cone
Posts: 61
Joined: 07 May 2016 02:58

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby summit48 » 12 Aug 2020 02:06

The icons to the right of "Generic" are the hosts VLC discovers and they are the ones I use.

I get the empty folder displayed for a split second, so I suspect(just a hunch) there is a handshake between VLC and the Server to fill the content of the "empty folder".

This leads me to ask, what type of network do you have?

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 12 Aug 2020 15:55

All relevant devices are connected to the network via gigabit Ethernet. My router is an Eero (I have several Eero nodes throughout my LAN but all are connected via Ethernet). It makes no difference if I set a fixed IP address or use DHCP.

I'm also using ATV-4K.

It's interesting that the hosts VLC discovers work for you but not for me, while the "Generic" does work for me, at least with the Testflight release of VLC for Apple TV.

I suspect it's something about how the SMB share is configured. Does anyone have a Samba share config file that works 100% of the time?

summit48
Blank Cone
Blank Cone
Posts: 61
Joined: 07 May 2016 02:58

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby summit48 » 13 Aug 2020 02:33

If VLC-tvOS is NOT automatically seeing the Ubuntu SMB device then you most certainly have a Network Discovery issue. The problem is either the eero network or the Ubuntu SMB device.

However if you believe the problem is VLC-tvOS then a simple test is to install Infuse(alternative APP to VLC) on the ATV-4K and see if it is able to discover the Ubuntu SBM node.

Another simple test is to put all your devices on one Layer 2 Ethernet switch and connect it directly to a Ethernet port on the eero router.

I use Ubiquiti Unifi USG-3P, Unifi AP AC Pro and a Layer 2 Ethernet switch and have NO SMB Network Discovery issues.

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 13 Aug 2020 04:12

To be clear, ATV-VLC autodiscovers the SMB share with no problem. It’s just when I select it, I always get an empty folder.

When I go through the “connect to generic server” option and manually identify the same server by IP address, I do not get an empty folder.

I’ll follow up on your other suggestions.

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 14 Aug 2020 03:59

Infuse sees the SMB share as well as all of the files without a problem.

VLC (latest Testflight build) sees the auto-discovered SMB share but only shows "empty folder".

VLC shows the contents of the folder if I go through "connect to generic server."

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 14 Aug 2020 20:07

I've (mostly) figured it out.

First, I noticed after restarting smbd/nmbd many times and restarting ATV-VLC (without changing settings for either of them), sometimes I was able to avoid the "empty folder" option and access content, but usually not.

Then, I turned on verbose logging in SMB and found these errors:

Code: Select all

[2020/08/14 13:43:05.909275, 3] ../../lib/util/access.c:369(allow_access) Allowed connection from 192.168.4.78 (192.168.4.78) [2020/08/14 13:43:05.909864, 3] ../../source3/smbd/oplock.c:1414(init_oplocks) init_oplocks: initializing messages. [2020/08/14 13:43:05.909968, 3] ../../source3/smbd/process.c:1955(process_smb) Transaction 0 of length 58 (0 toread) [2020/08/14 13:43:05.909996, 3] ../../source3/smbd/process.c:1548(switch_message) switch message SMBnegprot (pid 1014939) conn 0x0 [2020/08/14 13:43:05.910486, 3] ../../source3/smbd/negprot.c:636(reply_negprot) Requested protocol [Samba] [2020/08/14 13:43:05.910522, 3] ../../source3/smbd/negprot.c:636(reply_negprot) Requested protocol [NT LM 0.12] [2020/08/14 13:43:05.910659, 3] ../../source3/smbd/negprot.c:757(reply_negprot) reply_negprot: No protocol supported ! [2020/08/14 13:43:05.910963, 3] ../../source3/smbd/server_exit.c:243(exit_server_common) Server exit (no protocol supported ) [2020/08/14 13:45:27.076033, 3] ../../source3/smbd/server_exit.c:243(exit_server_common) Server exit (termination signal)
Googling suggested adding the following to smb.conf

Code: Select all

min protocol = NT1
After making this change, I was able to use the autodiscovered SMB share from ATV-VLC; however, it always required a username/password, even for a share I had configured allowing guest/anonymous access. To fix this, I added

Code: Select all

[global] map to guest = bad user [share] guest ok = yes guest only = yes guest user = smbguest
And also created a local user smbguest with read permissions for the share.

After making these tweaks, I am reliably able to access the autodiscovered SMB share from Testsuite ATV-VLC. I still need to go through the login screen for the share every time I open it, regardless of whether I pick "login," "save," or "anonymous login." I don't know if this is intended behavior or not -- it seems like the user should be able to skip the login screen if the share allows anonymous access or if the user has saved credentials.

But at least I can now consistently access content on the network.

It's unclear to me why it would have worked extremely inconsistently before setting the "min protocol" on the server side (and there -- it consistently worked from "connect to generic server" but not from the autodiscovered share). It seems like there must be something odd about how VLC is trying to authenticate to the SMB server that is not consistent.

Hopefully this info can provide a clue to a more systemic fix for the client. At a minimum, it would be very useful if the ATV-VLC client could provide some feedback about why a connection is failing -- "empty folder" makes it seem like the user has connected but is not seeing any files. Instead, it appears at least in this case there was a failure to authenticate.

summit48
Blank Cone
Blank Cone
Posts: 61
Joined: 07 May 2016 02:58

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby summit48 » 15 Aug 2020 02:08

Good to see you were able to identify the SMB share problem on Ubuntu.

However I don't understand when you previously posted, "Infuse sees the SMB share as well as all of the files without a problem."

ajkessel
Blank Cone
Blank Cone
Posts: 29
Joined: 21 Oct 2009 02:33

Re: VLC - AppleTV to save SMB credentials and avoid "empty folder" problem?

Postby ajkessel » 15 Aug 2020 02:17

To clarify:

Both Infuse and VLC on Apple TV autodiscovered the SMB share.

From Infuse, I could access all the files on the SMB share without any problem.

From VLC, I got the "empty folder" error until I made the modifications to smb.conf noted above.

Even though I was able to fix this by modifying the SMB configuration, this is going to be extremely difficult for normal users to figure out, particularly since every other app I've used (including ones on other laptops and mobile devices) saw the SMB share and files therein without needing to modify the SMB configuration. Could VLC at least tell the user what is going with "empty folder"? It is also odd that even prior to modifying the SMB configuration, by repeatedly restarting SMB and VLC, I was occasionally (rarely) able to get it to work. But after modifying the SMB authentication mechanism as noted above, it works 100% of the time. It's also odd that VLC was always work with "connect to generic server" but, previously, always got "empty folder" when selecting the autodiscovered shared.


Return to “VLC for iOS, iPadOS and Apple TV”

Who is online

Users browsing this forum: Google [Bot] and 8 guests