nextcloud / android

📱 Nextcloud Android app
https://play.google.com/store/apps/details?id=com.nextcloud.client
GNU General Public License v2.0
4.23k stars 1.76k forks source link

Provide support for Samsung Galaxy devices: auto upload & synchronization | SD card #3814

Closed Sanookmakmak closed 3 years ago

Sanookmakmak commented 5 years ago

In the Nextcloud forum many users are reporting troubles with auto upload and synchronization on Samsung Galaxy devices.

Auto upload does not work correct and synchronisation is continuously interrupted when using a SD card.

nextcloud-android-bot commented 5 years ago

GitMate.io thinks possibly related issues are https://github.com/nextcloud/android/issues/790 (Remove Auto upload), https://github.com/nextcloud/android/issues/2670 (Auto upload On device directory), https://github.com/nextcloud/android/issues/3376 (Galaxy S8 still not auto-uploading in power save ), https://github.com/nextcloud/android/issues/1290 (Auto upload light ), and https://github.com/nextcloud/android/issues/3708 (Auto upload - sync conflict ).

cassdel commented 5 years ago

Not just autoupload - any upload fails.

Henk57 commented 5 years ago

This problem is over 2 years old. I do not use Nextcloud anymore for this, but my Synology app instead.

tobiasKaminsky commented 5 years ago

any upload fails.

This should then be a different bug. Do you see any error message in upload view?

tobiasKaminsky commented 5 years ago

We are using Samsung Galaxy S9+ in daily use and do not experience any problems, even with sdcard.

Sanookmakmak commented 5 years ago

I have Samsung Galaxy S5 Active and Samsung Galaxy Tab 12.2, both with Android 5. In my case, auto upload did NEVER work as expected.

Synchronization of big accounts are interrupted continousely. Does not work as expected as well.

This problem is over 2 years old

And there is still.

cassdel commented 5 years ago

@tobias: Random errors. I use Samsung S8+. SSL Initialization error is the most common, with connection error and some "unknown stuff". I really believe that Samsung have a issue with the certificates AND storage permissions that the devs are missing. But all other apps works great - including Banking (and Bank apps are very restrictive in Brazil). And my iOS/Windows/Linux devices works just fine.

ezaquarii commented 5 years ago

That sounds like Samsung indeed - they are known of doing some bonkers customizations with weird side effects.

I'm wondering what we can do immediately to gain some more insight into the issue. The diagostics around connectivity seems to be missing.

ezaquarii commented 5 years ago

@tobiasKaminsky anything we can do to improve the runtime instrumentation? @cassdel seem to be a good test subject to verify improvements, but I'm not sure where to start.

Okijames commented 5 years ago

Add me to the list, fresh install of v15, using a Galaxy S8+ with SD card. Everything seems to work except Auto Upload of existing pictures.

AndyScherzinger commented 5 years ago

Everything seems to work except Auto Upload of existing pictures.

Because that has never been implemented so it can't work !

gemurdock commented 5 years ago

I am having the same issue here. My Samsung can't seem to work with it.

Sanookmakmak commented 5 years ago

I am having the same issue here. My Samsung can't seem to work with it.

You mean, auto upload does not work correctly, do you?

gemurdock commented 5 years ago

I am having the same issue here. My Samsung can't seem to work with it.

You mean, auto upload does not work correctly, do you?

Yes. I had some things upload (not using auto upload), but not all of it worked. Then auto upload does not work at all. I have a Samsung Galaxy 8+ with latest OS.

tuxmartin commented 5 years ago

I have Xiaomi Redmi 6 (Android 8.1) and auto upload not working :-(

cassdel commented 5 years ago

I do believe that Samsung has other issues as well. Its not about Auto-Upload. Is simple does not upload anything at all.

@ezaquarii @tobiasKaminsky - Im ok to test/check whatever you need, just need the instructions and a place to put the logs back. Pretty sure that we'll find some bad stuff happening with the way that Nextcloud works with SABRE/Webdav or SSL on Samsung devices.

stale[bot] commented 5 years ago

This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

tobiasKaminsky commented 5 years ago

I do believe that Samsung has other issues as well. Its not about Auto-Upload. Is simple does not upload anything at all.

As this seems to be a more general upload problem, can you please create a new issue and can you provide us additional infos via logcat? https://github.com/nextcloud/android/blob/master/README.md#getting-debug-info-via-logcat

stale[bot] commented 5 years ago

This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

killoctal commented 5 years ago

Same issue on Galaxy S7. It work neigher with internal memory/SD card. App is on the battery non-watch list (unlimited usage). No ssl used I found people complaining about this problem since 2017 (2 years ago)

PS: my cloud is accessible from my Ubuntu client so server is ok

meika commented 5 years ago

a newbie nextclouder here, installed yesterday, the very first feature I tested out was the Android App Nextcloud 4. It's auto uploading new photos. Please highlight "New photos" somewhere, it's a bit distressing when the feature feels like a bug due to expectations surrounding the words "sync" "autosync". This ability to suck off and archive photos from the family's devices phones is the main reason I have explored nextcloud so, in terms of marketing (do those peeps come to github?) this little distraction needs to be tightened up. Remember appearing to-- over-promise and under deliver is baaaad.

framuc commented 5 years ago

I made the same experiences like killoctal with my S7: upload does not work. After an update today I tried it again and it still didn't work. But after playing around a bit with the upload I found out one thing: Only files bigger than 1MB fail to upload, smaller files are uploaded. The settings of my server allow an upload size of 10GB and I can also upload files much bigger than 1MB from the PC application. So maybe this information might help, or did I miss anything? [...] Ok, I just found this: https://github.com/nextcloud/server/issues/11192

stale[bot] commented 5 years ago

This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

atoav commented 5 years ago

Autoupload uploaded 2 images, and then stopped doing anything. Restarting the phone, adding and removing the autoupload from the folder etc. doesn't fix the behaviour (Galaxy S7 edge).

stale[bot] commented 5 years ago

This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

Dreytac commented 5 years ago

I have found that while autoupload doesn't work, as soon as I run Nextcloud, go to the uploads page and swipe down for a "refresh", suddenly everything starts to get uploaded. So it seems autoupload for me only works when I manually refresh the uploads page.

Using a Samsung Galaxy S9 with Nextcloud v3.8.0.

framuc commented 5 years ago

😘 Dreytac notifications@github.com schrieb am Mo., 7. Okt. 2019, 18:21:

I have found that while autoupload doesn't work, as soon as I run Nextcloud, go to the uploads page and swipe down for a "refresh", suddenly everything starts to get uploaded. So it seems autoupload for me only works when I manually refresh the uploads page.

Using a Samsung Galaxy S9 with Nextcloud v3.8.0.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/nextcloud/android/issues/3814?email_source=notifications&email_token=ALF3RCAZOMSH7ULGXIA7Y4DQNNOXXA5CNFSM4HCQ4C72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAQ6MRQ#issuecomment-539092550, or mute the thread https://github.com/notifications/unsubscribe-auth/ALF3RCDAT5MV6FV2YSYCU3LQNNOXXANCNFSM4HCQ4C7Q .

framuc commented 5 years ago

Ups, this was just sent by my almost 2years old son via my smart watch. But thanks anyway ;-)

😘 Dreytac notifications@github.com schrieb am Mo., 7. Okt. 2019, 18:21: … I have found that while autoupload doesn't work, as soon as I run Nextcloud, go to the uploads page and swipe down for a "refresh", suddenly everything starts to get uploaded. So it seems autoupload for me only works when I manually refresh the uploads page. Using a Samsung Galaxy S9 with Nextcloud v3.8.0. — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <#3814?email_source=notifications&email_token=ALF3RCAZOMSH7ULGXIA7Y4DQNNOXXA5CNFSM4HCQ4C72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAQ6MRQ#issuecomment-539092550>, or mute the thread https://github.com/notifications/unsubscribe-auth/ALF3RCDAT5MV6FV2YSYCU3LQNNOXXANCNFSM4HCQ4C7Q .

dfeyer commented 4 years ago

Samething here, Samsung S9+, no SD card, upload broken

Log from apache2:

192.168.1.22 - - [18/Nov/2019:21:10:55 +0000] "MKCOL /remote.php/dav/uploads/ncp/a90dcc79a331de8a89781210b26f4bb2 HTTP/1.1" 405 1548 "-" "Mozilla/5.0 (Android) Nextcloud-android/3.9.0" 192.168.1.22 - - [18/Nov/2019:21:10:56 +0000] "PROPFIND /remote.php/dav/uploads/ncp/a90dcc79a331de8a89781210b26f4bb2 HTTP/1.1" 207 2744 "-" "Mozilla/5.0 (Android) Nextcloud-android/3.9.0" 192.168.1.22 - - [18/Nov/2019:21:10:56 +0000] "PUT /remote.php/dav/uploads/ncp/a90dcc79a331de8a89781210b26f4bb2/0000000000000000-0000000003001557 HTTP/1.1" 400 1067 "-" "Mozilla/5.0 (Android) Nextcloud-android/3.9.0"

I configure the sync to create directory per year/month, those directories are created, but stay empty.

Really frustrating.

dfeyer commented 4 years ago

From the nextcloud.log

{
  "reqId": "XdMKSmiSE5XqWpnRNbW8eAAAAMk",
  "level": 4,
  "time": "2019-11-18T21:16:58+00:00",
  "remoteAddr": "192.168.1.22",
  "user": "ncp",
  "app": "webdav",
  "method": "PUT",
  "url": "\/remote.php\/webdav\/Documents\/Mobile\/Videos\/1556817465406.JPEG",
  "message": {
    "Exception": "Sabre\\DAV\\Exception\\BadRequest",
    "Message": "Expected filesize of 48242 bytes but read (from Nextcloud client) and wrote (to Nextcloud storage) 8192 bytes. Could either be a network problem on the sending side or a problem writing to the storage on the server side.",
    "Code": 0,
    "Trace": [
      {
        "file": "\/var\/www\/nextcloud\/apps\/dav\/lib\/Connector\/Sabre\/Directory.php",
        "line": 156,
        "function": "put",
        "class": "OCA\\DAV\\Connector\\Sabre\\File",
        "type": "->",
        "args": [
          null
        ]
      },
      {
        "file": "\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Server.php",
        "line": 1096,
        "function": "createFile",
        "class": "OCA\\DAV\\Connector\\Sabre\\Directory",
        "type": "->",
        "args": [
          "1556817465406.JPEG",
          null
        ]
      },
      {
        "file": "\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/CorePlugin.php",
        "line": 525,
        "function": "createFile",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": [
          "Documents\/Mobile\/Videos\/1556817465406.JPEG",
          null,
          null
        ]
      },
      {
        "function": "httpPut",
        "class": "Sabre\\DAV\\CorePlugin",
        "type": "->",
        "args": [
          {
            "absoluteUrl": "https:\/\/bovarde.mooo.com\/remote.php\/webdav\/Documents\/Mobile\/Videos\/1556817465406.JPEG",
            "__class__": "Sabre\\HTTP\\Request"
          },
          {
            "__class__": "Sabre\\HTTP\\Response"
          }
        ]
      },
      {
        "file": "\/var\/www\/nextcloud\/3rdparty\/sabre\/event\/lib\/EventEmitterTrait.php",
        "line": 105,
        "function": "call_user_func_array",
        "args": [
          [
            {
              "__class__": "Sabre\\DAV\\CorePlugin"
            },
            "httpPut"
          ],
          [
            {
              "absoluteUrl": "https:\/\/bovarde.mooo.com\/remote.php\/webdav\/Documents\/Mobile\/Videos\/1556817465406.JPEG",
              "__class__": "Sabre\\HTTP\\Request"
            },
            {
              "__class__": "Sabre\\HTTP\\Response"
            }
          ]
        ]
      },
      {
        "file": "\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Server.php",
        "line": 479,
        "function": "emit",
        "class": "Sabre\\Event\\EventEmitter",
        "type": "->",
        "args": [
          "method:PUT",
          [
            {
              "absoluteUrl": "https:\/\/bovarde.mooo.com\/remote.php\/webdav\/Documents\/Mobile\/Videos\/1556817465406.JPEG",
              "__class__": "Sabre\\HTTP\\Request"
            },
            {
              "__class__": "Sabre\\HTTP\\Response"
            }
          ]
        ]
      },
      {
        "file": "\/var\/www\/nextcloud\/3rdparty\/sabre\/dav\/lib\/DAV\/Server.php",
        "line": 254,
        "function": "invokeMethod",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": [
          {
            "absoluteUrl": "https:\/\/bovarde.mooo.com\/remote.php\/webdav\/Documents\/Mobile\/Videos\/1556817465406.JPEG",
            "__class__": "Sabre\\HTTP\\Request"
          },
          {
            "__class__": "Sabre\\HTTP\\Response"
          }
        ]
      },
      {
        "file": "\/var\/www\/nextcloud\/apps\/dav\/appinfo\/v1\/webdav.php",
        "line": 80,
        "function": "exec",
        "class": "Sabre\\DAV\\Server",
        "type": "->",
        "args": [

        ]
      },
      {
        "file": "\/var\/www\/nextcloud\/remote.php",
        "line": 163,
        "args": [
          "\/var\/www\/nextcloud\/apps\/dav\/appinfo\/v1\/webdav.php"
        ],
        "function": "require_once"
      }
    ],
    "File": "\/var\/www\/nextcloud\/apps\/dav\/lib\/Connector\/Sabre\/File.php",
    "Line": 228,
    "CustomMessage": "--"
  },
  "userAgent": "Mozilla\/5.0 (Android) Nextcloud-android\/3.9.0",
  "version": "17.0.1.1"
}
dfeyer commented 4 years ago

OK finaly for me that was a general upload (except from the desktop client where everthing works), caused by my data directory moved to an external drive, but the opcache directory point to the old links. Now upload from the web interface, mobile client and auto upload works nicely.

damago1 commented 3 years ago

I have the same on Redmi Note 6. SD card seem to be read only for Nextcloud. Autoupload fails with "failed to copy to local folder" and "local storage full" errors (both errors visible for the same file: one of those errors on notification, second on 'sent' list.

Autoupload seems to work ok for internal memory. But not for SD card.

Nexcloud android app excluded from battery optimization, set as autostart, excluded from every limmitation i could find. Android version 10.

Oclair commented 3 years ago

why are currently active bugs' issues closed?

ronnystandtke commented 3 years ago

Same issue here on a Fairphone 3 using Open Camera v1.48.3 to store all taken pictures onto the SD card (formatted as external drive). Instant upload doesn't work. Sometimes pictures are synced several days later. The main use case - take a picture on the phone and edit it some seconds later on the desktop - just doesn't work. I'm trying to convince family and friends to use Free Software on their mobile devices (Android, Nextcloud, ...) but if these simple use cases don't work this mission is doomed to fail...

ronnystandtke commented 3 years ago

Can someone please reopen this bug and disable the stale bot? Sometimes users and developers need more than a couple of weeks to coordinate and fix bugs...

tobiasKaminsky commented 3 years ago

Autoupload seems to work ok for internal memory. But not for SD card.

Can you try this? So that we can limit down the problem to sd card?

jorkzijlstra commented 3 years ago

I deleted my comment again. As it turned out I seem to have had the same issue mentioned in #8019 and the auto upload is now working for me.

MuhannadYT commented 3 years ago

Hello, same issue on huawei p30 pro. But there is a fix that you can implement. Basicly allowing users to select the files using the default Android file selector, as there you can give the app access to the SD card (by default I mean the one that has the sentence "open from" at the top) hope this helped

github-actions[bot] commented 3 years ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

framuc commented 3 years ago

[nobot] Please don't close but solve.

github-actions[bot] commented 3 years ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

dawnstrider commented 2 years ago

Solution for Samsung Galaxy S9(+):

Start the Nextcloud app and set the working folder to the base of the SD card. After that, AutoUpload worked on our S9 without any hickups.