How To Connect an Android device using MTP in Ubuntu 14.04 LTS


This tutorial will help you to connect your android device in linux. You just need to follow the step wise information given below:

Firstly we have to install some of the common MTP applications that will be needed.

You will need to execute the following commands in your terminal.

sudo apt-get
install libmtp-common mtp-tools libmtp-dev libmtp-runtime libmtp9
sudo apt-get

Then we’re going to add the fuse.conf file. FUSE is an application that aims to provide a secure method for non privileged users to create and mount their own file system implementations. This option overrides the security measure restricting file access to the user mounting the file system. So all users (including root) can access the files.

You can execute the commands given below:

sudo vi

We want to remove the # from the below line of code for user_allow_other, like so…


#/etc/fuse.conf - Configuration file for
Filesystem in Userspace (FUSE)

#Set the maximum number of FUSE mounts allowed
to non-root users.
#The default is 1000.
#mount_max = 1000

# Allow non-root users to specify the
allow_other or allow_root mount options.

save the file and exit.


We now need to set up some rules for our device that we plan on connecting, but before we do that we need to find out both the vendor and product id

Connect your device via an available usb port and from terminal execute command


This should bring up an output similar to the following

Bus 002 Device 004: ID 17ef:7882 Lenovo 
Bus 002 Device 003: ID 1c4f:0048 SiGma Micro 
Bus 002 Device 002: ID 8087:0020 Intel Corp.
Integrated Rate Matching Hub 
Bus 002 Device 001: ID 1d6b:0002 Linux
Foundation 2.0 root hub 
Bus 001 Device 004: ID 0489:e00f Foxconn / Hon
Hai Foxconn T77H114 BCM2070 [Single-Chip Bluetooth 2.1 + EDR Adapter]
Bus 001 Device 003: ID 0c45:6464 Microdia 
Bus 001 Device 002: ID 8087:0020 Intel Corp.
Integrated Rate Matching Hub 
Bus 001 Device 001: ID 1d6b:0002 Linux
Foundation 2.0 root hub 

You need to look for your device, in this instance my Sony Tablet is at the top of the list, the vendor id is 0fce and product id is 01b1

We’re then going to add the mtp udev rules as follows, from a terminal type

sudo vi

Then add the below line of code

# Lenovo K3 note
SYMLINK+="libmtp-%k", ENV{ID_MTP_DEVICE}="1",

Remember what you’re changing here is the device name next to the #, this can be whatever you want, the # comments out the code, but for clarity and reference later I would choose the name of your tablet/phone and also the vendor id and product id, they should match what was seen when you issued the lsusb command earlier.

Once done, save the file.

The next step would also be to add a line of code to the 51 android rules file, again from a terminal execute

sudo vi

Then add the following line of code


Make sure to replace what I have highlighted by your device product id and vendor id.

Once that is done and the file is saved, remove any usb device currently connected and issue the following commands


Restart the service of udev by executing the command given below:

sudo service udev

Then save any other remaining work you may have open and reboot the system.


sudo reboot

Once rebooted you should now be able to plug your Android device in(making sure the screen is unlocked) .

Rajkishor Maharjan has written 17 articles