How to root Android device using ADB

How to do things, solutions, recipes, tutorials
Message
Author
User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#16 Post by don570 »

Nexus 7 tablet calls it's sync cable an OTG cable

http://www.amazon.com/s/ref=nb_sb_noss? ... =OTG+cable

I wonder if there is any real differences between the cables??

The website I refered to above said that most tablets now
use an OTG cable and here's how it's made ---> Grounding of two terminals

Image

________________________________________

Plume
Posts: 34
Joined: Mon 12 May 2008, 19:05

#17 Post by Plume »

I said previously that adb failed to detect my android device. This was from Puppy 5.2.5 (Lucid Puppy).
From Puppy 5.4.1, adb succeeds to detect my phone. This is obtained with a standard USB cable and with a pristine Puppy, so without java I guess. Fine!

However, /system is always mounted read-only.

Code: Select all

./adb shell /data/local/tmp/busybox mount -o remount,rw /system
says I can't do this because I'm not root (I'm root on Puppy but not on the phone).

Does somebody know how to deal with this on android 2.3.6? I suppose the problem is related to the android version rather than the hardware by itself.

Thank's

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#18 Post by don570 »

Does somebody know how to deal with this on android 2.3.6?
Yes the Android version is important!!

I checked if Java or the Jave development kit (JDK) is needed.

It looks like they aren't needed. Just installing adb application
was good enough.

By the way you should put adb in an executable path so you can
use just 'adb' in the terminal rather than './adb'

Here is the output of my terminal program

Code: Select all

# adb shell ls /mnt
asec
extsd
obb
sdcard
secure
usbhost1



# adb shell ls /
acct
cache
config
d
data
default.prop
dev
etc
init
init.goldfish.rc
init.rc
init.sun5i.rc
init.sun5i.usb.rc
initlogo.rle
mnt
oem
proc
root
sbin
sdcard
sys
system
ueventd.goldfish.rc
ueventd.rc
ueventd.sun5i.rc
vendor


 # adb shell ls /etc/
3g_dongle.cfg
NOTICE.html.gz
apns-conf.xml
audio_effects.conf
bluetooth
camera.cfg
camera_back.cfg
camera_dou.cfg
dbus.conf
dhcpcd
event-log-tags
fallback_fonts.xml
gps
gps.conf
hosts
init.goldfish.sh
media_profiles.xml
mkshrc
permissions
ppp
security
system_fonts.xml
usb_modeswitch.d
usb_modeswitch.sh
vold.fstab
wifi
 



User avatar
01micko
Posts: 8741
Joined: Sat 11 Oct 2008, 13:39
Location: qld
Contact:

#19 Post by 01micko »

Hi don570

A little OT (I did mangae to root my 'droid though :wink: )

There is a really cool app for accessing droids through any capable web browser. airdroid. Just requires your droid is on the same LAN. It works great in Puppy. Just be aware though that it is still in beta, some features hang, requiring a logout, login. Not a big deal.

Cheers
Puppy Linux Blog - contact me for access

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#20 Post by nooby »

Would this also work on a SonyEricson smartphone?
I don't have tablet only Smartphone and
what about a Huawei smartphone?

Could my android be too old though? I have not tested
B/C I am too afraid to brick them :)
I use Google Search on Puppy Forum
not an ideal solution though

Plume
Posts: 34
Joined: Mon 12 May 2008, 19:05

#21 Post by Plume »

@nooby
Airdroid works fine with my Huawei smartphone (Honour, Android 2.3.6).

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#22 Post by nooby »

Thanks plume
http://www.airdroid.com/

they say

Transfer files to and from your device via web browser.
Wireless operation via WiFi connection.

That would allow us to bring over a file that can root it then hopefully?
Looks promising indeed.
I use Google Search on Puppy Forum
not an ideal solution though

Plume
Posts: 34
Joined: Mon 12 May 2008, 19:05

#23 Post by Plume »

We can do a lot of things with Airdroid, such:
- look at our photos,
- listen to our music,
- look at our contacts or add new contacts,
- look at the call log,
- look at our messages or send new ones,
- browse the files on the smartphone, download them or upload other files from the PC.
But I'm not able to upload files in "System" and I'm afraid Airdroid can't help rooting the device if this was your idea.

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#24 Post by don570 »

I had my second nasty black screen incident with
my Android device. I now see why people complaing that
Android isn't as stable as Linux.

Cause: installing latest version of FBReader from external SDcard ???

Fix: remove external SD card . This allowed booting to proceed.

Then I went thru rooting procedure as described on first page.

I put back external SD card and everything is fine.

____________________________________________________

I discovered that Superuser.apk is confusing to use
because it is actually a commercial program. The writer
is trying to sell a different program named 'Elite'. This confuses
the interface greatly


http://androidsu.com/elite/




___________________________________________________________

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#25 Post by don570 »

Here are instructions to use the Superuser apk with ES File Explorer.

First launch 'ES File Explorer' and look under 'Settings'
Make sure 'Up to root' is ticked.

Image


Next launch Superuser app (It has an icon). Somehow??? it
knows that 'ES File Explorer' is installed and can be given root access.

Image

Note: screenshots were taken using this method


_______________________________________________________

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#26 Post by nooby »

Don thanks for that one and for the drawings of the OTG cable.
I use Google Search on Puppy Forum
not an ideal solution though

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#27 Post by don570 »

The newest version of ES File Explorer (es_file_explorer_v1.6.2.4.apk)
that came out before Christmas has fixed a bug with 'Root Explorer'.

Under 'Settings' there is 'Root Settings' which allows 'Root Explorer'
which works now for me. Android version 4.04

_____________________________________________________

esrom02
Posts: 8
Joined: Wed 01 Jun 2011, 02:45

Help?

#28 Post by esrom02 »

First of all sorry for replying in this old thread.

My problem is whenever I try to use adb command, It says permission denied? How can I fix it? Thank you.. And do I need particular drivers for my phone? so puppy will recognize my phone?

User avatar
Ted Dog
Posts: 3965
Joined: Wed 14 Sep 2005, 02:35
Location: Heart of Texas

#29 Post by Ted Dog »

thanks any other android package that do not requre google shop setup.

really need a flash player ...

esrom02
Posts: 8
Joined: Wed 01 Jun 2011, 02:45

Problem Fix !

#30 Post by esrom02 »

My bad for not making it executable..

Now my problem is whenever I push the files, it prints permission not permitted.

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#31 Post by don570 »

Note to teddog : 'adb' doesn't need JAVA or flash to be installed
to obtain the basic commands like 'push' and 'pull'.
I did have to install the JDK(Java Development Kit)
to take a screenshot of Android device.

Note to esrom2: Puppy linux always runs as the root user so
you should never get the message 'permission not permitted'

Some linux apps don't like to run by the root user, but adb isn't one of them.

I wonder if your phone manufacturer has found some way of blocking
adb commands?? Android devices have ways of blocking viruses.
So maybe your phone thinks it's being attacked by a virus.

All I can suggest is use the latest version of adb and cross your fingers.

Here's a tutorial on using adb that might be of use.
http://forum.xda-developers.com/showthr ... p=17123601

____________________________________________________

oldaolgeezer
Posts: 64
Joined: Sun 03 Dec 2006, 19:34

How to root Android device using ADB

#32 Post by oldaolgeezer »

A comment on my use of adb:

I have been using Puppy Linux 5.2.8 V4 successfully with adb on my first generation Kindle Fire tablet.

I have used Puppy and adb to flash various recovery partition programs and Android Gingerbread and Jellybean ROMs designed for the first generation Kindle Fire via an ordinary micro USB cable.

(I've learned from the forums on xda-developers.com that, there is a forum for many of the different models of phone and tablet hardware. There may be user developed flashable ROMs and/or installable apk programs for many of the specific models there too.)

As don570 reported above, some of these phones or tablets require the normally unused pin 4 of the micro USB cable end to be grounded (in the case of the OTG ("On the Go") cable), but some other brands or model phones or tablets sometimes need the unused pin 4 of the micro USB cable end to be connected to the +5 volt wire with a current limiting resistor (these micro USB cables are called a "Factory Cable").
The xda-developers.com has lists of what cable is required for a specific model phone or tablet with adb or what cable is required for even resurrecting a "brick"!

Also I wanted to thank 01micko for mentioning the useful Android apk: airdroid.
As a newbie in the world of Android, I have found the sheer number of available apps (even just ones with four or five star reviews) to be overwhelming.

For my simple needs, I haven't wanted to go through an endless cycle of installing, trying and then un-installing hundreds of apps.

Thanks again don570 and 01micko.

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#33 Post by don570 »

Here's an interesting video on how to make
an OTG cable with a female end rather than
the normal male plug.

This is useful with Android tablets.

http://www.youtube.com/watch?v=COkLEJGo6vo

To buy a new cable is not expensive but few stores have this special
cable in stock.
___________________________________________________
It's possible to attach keyboards and USB sticks to nexus7
and probably other tablets.


http://www.amazon.ca/Asuxtek%C2%AE-Nexu ... B008ZBGC5S

Here's a review..

1 of 1 people found the following review helpful
5.0 out of 5 stars OTG good ta go!
This little cable lives up to it's name. Works fine on a rooted Nexus 7 combined with stickmount app to add much needed USB storage to the tablet. You can't go wrong for $6.00 free shipping. You just have to wait two weeks for it to get here from Hong Kong.
This is same cable (I believe)

http://www.adafruit.com/products/1099
_______________________________________________





___________________________________________________

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#34 Post by don570 »

To play downloaded flash videos without installing Flash itself
I found the following player works on recent Android tablets.

BSP v1.5.136 [4.0+].apk


However I found that mp4 videos were out of sync with audio,
but Android's builtin video player can handle mp4 fine.

.

Dromeno
Posts: 534
Joined: Fri 12 Sep 2008, 07:01

How about doing a test run

#35 Post by Dromeno »

I do not have an android device so I do not know if this is useful, but I can imagine that you would like to be able to test the rooting procedure before you do it on an expensive phone.

Here are several android iso's whch can be installed on a computer (or even within puppy in a virtual box environment)

http://www.android-x86.org/

the only annoting part when you want to make a puppy/android multiboot system is that Grub4DOS does not recognize the android, so you will have to go back to Grub (ideas for workarounds are welcome)

Post Reply