Summary: | Trouble opening an MTP device | ||
---|---|---|---|
Product: | [Frameworks and Libraries] kio-extras | Reporter: | vytas <vytas.naus> |
Component: | MTP | Assignee: | Elvis Angelaccio <elvis.angelaccio> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | alain.guirauton, elvis.angelaccio, enrico.tagliavini, kfm-devel, mehanoid.ru, mte90net, said.fox, sitter, yourjunkhere14 |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
vytas
2019-12-16 11:56:16 UTC
I have another issues with connecting my computer operated by Kubuntu 18.04 to my Android device, Redmi Note7, while the process is not smooth. The file manager able to access files on the device, but trying to browse files using the open file dialog of any application such as web browsers e.g. Firefox, Vivaldi, etc. is not succeeded. I posted a question on Ask Ubuntu that describes the issue at the following URL: https://askubuntu.com/questions/1207350/could-not-able-to-find-android-device-photo-through-applications-open-file I've seen this problem with a Samsung S7. Possible related: https://bugs.kde.org/show_bug.cgi?id=411489 HI, I have the same problem with the message "Code d'erreur 150 inconnu Mauvais param�tres Veuillez envoyer un rapport de bogue détaillé à https://bugs.kde.org." OS : Mozilla/5.0 (X11; Linux 5.6.14-desktop-2.mga7 x86_64; French) KHTML/5.57.0 (like Gecko) Konqueror/5 KIO/5.57 Portable : SAMSUNG GALAXY Notes 5 Best regards? Here's a udevadm monitor during the opening. In the example, I plug/unplug the cable 2 times. The results are identical, yet the second one is working. Only thing I did was close Dolphin as per suggestion from elsewhere - sounds stupid, but it didn't work for atleast 50 tries before. What information should be gathered to scope in on this? udevadm monitor: KERNEL[157.249285] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) KERNEL[157.268534] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) KERNEL[157.268579] bind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) UDEV [157.272331] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) UDEV [157.273408] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) UDEV [157.274705] bind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) KERNEL[163.617649] unbind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) KERNEL[163.617690] remove /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) KERNEL[163.619585] unbind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) KERNEL[163.619617] remove /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) UDEV [163.620509] unbind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) UDEV [163.621156] remove /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) UDEV [163.621933] unbind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) UDEV [163.622359] remove /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) KERNEL[164.641550] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) KERNEL[164.660366] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) KERNEL[164.660404] bind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) UDEV [164.663582] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) UDEV [164.665348] add /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4/1-4:1.0 (usb) UDEV [164.666988] bind /devices/pci0000:00/0000:00:01.3/0000:03:00.0/usb1/1-4 (usb) mtp-detech shows the following: libmtp version: 1.1.16 Listing raw device(s) Device 0 (VID=04e8 and PID=6860) is a Samsung Galaxy models (MTP). Found 1 device(s): Samsung: Galaxy models (MTP) (04e8:6860) @ bus 1, dev 10 Attempting to connect device(s) error returned by libusb_claim_interface() = -6LIBMTP PANIC: Unable to initialize device Unable to open raw device 0 OK. When it wasn't working, the folliwng line was "Samsung: Galaxy models (MTP) (04e8:6860) @ bus 1, dev 7" instead of dev 10, even though neither port nor anything else changed. This looks like a problem possibly generated in the KIO module. Running mtp-detect: $ mtp-detect libmtp version: 1.1.16 Listing raw device(s) Device 0 (VID=2a70 and PID=f003) is a OnePlus OnePlus 2 A2005. Found 1 device(s): OnePlus: OnePlus 2 A2005 (2a70:f003) @ bus 1, dev 17 Attempting to connect device(s) error returned by libusb_claim_interface() = -6LIBMTP PANIC: Unable to initialize device Unable to open raw device 0 OK. Running the android file transfer utrility claims the device is already in use: # aft-mtp-mount $HOME/mtpfs/ Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process Device::Find failed:Device is already used by another process connect failed: no MTP device found stracing mtp-detect shows ioctl(3, USBDEVFS_CLAIMINTERFACE, 0x7ffd33ff178c) = -1 EBUSY (Device or resource busy) so it looks like the KDE kio module is locking the USB device and not releasing it at some point early right after the USB cable is connected killall kiod5, seems to help, after running it the MTP file system is accessible with any libmtp based software (e.g. mtp-detect, gvfs-mtp, jmtpfs and so on) except the KDE one. Trying to access the phone with a KIO based application causes the device to be locked again and kiod5 needs to be killed again to make it accessible. For anyone else stumbling upon this in an effort to find a workaround atleast, a thing that fixes it every time is, after confirming popup on the phone, close and reopen dolphin. (In reply to vytas from comment #6) > For anyone else stumbling upon this in an effort to find a workaround > atleast, a thing that fixes it every time is, after confirming popup on the > phone, close and reopen dolphin. Doesn't help me, still get the error, even if I kill the dolphin daemon in the background Do you have any other application that links to libmtp running? This library unfortunately only allows to be used by one client at a time. (In reply to Christoph Feck from comment #8) > Do you have any other application that links to libmtp running? This library > unfortunately only allows to be used by one client at a time. As I said I have to killall kiod5, which seems to be the one keeping the device busy. If I do that, I can then use other libmtp based tools, but not KDE based one. As soon as I try to access the phone with dolphin I get the error again. Ultimately this is a design limitation in libmtp I think. Not having multiplexing is like the ALSA days before pulse. Seems to be working for me now. There were a few updates since my last comment and probably some KDE libraries / frameworks was included too. For reference I'm running Fedora 32, Plasma 5.18.5 So can this ticket get closed? (In reply to Christoph Feck from comment #11) > So can this ticket get closed? It looks like the problem was solved for Fedora 32, so I think it can be close. Possibly wait a few days for the original reporter to give a feedback. Thank you. vytas, can you confirm the fix with recent versions? Dear Bug Submitter, This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging If you have already provided the requested information, please mark the bug as REPORTED so that the KDE team knows that the bug is ready to be confirmed. Thank you for helping us make KDE software even better for everyone! This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging Thank you for helping us make KDE software even better for everyone! I have this bug in Debian Sid with Plasma 5.22. I saw that I need to kill kiod5 manually and mount the device with jmtpfs manually. Otherwise dolphin as root or normal user will lag and doesn't work. When this happens mtp-detect write this: libmtp version: 1.1.17 Listing raw device(s) Device 0 (VID=2717 and PID=ff40) is a Xiaomi Mi-2s (id2) (MTP). Found 1 device(s): Xiaomi: Mi-2s (id2) (MTP) (2717:ff40) @ bus 3, dev 19 Attempting to connect device(s) error returned by libusb_claim_interface() = -6LIBMTP PANIC: Unable to initialize device Unable to open raw device 0 OK. Dolphin should now correctly show devices, so long as the device can actually be opened, which as mentioned isn't always the case if you use multiple different apps because MTP does not do multiplexing. |