1

Linux Mint 19.3 laptop copying a 400 MB file via MTP (in Caja) to an Android 7.0 tablet.

While it's copying, the file is visible in the stock Files app on the tablet, and I can keep hitting the refresh button on the tablet to see the file size grow in sync with the progress meter on the laptop.

As soon as it reaches 100%, it's still visible on the laptop, but disappears from the tablet upon the next refresh, never to be seen again. Even after unmounting and remounting, the tablet cannot see it, and the laptop still can. The laptop shows the proper file name, size, type, and location; however, it:

  • Shows "unknown" for "size on disk" and "accessed" in the Properties dialog
  • Shows a modified date of 31 Dec 1969
  • Gives an generic i/o error trying to open the file
  • Gives the error "Sorry, could not rename ...: libmtp error: could not set object string" if I try to rename it

I had heard that MTP support in Linux was pretty good nowadays. Before I try installing extra MTP packages and whatnot, am I missing something obvious?

1

MTP is very buggy protocol and should be completely avoided at all. What you see in File Explorer is only a snapshot of current files, you can't edit files in place. if you move folder to pc it is not unusual the transfer brakes but source folder is deleted on phone anyway

a safe way to transfer files is the adb shell

  • adb pull -a /sdcard will copy all files from Internal Storage to PC
  • adb push is the command for transfering files
2
  • Thanks for the helpful alternative. Why am I seeing this behaviour? Why do both Android and Linux pretend it's supported / show the file copying? (I can delete a folder from the PC side and that is reflected on the phone side, no problem, BTW...) – Kev Jan 11 at 8:11
  • 1
    MTP is designed for Windows Media Player to respect DRM. It never was a full file transfer protocol. The problems are the same across all OS (Windows/Linux/Android). I don't know why google decided to support MTP, most likely for compatibility reasons to FAT32 MicroSD Cards wikipedia.org/wiki/Media_Transfer_Protocol – alecxs Jan 11 at 8:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.