New: XDA launches forum for app developers. Discuss coding, tools, marketing, and more.
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
gnexus47
Old
#1  
Junior Member - OP
Thanks Meter 0
Posts: 6
Join Date: Mar 2012
Location: Seini
Exclamation ADB Shell not working, but my N1 isn't bricked

I wanted to use USB Tunnel to share my PC's internet connection with the phone, but I got the error:
Code:
- exec '/system/bin/sh' failed: No such file or directory (2) -
I tried to install other APK's through ADB and they also failed, so I googled this error and I saw that the main issue is a failing ADB Shell. I tried to open Shell and I got the same error. The difference between me and the other users is that my phone is booting as usual, USB Mass Storage works, the phone is detected by fastboot- and adb devices commands and everything is working as intended, except for installing APKs through ADB/opening Shell.

Here is my phone's current config:
MeDroidMod 1.4.4 w/ HWA
Latest Tiamat kernel
TexasICE HBOOT w/ 210/8/218 partition layout
4GB microSD card...I don't know the filesystem but it's definitely NOT ext4, so there's not A2SD for me (I think it's FAT or FAT32)
ClockWorkMod Recovery
 
taodan
Old
#2  
taodan's Avatar
Senior Member
Thanks Meter 156
Posts: 737
Join Date: Nov 2011
Quote:
Originally Posted by gnexus47 View Post
I wanted to use USB Tunnel to share my PC's internet connection with the phone, but I got the error:
Code:
- exec '/system/bin/sh' failed: No such file or directory (2) -
I tried to install other APK's through ADB and they also failed, so I googled this error and I saw that the main issue is a failing ADB Shell. I tried to open Shell and I got the same error. The difference between me and the other users is that my phone is booting as usual, USB Mass Storage works, the phone is detected by fastboot- and adb devices commands and everything is working as intended, except for installing APKs through ADB/opening Shell.

Here is my phone's current config:
MeDroidMod 1.4.4 w/ HWA
Latest Tiamat kernel
TexasICE HBOOT w/ 210/8/218 partition layout
4GB microSD card...I don't know the filesystem but it's definitely NOT ext4, so there's not A2SD for me (I think it's FAT or FAT32)
ClockWorkMod Recovery
Which adb commands did you use? Can you list the commands here that you had used? It could be that you didn't issue su command to get superuser rights?
If you want to say thanks, it is easier to hit the button below

~!~ Nexus One ~!~
  • HBOOT: Latest Blackrose S-off
  • Recovery: Amon_RA v2.21
  • ROM: ICS AOKP Milestone 5
  • Kernel: Tiamat & Shaky156 ICS 03142012
  • SD Card: 16GB
~!~ Acer Iconia A500 ~!~
  • Recovery: CWM rev1.7 by Thor2002ro
  • ROM: CM10 JellyTime 4.1.2
  • Kernel: 2.6.39.4+
  • SD Card: 8GB
 
rugmankc
Old
#3  
rugmankc's Avatar
Senior Member
Thanks Meter 815
Posts: 4,943
Join Date: Jun 2010
Location: Dayton, Ohio
you don't need to be in Shell to push apk

put the apk on your C: drive
open command window and navigate to the folder you have adb/fastboot in--normally tools of your sdk

then:


type adb devices--then

1. adb remount
2. adb push C:/CalendarGoogle.apk /system/app/CalendarGoogle.apk
3. adb push C:/CalendarProvider.apk /system/app/CalendarProvider.apk
4. adb shell
7. chmod 777 system/app/CalendarGoogle.apk
11. chmod 777 system/app/CalendarProvider.apk
12. exit
13. Reboot

use the apk name of whatever you are flashing in place of mine and your chmod may not be exactly like mine--
ATT Samsung Galaxy S4/Rooted/TWRP/Stock
Long Time MultiRom Flasher and Still Hope to Be
Phones Owned: Nokia 6200; Nokia 6126 2ea; BB 8700g; BB 8900; Nexus One-Rooted, HTC One S rooted, Samsung Galaxy S4 rooted; Carrier AT&T--





 
gnexus47
Old
#4  
Junior Member - OP
Thanks Meter 0
Posts: 6
Join Date: Mar 2012
Location: Seini
Default ADB Shell

Quote:
Originally Posted by rugmankc View Post
you don't need to be in Shell to push apk

put the apk on your C: drive
open command window and navigate to the folder you have adb/fastboot in--normally tools of your sdk

then:


type adb devices--then

1. adb remount
2. adb push C:/CalendarGoogle.apk /system/app/CalendarGoogle.apk
3. adb push C:/CalendarProvider.apk /system/app/CalendarProvider.apk
4. adb shell
7. chmod 777 system/app/CalendarGoogle.apk
11. chmod 777 system/app/CalendarProvider.apk
12. exit
13. Reboot

use the apk name of whatever you are flashing in place of mine and your chmod may not be exactly like mine--
I don't use ADB Shell to push APK's. That's just another thing which doesn't work.

@taodan: I only use: adb install xxxxx.apk.
 
evilkorn
Old
#5  
Senior Member
Thanks Meter 29
Posts: 1,752
Join Date: Jun 2009
Location: Boynton Beach, FL
A work around is to mount the sdcard and drag and drop the apks to the sdcard. Then install using your favorite file manager.
 
rugmankc
Old
(Last edited by rugmankc; 26th March 2012 at 12:58 AM.)
#6  
rugmankc's Avatar
Senior Member
Thanks Meter 815
Posts: 4,943
Join Date: Jun 2010
Location: Dayton, Ohio
Quote:
Originally Posted by evilkorn View Post
A work around is to mount the sdcard and drag and drop the apks to the sdcard. Then install using your favorite file manager.
that will work too, i've used root explorer to copy paste from sdcard to correct file location. prefer adb. set your permissions after

did you try adb remount first, not sure if that would help



what i was saying is you don't need to type adb shell. assuming you are doing this from a pc command terminal window.

you can use the commands I gave above to push apk. i think when you push it copies apk to phone leaving apk on pc also. install actually moves it to phone--as i understand it


here is some links and info that might help.*


http://www.talkandroid.com/guides/be.../#.T2-cdaJST3U

http://www.brighthub.com/mobile/goog...les/37151.aspx


also, have you ever had luck installing/pushing apk's. you may not have the correct environmental path on pc or are typing incorrect path in your command line

you can google environmental path editing for android and get examples of how to do it--i am not even sure mine is set right since I still have to type the full path in command window to use adb


sorry if this is old news just trying to find your problem
ATT Samsung Galaxy S4/Rooted/TWRP/Stock
Long Time MultiRom Flasher and Still Hope to Be
Phones Owned: Nokia 6200; Nokia 6126 2ea; BB 8700g; BB 8900; Nexus One-Rooted, HTC One S rooted, Samsung Galaxy S4 rooted; Carrier AT&T--






XDA PORTAL POSTS

Pearl Chen to Talk NFC Development at XDA:DevCon 2013

From HTML to LEDs or Android to Arduino, Hardware Hacking is a pastime of many people … more

Avoid Framework Bootloops on Xperias Running Jelly Bean

If you’re a Sony device owner running a stock Android Jelly Bean firmware and … more

Forum Added for the Samsung Galaxy Mega

What do you do when the Galaxy Note line is simply not big enough? You get theSamsung Galaxy Mega. … more

Voice Control Your Phone with Tasker and AutoVoice – XDA Developer TV

XDA Developer TV Producer Kevin set up his phone to respond to … more