15

I have installed mtp-tools on my debian7.8.
mtp-files can list all my files on android phone.
How can I mount all my files on android phone on the directory /tmp/myphone?

root@debian:/home/debian# jmtpfs -l
Device 0 (VID=0b05 and PID=0c02) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team Available devices (busLocation, devNum, productId, vendorId, product, vendor): 1, 8, 0x0c02, 0x0b05, UNKNOWN, UNKNOWN
root@debian:/home/debian# jmtpfs /tmp/myphone
Device 0 (VID=0b05 and PID=0c02) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team ignoring usb_claim_interface = -6ignoring usb_claim_interface = -5PTP_ERROR_IO: failed to open session, trying again after resetting USB interface LIBMTP libusb: Attempt to reset device
Android device detected, assigning default bug flags
fuse: bad mount point `/tmp/myphone': Input/output error

The jmptfs can't mount my phone.

chmod 777  /tmp/myphone 

After chmod.

root@debian:/home/debian# jmtpfs /tmp/myphone
Device 0 (VID=0b05 and PID=0c02) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Android device detected, assigning default bug flags
root@debian:/home/debian# jmtpfs -l
Device 0 (VID=0b05 and PID=0c02) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Available devices (busLocation, devNum, productId, vendorId, product, vendor):
1, 5, 0x0c02, 0x0b05, UNKNOWN, UNKNOWN

1
  • fuse: bad mount point '/tmp/myphone': Input/output error I think that's the issue here. Is the directory created and writable? Can you try mounting it as a regular user instead? Mar 3, 2015 at 11:22

1 Answer 1

17

Install jmtpfs (aptitude install jmtpfs) which allows to mount MTP devices.

Create the directory if it doesn't exist already (mkdir /tmp/myphone). Then, the following will mount your phone:

jmtpfs /tmp/myphone

jmtpfs will use the first available device. If you've got more than one connected at a time, you can do jmtpfs -l to find out which one is your phone, and use the -device flag to specify it.

As an alternative, you can try go-mtpfs instead.

4
  • 1
    More details on jmtpfs at github.com/JasonFerrara/jmtpfs
    – Brij
    Jul 21, 2018 at 16:42
  • 1
    Note that jmtpfs . (mount into the current directory) does not work, but jmtpfs $(mktemp -dt phone.XXXXXX) (mount into a new temporary directory) does. Sep 27, 2018 at 16:18
  • Still working in Ubuntu 22.04, this allows to transparently use commands such as rsync.
    – user171780
    Jul 7, 2023 at 19:11
  • This didn't work with my MTP device. I get this error libusb_claim_interface() reports device is busy, likely in use by GVFS or KDE MTP device handling alreadyLIBMTP PANIC: Unable to initialize device terminate called after throwing an instance of 'MtpErrorCantOpenDevice' what(): Can't open device [1] 121957 IOT instruction (core dumped) jmtpfs /tmp/myphone I'm on Ubuntu 22.
    – Raleigh L.
    Jul 11, 2023 at 3:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .