Tell me more ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

This question already has an answer here:

Please help me troubleshoot. I would like to transfer files between my Ubuntu 12.04 and Nexus 7 (Android 4.2) I have first followed this link post carefully without success, rolled back all changed. The tried this other one simpler one link.

Nevertheless, upon:

mount /mnt/nexus7

I get:

Listing raw device(s) Device 0 (VID=18d1 and PID=4e41) is a Google Inc
(for Asus) Nexus 7 (mode 1).    

Found 1 device(s):    Google Inc (for
Asus): Nexus 7 (mode 1) (18d1:4e41) @ bus 1, dev 11 

Attempting to connect device Android device detected, assigning default bug flags

Listing File Information on Device with name: (NULL)

and even doing an ls -l /mnt generates:

ls: cannot access nexus7: Transport endpoint is not connected

total 4

d?????????? ? ?    ?       ?            ? nexus7

Ideas why that is happening???

share|improve this question
you could just use adb(many posts about it) OR use airdroid app + usb tethering for network – tarunchhn Apr 10 at 11:11

marked as duplicate by Mitch, Eliah Kagan, maggotbrain, Eric Carvalho, Luis Alvarado Apr 13 at 11:11

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

9 Answers

up vote 2 down vote accepted
+50

It's not worth it. Use something like SSHDriod and then connect over ssh. There are also FTP servers and even Driod NAS that gives cifs access. MTP does not work well, and likely will continue to not work well for the near future.

If you really want to get mtp working then make sure you set your Nexus to NEVER lock the screen or power off the screen. Locking the screen with "lock" the MTP protocal as well, causing all manor of data loss and connection issues. Powering off the screen in the stock kernel (might even be hardware) will turn the CPU down as much as it can and enable tons of other strong power saving features, that will result in horrid (but still working) transfers.

share|improve this answer

MTP is a Microsoft technology and is not officially supported on Linux. I've tried Mtp-Tools many times too, without success. If you consider an alternate method though, I've two recommendations:

share|improve this answer
I was able to connect it to my work computer mtpfs, but not at home. Could you help me troubleshoot it? – Pomario Nov 22 '12 at 20:26

If your computer and Nexus are on the same wifi network, you can use an app called AirDroid. It's free

https://play.google.com/store/apps/details?id=com.sand.airdroid&feature=nav_result#?t=W251bGwsMSwxLDMsImNvbS5zYW5kLmFpcmRyb2lkIl0.

  1. Open app on device.

  2. Go to web.airdroid.com on computer web browser.

  3. Enter passcode generated on device into the web app.

  4. Automatically connects. You can transfer files, view contacts and many other things. It's great. I use it all the time.

I hope this helps.

share|improve this answer

This post is similar to the first one you linked, but the steps are a bit different. It might help to give it a try.

The steps are summarized below for convenience.

Disclaimer

I have not personally tried the following steps. I cannot guarantee their safety or usefulness. Use at your own risk.

Mounting

  1. Install the relevant packages:

    sudo apt-get install mtp-tools mtpfs
    
  2. Create a new udev rule using the following command (requires password):

    gksu gedit /etc/udev/rules.d/51-android.rules
    
  3. Here we will deviate from the posted steps a little based on a comment from the linked post. In a terminal, run lsusb with your Nexus 7 connected via USB. You should see output like the following:

    Bus 001 Device 010: ID 18d1:4e41 Google Inc.
    

    Keep the two colon-separated values after the ID part in mind for the next step. They are what you should set ATTR{idVendor} and ATTR{idProduct} to, respectively.

  4. Type the following text into the file, all in a single line (numerical values used are those from the original posted steps):

    SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", ATTR{idProduct}=="6860", MODE="0666", OWNER="your-username-in-ubuntu"
    

    As an example, using my username and the values from the comment, the line I would enter would be:

    SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e41", MODE="0666", OWNER="christopher"
    
  5. Create a mount point for your Nexus 7:

    sudo service udev restart
    sudo mkdir /media/Nexus7
    sudo chmod a+rwx /media/Nexus7
    
  6. If your Nexus 7 is not already plugged in, do so now. Then run the following command on Ubuntu in order to access it:

    sudo mtpfs -o allow_other /media/Nexus7
    

    This should allow you to use Nautilus in order to browse your Nexus 7 and transfer files.

Unmounting

When you are finished with whatever you are transferring, run the following command to unmount your Nexus 7 before unplugging it:

sudo umount mtpfs

And in case that didn't work...

...you can take a look at a supposedly more reliable way to connect here.

share|improve this answer

I would recommend 'Go-mtpfs'. There are 2 way of use this program that i should explain.

First install the program using the folowing commands:

sudo add-apt-repository ppa:webupd8team/unstable
sudo apt-get update
sudo apt-get install go-mtpfs

Using the terminal

If u want to use the program using the terminal or if u simply hate unity.

  1. Mount You mtp device
    For mounting your device probably do the following command.

    go-mtpfs /media/MyAndroid

    leave your terminal open so long you use your device.

  2. For unmounting your mtp device
    Close the terminal or do ctr+c for terminate the program.
    fusermount -u /media/MyAndroid

Using the custom Unity Launcher

  1. First install the launcher:

    sudo apt-get install go-mtpfs-unity

  2. Press the ubuntu button on the unity launcher. Search for "Mount Android Device". And drag the icon to the unity bar.

  3. Than simply right-click the icon and you should get this. enter image description here

Enjoy your android device that now works perfectly on ubuntu :D.

source

share|improve this answer
Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. – RolandiXor Apr 10 at 16:15
Oke i will try to make my answer better. – Thomas15v Apr 10 at 16:28

I followed the steps mentioned on the post u link, and worked fine for me, but i mounted using sudo command before the mount.. another thing i pluged the device before doing all the steps. and now is working fine.. Also check that ur device have enable the option USB computer connection, there i selected Media device (MTP). That's all i have done.. hope u can make it work soon. Regards

share|improve this answer
1  
thank you for your comment, but it did not provide any help in troubleshooting the issue – Pomario Nov 20 '12 at 19:51

Try using gmtp instead of mtpfs.

gmtp provides a friendly UI and I have used it reliably for years.

http://gmtp.sourceforge.net/

share|improve this answer

Got it working with my Nexus 4 by installing the newest version of libmtp from launchpad. The version for Raring Ringtail works fine on my 12.04 system. The instructions stay the same as in your tutorial.

Edit: Although it works, it's painfully slow... I'm right now copying with 7 kb/s

Edit2: Nvm, it got up to 350 kb/s, which is acceptable I presume.

share|improve this answer

Is your Android device password protected and locked? I found I was getting the error:

Transport endpoint is not connected

because I hadn't entered the password. Once I authenticated on the device, I could connect.

Makes complete sense when you think about it. You shouldn't be able to just grab a device you don't have a password for and connect to it via computer.

share|improve this answer

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