Sunday, February 3, 2013

TUTORIAL : Galaxy Nexus Enable MTP File Transfer in Ubuntu Linux

 Many people have struggle to connect android phone to Ubuntu for file transfer. I've found it over the net and it's work like charm. Kudos to Lou from http://ohheyitslou.blogspot.com/




The packages for MTP in the Ubuntu 11.10 repos are built from outdated source and are the cause of most of the MTP file transfer woes. I've gone ahead and removed the updated packages from the Ubuntu 12.04 repos both 32 & 64 bit versions. These have to be installed in a certain order to avoid issues so install as follows:


sudo dpkg -i libmtp9_1.1.1-1_amd64.deb
sudo dpkg -i libmtp-common_1.1.1-1_all.deb
sudo dpkg -i libmtp-runtime_1.1.1-1_amd64.deb
sudo dpkg -i mtp-tools_1.1.1-1_amd64.deb

Final package that needs to be install:

sudo apt-get install -y mtpfs

*After install make sure that the following packages are installed 
mtp-tools libmtp-runtime libmtp9 libmtp-common mtpfs

  • First we must create a mount point for your Galaxy Nexus:
sudo mkdir /media/Nexus
  • Now we must assign the proper read/write privileges to the directory:
sudo chmod 775 /media/Nexus
  • We have to create a file the enables your Linux system to see your Galaxy Nexus:
sudo gedit /etc/udev/rules.d/99-android.rules
  • Copy & Paste the following into the file then save and close:
#Acer
SUBSYSTEM=="usb", SYSFS{idVendor}=="0502", MODE="0666"
#Dell
SUBSYSTEM=="usb", SYSFS{idVendor}=="413c", MODE="0666"
#Foxconn
SUBSYSTEM=="usb", SYSFS{idVendor}=="0489", MODE="0666"
#Garmin-Asus
SUBSYSTEM=="usb", SYSFS{idVendor}=="091E", MODE="0666"
#Google
SUBSYSTEM=="usb", SYSFS{idVendor}=="18d1", MODE="0666"
#HTC
SUBSYSTEM=="usb", SYSFS{idVendor}=="0bb4", MODE="0666"
#Huawei
SUBSYSTEM=="usb", SYSFS{idVendor}=="12d1", MODE="0666"
#Kyocera
SUBSYSTEM=="usb", SYSFS{idVendor}=="0482", MODE="0666"
#LG
SUBSYSTEM=="usb", SYSFS{idVendor}=="1004", MODE="0666"
#Motorola
SUBSYSTEM=="usb", SYSFS{idVendor}=="22b8", MODE="0666"
#Nvidia
SUBSYSTEM=="usb", SYSFS{idVendor}=="0955", MODE="0666"
#Pantech
SUBSYSTEM=="usb", SYSFS{idVendor}=="10A9", MODE="0666"
#Samsung
SUBSYSTEM=="usb", SYSFS{idVendor}=="04e8", MODE="0666"
#Sharp
SUBSYSTEM=="usb", SYSFS{idVendor}=="04dd", MODE="0666"
#Sony Ericsson
SUBSYSTEM=="usb", SYSFS{idVendor}=="0fce", MODE="0666"
#ZTE
SUBSYSTEM=="usb", SYSFS{idVendor}=="19D2", MODE="0666"

  • Now we must make the file executable:
sudo chmod +x /etc/udev/rules.d/99-android.rules
  • Download and unzip the mount/unmount scripts I've written for you in your home directory:
  • Make the scripts executable:
sudo chmod +x mount-nexus.sh unmount-nexus.sh
  • Enable MTP transfer on your Galaxy Nexus by entering into Settings-Device-Storage select Menu in the bottom right hand corner then "USB computer connection" make sure "Media device (MTP)" is selected.
  • Connect the Galaxy Nexus to your computer:  *USB Debugging must be disabled*
  • With the mount and unmount scripts in your home directory execute the mount command by typing the following (please wait for a while, it take time to load files from android) :
./mount-nexus.sh
  • Execute (IS A MUST) the unmount command by typing the following:
./unmount-nexus.sh 


 




Tags : TUTORIAL : Galaxy Nexus Enable MTP File Transfer in Ubuntu Linux mtpfs mtp-tools libmtp-runtime libmtp9 libmtp-common mtpfs ./mount-nexus.sh ./unmount-nexus.sh, 

1 comment:

  1. I really loved reading your blog. It is very well authored and easy to undertand. Unlike so many other blogs I have read which are really not that good. I also found your posts very interesting. In fact, after reading, I shared it with my friends and everyone liked it!
    Mobile auto scratch repair

    ReplyDelete

Expand storage for Openwrt router

If he router has very low storage, in my case router is DIR-842. Here is tutorial to expend storage using USB flash drive.  Original guide i...