Ubuntu – Mounting an MTP enabled device on Ubuntu 12.04.3 LTS 32-bit

32bitandroidmountmtpUbuntu

My aim is to perform file operations on my Samsung Galaxy Note 10.1 (older edition) using Ubuntu 12.04.3 LTS 32-bit. This does not work out of the box as I plugged my device and saw myself. In order to mount and have the device recognized by the OS I tried various tutorials on the net. I summarize them as follows:

Mounting your MTP Android’s SD Card on Ubuntu

http://www.mysolutions.it/mounting-your-mtp-androids-sd-card-on-ubuntu/?replytocom=5183#respond

I have done everything as described but when I run "mtp-detect" command the following output is generated:

mtp-detect
Unable to open ~/.mtpz-data for reading, MTPZ disabled.libmtp version: 1.1.6

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 3, dev 2
Attempting to connect device(s)
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
inep: usb_get_endpoint_status(): Invalid argument
outep: usb_get_endpoint_status(): Device or resource busy
usb_clear_halt() on IN endpoint: Device or resource busy
usb_clear_halt() on OUT endpoint: Device or resource busy
usb_clear_halt() on INTERRUPT endpoint: Device or resource busy
LIBMTP PANIC: failed to open session on second attempt
Unable to open raw device 0
OK.

Adding the GVFS-mtp PPA available on Launchpad

https://launchpad.net/~langdalepl/+archive/gvfs-mtp

This worked and initially it auto mounted the tablet upon plugging it in. However, I cannot perform file operations on the tablet such as opening a file (say pdf) residing inside the memory of the tablet, copying a file inside the memory of the tablet to another place in the memory of the tablet; the same goes for moving. This solution was described in this post: https://askubuntu.com/questions/87667/getting-mtp-enabled-devices-to-work-with-ubuntu/308366#308366

Using go-mtpfs

I tried this by following the instructions on the following website:
http://www.webupd8.org/2012/12/how-to-mount-android-40-ubuntu-go-mtpfs.html

The output of trying to mount the device is as follows:

go-mtpfs /media/MyAndroid/
2014/04/21 19:43:24 compiled against libmtp 1.1.5
Device 0 (VID=04e8 and PID=6860) is a Samsung Galaxy models (MTP).
2014/04/21 19:43:24 found device Samsung: Galaxy models (MTP) (04e8:6860) @ bus 3, dev 2
: 
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
inep: usb_get_endpoint_status(): Invalid argument
outep: usb_get_endpoint_status(): Device or resource busy
usb_clear_halt() on IN endpoint: Device or resource busy
usb_clear_halt() on OUT endpoint: Device or resource busy
usb_clear_halt() on INTERRUPT endpoint: Device or resource busy
LIBMTP PANIC: failed to open session on second attempt
2014/04/21 19:44:00 rdev.open failed: open: open returned nil

I also wonder if the screen lock really interferes with these sort of operations. Note that I got the above results without the screen lock active. I also added a screenshot from Nautilus showing that the device is detected upon linking but not mounted automatically. I suspect that some of these options may have caused some sort of clash and I would be very grateful if you can provide assistance on mounting my device properly and performing file operations both within the tablet, and between the tablet and the laptop.

Thanks in advance,

enter image description here

Best Answer

Try out this http://bernaerts.dyndns.org/linux/74-ubuntu/268-ubuntu-automount-any-mtp-device

This guide explains how to easily configure your Ubuntu computer to directly access your Android devices filesystem in MTP mode as soon as you plug it to a USB port. This guide has been completly rewritten to use mtp-detect. It has been tested with a Google Nexus 4 and a Google Nexus 7, but it should work with any other MTP device (Android phone or tablet, MP4 player, ...). It has been done under Ubuntu 12.04 LTS Amd64 but it should work or be easily adapted on many Linux flavours.

Related Question