[APP][4.0.3+][NO Root] LAN drive - Samba Filesharing Server SMB1 and SMB2

Search This thread

poppyto

Senior Member
Jul 17, 2009
58
40
output from your debug interface is attached.

My file manager never ends in connecting/reading the root share. And your app has created now >7 connections to my PC.

I hope you can see something in the debug file.
This afternoon I have only ~2 hours time and tomorrow morning I am not at home.

Here the changelog for the new version 1.6 incoming :
  • Android Bug Fix : With Android < 6.0, you could not access "Root" share (thanks tramp20)
  • Android New behavior : Stop wavelock when WLAN is down and start it again when WLAN is up (battery saver) (thanks tramp20)
  • Android New behavior : Save last path where you backuped your settings for fast finding on recovery (thanks tramp20)

I updated my ROM to 5.1 and I had the same bug as you (Linux kernel has few differences with 6.0 ROM) so I could update, it should work like a charm now.
Let me know if it's ok for the wavelock too.
Again, thanks for the feedback, really appreciate ;)
 
  • Like
Reactions: svbarbosa

tramp20

Senior Member
Jan 15, 2012
798
166
Rosenheim
Apps & Games
Thank you for the updates.
I had no time to test all but access to the root share does not work (I have now v1.7) on Android 5.1.1 and 4.2.2 -:(

The other test will follow.

Edit:
With v1.5 I could access the root shares from my other smartphone and vice versa. This now does no longer work.
 
Last edited:

EasyGame7

Senior Member
Jan 11, 2015
57
4
I can't connect throudh Explorer

attachment.php
 

Attachments

  • oppo.png
    oppo.png
    7.3 KB · Views: 823

bucefal82

Member
Nov 16, 2012
35
88
Ryazan
bucefalportal.ru
Awesome interface brakes, you press adjustments and wait for 30 seconds until you go to the setup page. Do not boot up a splash screen, older version 1.5.
Xiaomi mi6 android 7.1.1
 

poppyto

Senior Member
Jul 17, 2009
58
40
Thank you for the updates.
I had no time to test all but access to the root share does not work (I have now v1.7) on Android 5.1.1 and 4.2.2 -:(

The other test will follow.

Edit:
With v1.5 I could access the root shares from my other smartphone and vice versa. This now does no longer work.

Could you send me back the debug thing please, (I add some log to help) it will help me :)
 

EasyGame7

Senior Member
Jan 11, 2015
57
4
Could you ping "Oppo" and check it's the IP phone ?
Could you access with \\x.x.x.x with the IP phone and let me know ?

Thanks for your reply.
I try with \\x.x.x.x ( \\devicename too) and it connected but when I click to the folder new dialog appear (except LAN Drive Folder, it's said empty in Explorer)
attachment.php


and in the app interface of those folder said "This folder is empty"
And Folder Picker is blank

Update: After I Reset the Sharings, the old dialog about "Window cannot access..." appears again
Reset the phone and open app, it can connect to the server like before. But the blank folder in app interface and windows error dialog still there.

Sorry for my bad English

My OS: RR Lollipop 5.1.1, Magisk Su
 

Attachments

  • oppo1.png
    oppo1.png
    7.1 KB · Views: 765
Last edited:

ronmaz

New member
May 27, 2018
1
0
Version 1.6 broke apostrophes

Hello,
From version 1.6, any file or folder name with an apostrophe doesn't display correctly in my file manager. I have LAN drive installed on an Android TV box with 2 USB drives connected. When I look at the contents of the USB drives using a file manager on my PC, the apostrophe and anything after it gets cut off.

It's hard to explain and I don't know how to paste images in here. For example. I have folders containing videos. Some of these folders are named:
Britain's Great War (2014)
Britain's Greatest Generation (2015)
Britain's Most Beautiful Lost Railways

Ever since version 1.6, they display in the file manager as:
Britain
Britain
Britain

Everything including the apostrophe and anything after it gets cut off.

I have had to revert to version 1.5 and it's working again.

Thanks,
Ron.
 

poppyto

Senior Member
Jul 17, 2009
58
40
Hello,
From version 1.6, any file or folder name with an apostrophe doesn't display correctly in my file manager. I have LAN drive installed on an Android TV box with 2 USB drives connected. When I look at the contents of the USB drives using a file manager on my PC, the apostrophe and anything after it gets cut off.

It's hard to explain and I don't know how to paste images in here. For example. I have folders containing videos. Some of these folders are named:
Britain's Great War (2014)
Britain's Greatest Generation (2015)
Britain's Most Beautiful Lost Railways

Ever since version 1.6, they display in the file manager as:
Britain
Britain
Britain

Everything including the apostrophe and anything after it gets cut off.

I have had to revert to version 1.5 and it's working again.

Thanks,
Ron.

Fixed, I just sent an updated (1.9) it will be available in few minutes

Fine, all shares incl. root are working now perfect :)

The next challenge for you are the permanent wakelocks when WLAN is off during night, they prevent the deep sleep completely.

PS. the list of changes of v1.8 is missing at the first start of LD.

Mmmm I already did it since 1.6, doesn't-it work ? (from my side I tested and it's ok but maybe there's something I didn't get, let me know)
 

poppyto

Senior Member
Jul 17, 2009
58
40
Thanks for your reply.
I try with \\x.x.x.x ( \\devicename too) and it connected but when I click to the folder new dialog appear (except LAN Drive Folder, it's said empty in Explorer)
attachment.php


and in the app interface of those folder said "This folder is empty"
And Folder Picker is blank

Update: After I Reset the Sharings, the old dialog about "Window cannot access..." appears again
Reset the phone and open app, it can connect to the server like before. But the blank folder in app interface and windows error dialog still there.

Sorry for my bad English

My OS: RR Lollipop 5.1.1, Magisk Su

Could you send me the log :

From a computer, while LAN drive is launched go here :
http://your_phone_ip:13000/debug.html?refresh=auto&refreshtime=1&orderby=desc
Then try to access Root sharefolder, the debug page should show/may something
Then save the page CTRL+S from your browser dans send it to me enclosed here

Thxs
 

poppyto

Senior Member
Jul 17, 2009
58
40
No, not solved with 1.8 :(
Nothing has changed.

I let the phone alone for 1:45 h.

The change log is missing for 1.8 and 1.9.

I may misunderstood the event.
When your phone goes in deep sleep, it stop the Wifi ? Or the fact LanDrive hold the wavelock, it doesn't stop it ?
For the moment I based my code on the fact when Wifi is off, the wavelock stop and when it's on, wavelock restart.
But if the wavelock hold it, how could I detect the deep sleep (it's not really a question, I will search but I need to know the behavior first ^^) ?
 

tramp20

Senior Member
Jan 15, 2012
798
166
Rosenheim
Apps & Games
I may misunderstood the event.
When your phone goes in deep sleep, it stop the Wifi ? Or the fact LanDrive hold the wavelock, it doesn't stop it ?
?

With Samba File Server and SambaDroid their server allow to go to deep sleep if the screen is off and therefor Android shuts down WiFi.

Lan Drive prevents with its permanent wakelocks almost 96% of the time (see screenshot) that the phone can go to deep sleep and therefor stays awake the whole time (even the whole night).

There is a difference between kernel and partial wakelocks (sorry I don't know it). It would be the best that you should install BetterBatteryStats so you can see this behavior.
 

poppyto

Senior Member
Jul 17, 2009
58
40
With Samba File Server and SambaDroid their server allow to go to deep sleep if the screen is off and therefor Android shuts down WiFi.

Lan Drive prevents with its permanent wakelocks almost 96% of the time (see screenshot) that the phone can go to deep sleep and therefor stays awake the whole time (even the whole night).

There is a difference between kernel and partial wakelocks (sorry I don't know it). It would be the best that you should install BetterBatteryStats so you can see this behavior.

I installed BetterBatteryStats and the wakelocks are right dropped after the inactivity period (in the settings, 30min by default but you can change it).
If i disable the wakelock, people can't connect to the phone when the screen goes off and that's not the excpected behavior (when an app run as a service, it should be available anytime).
How do you enable the 'deep sleep' mode ? special app ? I will have a look on this side
 

Top Liked Posts

  • There are no posts matching your filters.
  • 13
    iUUVcmJE6gWKe-YlSlReNiLeedXOUVaFtqxKZ1eqye5MU3LoQBi_0WK4vzgGRa6EvWY=s180-rw


    Introduction:
    LAN drive is an easy SAMBA Server for Android (iOS & WM10) devices.
    Access all your phone files - InternalStorage,SDCard,ExternalHDD - in read/write remotely with common softwares :
    • MAC OS Finder
    • Windows File Explorer
    • ES Explorer
    • VLC
    • Kodi
    • Any SMB client capable app
    You just have to be on the same network (WiFi) to make it work.

    There are 3 default network sharings activated :
    • 'LANdrive' : storage bound with the app (deleted when you clear cache of the app)
    • 'Root' : "/" access
    • 'InternalStorage' :
    • 'SDCard'|'HDD': Any other external storage automatically detected
    You can create your custom sharings too (bound to the app or select one with file picker)

    The app is free with an InApp purchase for unlocking the bandwidth (0.5 MB/s in trial) and remove ads, otherwise all is functionnal.
    We released it first at the end of January 2018 and are looking for feedback and help in making LAN drive the best it can be.

    Presentation Video:


    Works without ROOT:
    Read the tutorial inside the app (works on Windows / MAC / Linux)


    Features:
    • Copy/paste/rename files and folders on your device with MAC OS Finder, Windows File Explorer, Android ES Explorer, etc.
    • Access the 'external' storage (Photos and Videos included) in your device as a network shared folder.
    • Access the Root folder and all directories including SD Cards or external HDDs as network shared folders
    • View your multimedia files with embedded mediaplayer (or external app).
    • Your device name appears automatically in MAC OS Finder, Windows File Explorer, Android ES Explorer, VLC, Kodi etc.
    • Manage your device name (NetBios) and Workgroup name.
    • 3 authentication types : Anonymous with popup confirmation, Anonymous and Users with custom rights
    • Manage users and create your own shared folders with credentials.
    • View users connected and disconnect them.
    • Unlimited connections (several users can access your sharings at the same time)
    • 5 languages : English, Spanish, French, German, Italian.
    • Launched as a service in the background : Access your SMB server while using other apps
    • Optionally start the app after boot device completed
    • Protocols SMB1 (CIFS) and SMB2 protocol (enable/disable via settings)

    How Does It Work?
    LAN drive uses its own SMB1 & SMB2 implementation with an efficient way to announce itself on clients (your phone appears automatically in other software, even in Windows 10 File Explorer).
    You can choose 3 ways to authenticate :
    • Popup confirmation (default)
    • Anonymous
    • Create users with custom rights
    Even if it requires root access, LAN drive is non intrusive (not installed in app systems), nothing will stay in the system after uninstall it.


    Known issues
    • App startup time could be very slow (could take 10 seconds depending the devices).
      It's not something we can improve at the moment (framework loading Xamarin.Forms)
    • App Size : 26MB. We can't make it better, again Xamarin.Forms have some mandatory DLL to load to work

    Use cases:
    Some users don't know the powerfull use of SMB server, here some use cases:
    • Backup files, like you do with an USB key, but without the USB cable, and with security credentials.
    • Watch your movies/photos on your TV with Kodi (or VLC) streaming directly from your Phone.
    • Use a Backup utility from MAC or PC to create a scheduled task which backup|synchronize your movies/photos every days.
    • Developers|Hackers could browse Root "/" and edit/delete/copy/paste any files without using adb shell


    Who Are We?
    Webrox is a little french company of 2 persons, we build apps since 2011, check the Webrox store page here.
    We made LAN drive to have a very easy multiplatform SMB Server.



    How To Download:
    Google Play Download



    XDA:DevDB Information
    LAN drive, App for all devices (see above for details)

    Contributors
    poppyto

    Version Information
    Status: Stable
    Current Stable Version: 1.4
    Stable Release Date: 2018-05-14

    Created 2018-05-15
    Last Updated 2018-11-19
    2
    Some minutes ago LD does not shut down when WiFi was off or does not return when WiFi comes back. I could try this many times.
    Then I forced close LD (with the back key) and LD behaves normal again. I do not know how long :(

    This looks for me that perhaps a variable in your app is not always synchronized to the real state.

    Ok got the bug, my code only works if you push the nav (center) button instead of back button (which close the page) => I fix it now :)
    2
    No, that is not normal: during 14h 59m your app has during 98.6% of this time wakelocks. The battery drops normally during night from 100 to 95% but with your running discharges to ~70%.
    As you can see other apps in my screenshot they have all >0.2 %.
    Your app should detect this unused time during night (deep sleep) and when WLAN is off, there is no need to permanent check.
    BetterBatteryStats is a perfect app to detect things.

    And thank you to solve the other two points.

    You will have a lot of work for this app (fine tuning) :)

    Ok, I just sent an update,

    So, based on your comment about the battery drain:
    I add an auto stop after inactivity time (no connection on the server) you can change it in the settings (default:30min), I hope it will resolve your battery issue ;) let me know !

    Here the new changelog for 1.5 (will be available in 15 minutes I guess) :

    • New feature : Auto Stop server after inactivity time (change the duration in the settings, default : 30mn)
    • New feature : Backup and restore your settings on an external file
    • New behavior : Doesn't stop the server when button back on the homepage
    2
    How do you define inactivity? No more transfer over WLAN alone or over Lan Drive? Is screen on or off?



    That is ok.



    My Sony does this in the firmware but I think every Android smartphone does this too.
    Screenshot only in German.


    To the inactivity period: did you changed something here since v1.5? I remember that the LD server always stopped after the chosen time even the screen was on. So I did no longer used this function.

    The change logs are now complete for 1.8 and 1.9, don't know what happened on two phones.



    A little fast test:
    I selected two minutes, unplugged the charger, the screen shuts off and 10 mins later the LD server still is running and I can access the shares.
    So the phone can not go to deep sleep because of the wakelocks :(


    I attache a new debug file

    I sent the 2.0 version, now the server auto stop when WLAN is down and restart when WLAN is up again.



    On the new version (2.0), it include busybox => it should work for you now :)
    1
    You're welcome :)
    Here are the previous messages from the original thread

    I hope no one will be upset with my post, specially the OP.

    But since there is no update for Samba Filesharing since 2014, I feel obligated to share my discovery.

    Yesterday I found an alternative app in play store: LAN drive - SAMBA Server.

    In preliminary tests it works well and seems faster than Samba Filesharing. But be aware that the free version has a speed limit. To use LAN drive at full speed you have to pay.

    The app has been released on January 25, 2018. There are constant updates and the dev seems active and responsive.

    I made this discovery because there was no way Samba Filesharing would work in my Moto Z2 Play. Due to the nightmare of using MTP I started searching for alternatives. I found LAN drive and it worked like a charm.

    When creating your accounts and shares, my advice is first create all your shares and then add users. If you follow the app suggested sequence you will end up with your custom shares not accessible from your PC.

    If you use file synchronization software be aware that LAN drive has a bug. Files written to the phone do not get the time stamp updated to the source file time stamp. I will report this to the dev and hope it gets fixed soon.

    Hello svbarbosa, I'm the LAN drive developer.
    I will fix the issues of users rights and wrong timestamp on monday.
    I would like to tell other users LAN drive is a non intrusive app (it doesn't install anything in the system apps and it only work when you started it, security is a big thing these days).
    If anybody have a feedback, feel free to test LAN drive and feedback me ;)

    @poppyto, welcome to XDA!

    Glad to confirm you are really active and responsive. ;)

    I have also seen your answer to my email and will get on it soon. Some family errands to run first. :p

    Take your time to fix the issues. We have been waiting for so long to have samba support that we can sure handle waiting some more time to have your fixes.

    And please do start the LAN Drive app thread. I am a long time user of Samba Filesharing and despite it seems to be dead in terms of new development, somehow I feel weird talking about a replacement app here. :eek:



    I had problems with Samba Filesharing not working in my Moto Z2 Play, it is my first phone where Samba Filesharing would not work. Shares do not appear on my PC.

    I did some research and foung a great replacement app. Check it out in my previous post #235.

    Can you make LAN drive compatible with android 2.3 too?
    Or
    Can you give me another version of it which is compatible with android 2.3?

    Unfortunately, Xamarin Forms needs at least Android 4.0.3, and I can't make it better :/

    I was happy to found your app, but nothing works (I have paid in the meantime):
    1. I cannot make a new user
    2. I cannot change sharings etc.
    3. I cannot change device name and so on.

    your app does not accept any input :(

    Until now I am using Samba FileServer or SambaDroid

    You could make a own XDA thread here if your app really works.

    Sony Z1c stock rom 5.1.1 rooted

    Hello tramp20,

    I will open a support thread for LAN drive. I am not the developer, just a user of the app willing to help.

    LAN drive is working fine in three of my phones.

    In the meantime please let us know your phone model, Android version / rom, kernel if not stock and from which device/PC you are trying to access the phone.

    1.
    I wrote this two times: Sony Z1c stock rom 5.1.1 rooted

    As I cannot change the settings I cannot get a connection to my Win10 PC.

    As I wrote too I have no problems with Samba File Server or SambaDroid.

    2. On a very old LG P970 (Android 4.x) I can change the settings of this app but I don't see this phone in my network because Lan Server catches a wrong IP address (perhaps mobile and not WLAN).

    This app is in my eyes only alpha quality until now.

    My bad. I am having a tough work period and missed the last line in your post. :p

    For now, in your Sony, please uninstall and reinstall from Play Store. This will wipe data for LAN Drive make sure you have the latest update.

    Then create one user and one share. It should work.

    Turn of mobile data in settings and check if you can see it from your PC.

    Hi,
    since Lan Drive v1.3 I can configure this app now:)
    But there are problems of course:
    1. During deep sleep of my device I have wakelocks the whole time (battery is discharging badly), See attached screenshot.
    2. If I de-install the app and make a fresh new installation all shares are visible and I have access (not always). But after a short time or after stopping and restarting this app my device is no longer visible. I tested this on two smartphones several times. That is terrible.

    Wishes.
    A possibility to save and restore the settings on the (external) sdcard.
    2. If I tap on the back key the should NOT stop the smb server.

    If the smb server is running the transfer rate is very good compared to the old samba file server

    Well done. You beat me! Could not find the time to start the thread as I offered. :eek:

    Truth is I'm having an unusually tough period at work.

    Fortunately it is almost over and I will be able to help LAN drive development again real soon.