[Q] ADB Command Execution problem - Android Q&A, Help & Troubleshooting

I have my phone connected to my laptop via the USB cable and the ADB is able to identify the device. When i run adb devices it returns the phone in the list of connected devices. Running the command adb shell now gives an error stating:
reloc_library cannot locate 'fdatasync'
Infact running any command on the terminal emulator installed on my phone also returns me the same error.
Has anyone faced the same problem or has any pointers to a solution to it?

Please use the Q&A Forum for questions &
Read the Forum Rules Ref Posting
Moving to Q&A

anuj142003 said:
I have my phone connected to my laptop via the USB cable and the ADB is able to identify the device. When i run adb devices it returns the phone in the list of connected devices. Running the command adb shell now gives an error stating:
reloc_library cannot locate 'fdatasync'
Infact running any command on the terminal emulator installed on my phone also returns me the same error.
Has anyone faced the same problem or has any pointers to a solution to it?
Click to expand...
Click to collapse
Do you have busybox installed? It seems as if the /bin directory doesnt exist or contain the proper files. Thats about all i got as of now

I have not been able to install busybox on my system. I have tried all possible versions and all possible ways of getting it installed but nothing works.

whats meant by "nothing works"? in fact you clearly installed something on your phone so it cannot start a shell anymore, did you reboot after you played around?

I have not been able to install busybox on my system. I have tried all possible versions and all possible ways of getting it installed but nothing works.
Click to expand...
Click to collapse
Well that is more than likely the issue, are you rooted? And you've tried the busybox installer from the market?
Sent from my GT-I9100 using Tapatalk

When i say "nothing works" what i mean is i have tried various busybox installers on the market and none of them seemed to work. Everytime i get the error stating that BusyBox could not be installed.
I have tried rebooting multiple times as well.

elesbb said:
Well that is more than likely the issue, are you rooted? And you've tried the busybox installer from the market?
Sent from my GT-I9100 using Tapatalk
Click to expand...
Click to collapse
Yes, my phone is rooted and yes i have tried the busybox installers from the market.

Related

SU request issue, help please

ok so on most roms this happens. i need a SU request but my phone freezes obn a black screen and on the top in gray it says SU request. i wait paciently and maybe 1-2 mins later is asks to FC because its not responding. is there a fix or what am i doing wrong. usb debugging is on and so is install nonmarket apps idk wtf im doing wrong or if somthing is just not working. any input??
I've heard su is not working properly until you activate it once via adb. In your teriminal (cmd or similar)
Code:
adb shell
$su
You should get a working super user request after which all other su requests should work fine.
Marisa said:
I've heard su is not working properly until you activate it once via adb. In your teriminal (cmd or similar)
Code:
adb shell
$su
You should get a working super user request after which all other su requests should work fine.
Click to expand...
Click to collapse
yes same thing happens to me
plug in your phone
goto your android sdk tools
and input adb shell
now go back to your phone and try it while still plugged
thats what i have been doing...
the same thing is happening for me and the instructions of simply input adb shell into terminal arent helping really. if someone could tell me exactly where to be aiming the command prompt and what the exact commands are in order to fix this I would greatly appreciate it.
WalkingTaco said:
the same thing is happening for me and the instructions of simply input adb shell into terminal arent helping really. if someone could tell me exactly where to be aiming the command prompt and what the exact commands are in order to fix this I would greatly appreciate it.
Click to expand...
Click to collapse
Are you getting the same crshes and things, but when you do the adb shell # pops up instead of $?
whenever i do adb shell I get #, so that means SU is already activated, but it's actually not on my phone, so i have no idea what's going on and no one seems to know how to fix it.
no. my Su permissions always force close after a minute of black screen. there is a fix posted above but my nerd level is not high enough to.infer the rest
Sent from my Eris using the XDA mobile application powered by Tapatalk
I don't know the exact command prompt setup, I'm running linux. However, when you originally rooted your phone you used the Android SDK correct?
With your phone plugged in, and USB Debugging enabled on your phone (Settings -> Applications -> Development -> USB Debugging) Open command prompt and get to the tools directory you used during rooting, I don't know where you installed it, so I cannot guide you through that part. If you used Ivan's guide http://forum.xda-developers.com/showthread.php?t=647707 it's probably best to refresh yourself there.
Once you've found your SDK /tools/ in command prompt, it should be as easy as running the code I mentioned earlier
Code:
adb shell
$su
in the command prompt.
The superuser prompt should show up on your phone, tell it to allow it and it should work without fail until you flash a new ROM that has the bug.
thanks very much. I used Ivans guide. I rooted it yesterday when o got my replacement from Verizon in store. I had been using the 2.1 leak on my old one and complained in store for thirty seconds. they didn't even look at it gave me a replacement in ten minutes
Sent from my Eris using the XDA mobile application powered by Tapatalk
Rock out thanks for the Super Help

[Q] ADB issues.

So I can't get adb to work and I'm about fed up. So here is what I've done. Could someone please tell me if I've gone wrong somewhere or what I'm missing because I'm sure it can't be that difficult.
I have an Atrix 4g that's rooted and running Adeo 0.1.7. Had zero issues doing either of those two things. Also I'm running Vista 64bit.
I've tried this in both normal and as administrator.
When I tried to push a file or list devices I get this. "daemon still not runningerror: Cannot connect to daemon"
When I tried adb shell su. I got permission denied.
I uninstalled sdk and reinstalled and now when I try to push I get "Not found." The other two are still the same problems.
I also added adb to the enviroment variables.
I used VanillaTbone's adb for dummies app. Which installs all the drivers for you automatically. So I don't believe there is an issue there. I've read all the threads I could find, but any issues I've seen have to do with rooting an HTC and the solutions I've seen are ones that I can't do on this phone. So I'm at a loss and my eyes are about to burst into flames from all this reading. Any help would be greatly appreciated!
I had a similar issue and it was fixed when I went into root explored and changed to r/w. Hope your fix is this easy...
Sent from my MB860 using XDA App
VicFerrari said:
So I can't get adb to work and I'm about fed up. So here is what I've done. Could someone please tell me if I've gone wrong somewhere or what I'm missing because I'm sure it can't be that difficult.
I have an Atrix 4g that's rooted and running Adeo 0.1.7. Had zero issues doing either of those two things. Also I'm running Vista 64bit.
I've tried this in both normal and as administrator.
When I tried to push a file or list devices I get this. "daemon still not runningerror: Cannot connect to daemon"
When I tried adb shell su. I got permission denied.
I uninstalled sdk and reinstalled and now when I try to push I get "Not found." The other two are still the same problems.
I also added adb to the enviroment variables.
I used VanillaTbone's adb for dummies app. Which installs all the drivers for you automatically. So I don't believe there is an issue there. I've read all the threads I could find, but any issues I've seen have to do with rooting an HTC and the solutions I've seen are ones that I can't do on this phone. So I'm at a loss and my eyes are about to burst into flames from all this reading. Any help would be greatly appreciated!
Click to expand...
Click to collapse
Are you using Mac, Windows or Linux?
Sebring5 said:
Are you using Mac, Windows or Linux?
Click to expand...
Click to collapse
Windows vista 64

Can't Access Files In ADB

Hi all,
I'm rooted and running Cyanogenmod 10.2.0. I'm trying to access some files on my device through ADB that require root access. I can change to the directory but when I attempt to list the contents of the directory I get a "permission denied" error.
I did enable Root access for "Apps and ADB" in the developer options on the phone.
Any ideas what's going wrong or (most likely) what I'm doing wrong?
TIA!
Sailing_Nut said:
Hi all,
I'm rooted and running Cyanogenmod 10.2.0. I'm trying to access some files on my device through ADB that require root access. I can change to the directory but when I attempt to list the contents of the directory
Click to expand...
Click to collapse
Will you please provide which command did you execute in cmd?
Please write it in same syntax as in adb
Sent from my GT-S5360 Gadget of Mass Destruction using xda-app
Using CWM........Busybox Commands........No I use my hands
Here are the commands I executed
Code:
adb shell
CD data/data/com.whatabou.pixeldungeon/files/
ls
The ls is where I get the error. It does change to the directory but it won't list the files. I have verified that I can see the files with root explorer.
Sailing_Nut said:
Here are the commands I executed
Code:
adb shell
CD data/data/com.whatabou.pixeldungeon/files/
ls
The ls is where I get the error. It does change to the directory but it won't list the files. I have verified that I can see the files with root explorer.
Click to expand...
Click to collapse
I have 2 answers. First - Go to adb
Code:
adb start-server
adb devices
adb shell
su
cd data/data/com.whatabou.pixeldungeon/files/
ls
Don't forget "su" command
When you give "su" command (depending on your phone) screen shows toast message or Superuser access for shell. In latter case give access.
Second- if above doesn't help
Then this will help to pinpoint problem.
Install terminal emulator from Play Store. Open and give Superuser access.
Code:
su
cd data/ /data/com.whatabou.pixeldungeon/files/
ls
Don't forget "su" command.
If 2nd method works then there is a problem with adb. If second method doesn't work then problem in phone.
Press thanks if helped
Sent from my GT-S5360 Gadget of Mass Destruction using xda-app
Using CWM........Busybox Commands........No I use my hands
Thanks for the response.
I KNOW the problem was that I forgot the su. Stupid me! I was assuming that since I was rooted that the shell was automatically elevated.
But now I have a different problem. I'm unable to use the original PC that I was working with and I've switched to another. Now I can't seem to get ADB to connect to my device. As first it showed no devices when I did the devices command. I realized it was likley because I didn't have the Samsung drivers installed, so I installed those and now I see the phone but it shows offline.
Any ideas what might be going wrong now?
I'm going to do a bunch of Googling to try to figure it out, but if I'm not successful maybe someone here will have an answer.
Thanks tons!
OK all solved!
I'm not sure what along the way I did that fixed my device offline problem. (It may just be that I never saw the RSA fingerprint notification on the phone the first bunch of times.)
The su took care of not being able to see the files when executing ls.
Thanks @hnkotnis
Sailing_Nut said:
OK all solved!
I'm not sure what along the way I did that fixed my device offline problem. (It may just be that I never saw the RSA fingerprint notification on the phone the first bunch of times.)
The su took care of not being able to see the files when executing ls.
Thanks @hnkotnis
Click to expand...
Click to collapse
Glad to help you.
I also had the adb saying offline problem. First it wouldn't show device. Then after Computer and phone reboot, it showed offline. I reinstalled Samsung adb drivers. It said I already have drivers. I said yes still install and rebooted. Problem solved. It occurred once again, but was repaired automatically.
Sent from my GT-S5360 Gadget of Mass Destruction using xda-app
Using CWM........Busybox Commands........No I use my hands

Can anyone help me on understanding ADB commands?

Hey all I hope I'm not in the wrong section and I tried searching for an already similar if not identical thread but couldn't find one(probably not looking too hard) but I have a rooted LG G2 and I have ADB up and running but I don't know the commands I'm assuming. I type "ADB shell" and it connects and finds device but the only command that works for me is "reboot system". I've tried "boot recovery" and a few iterations but no luck.. Do I just not know the correct commands to tell it?
Sent from my LG-D801
DurbanPoison24 said:
Hey all I hope I'm not in the wrong section and I tried searching for an already similar if not identical thread but couldn't find one(probably not looking too hard) but I have a rooted LG G2 and I have ADB up and running but I don't know the commands I'm assuming. I type "ADB shell" and it connects and finds device but the only command that works for me is "reboot system". I've tried "boot recovery" and a few iterations but no luck.. Do I just not know the correct commands to tell it?
Sent from my LG-D801
Click to expand...
Click to collapse
It would help if you told us what it is you're trying to do. If you just want a full list of every command then there's threads and websites that have it all. If you're trying to do something specific then let us know and we'll try and give you the correct commands.
The most common you'll use are:
adb devices - To ensure phone is connected correctly.
adb shell - To access the phone shell (?).
adb push [filename] /path/to/destination - Send a file from PC to phone, usually the sdcard.
Mr_JMM said:
It would help if you told us what it is you're trying to do. If you just want a full list of every command then there's threads and websites that have it all. If you're trying to do something specific then let us know and we'll try and give you the correct commands.
The most common you'll use are:
adb devices - To ensure phone is connected correctly.
adb shell - To access the phone shell (?).
adb push [filename] /path/to/destination - Send a file from PC to phone, usually the sdcard.
Click to expand...
Click to collapse
If it makes any sense I really wasn't trying to do anything specific I just wanted to make sure everything was working right. And as for what wasn't working for me was telling the phone to go into recovery. That's honestly the only thing I was trying.
Sent from my LG-D801 using xda app-developers app
You don't need a shell for this
adb reboot recovery
Should do the trick, opening a shell gets you into the phones file system which is not needed to reboot to recovery
Just do a quick Google search and you will find many guides on this, especially here in xda
Sent from my Nexus 7 using XDA Premium 4 mobile app

Help required removing Apps and Files that are write protected

Hey Guys,
Been lurking for a while. I want to get into some Android development. I bought a cheap Galaxy Tab s SM-T800 from ebay. It was a retail unit, so came with the usual retail protection, but that was no issue, I've reflashed it and rooted it, it is now running 6.0.1 with build number MMb29K.T800XXU1CRJ1.
The issue is, there are a bunch of apps and files that appear to be left over from the retail demo mode, and I can't remove them. The apps won't uninstall, it just says "uninstall unsuccessful", and the files, when I try to delete them, it just says "failed to delete".
Even after freshly restoring the new firmware, the storage on this device is pretty much zero, a lot of the space being taken up with the files and apps that I can't remove.
There was just about enough space remaining to install System App Remover, but that couldn't delete the files and apps either.
How are these files being write protected? How do I go about removing the write protection? I'm wondering if this device, because it was a retail demo unit, was configured with some kind of write protected partition, which is why the storage is so low, and why I can't delete the apps?
Any thoughts, this is driving me nuts.
Thanks
Install a file manager that allows to mount the partitions in question as READ-WRITE, thus folders/files can get deleted
jwoegerbauer said:
Install a file manager that allows to mount the partitions in question as READ-WRITE, thus folders/files can get deleted
Click to expand...
Click to collapse
Thanks, but I can't install any of the file manager apps, as there is not enough free space. I'll need to do it by connecting from Windows. What android partition/file manager would be a good one to use from Windows?
DotNetDude said:
Thanks, but I can't install any of the file manager apps, as there is not enough free space. I'll need to do it by connecting from Windows. What android partition/file manager would be a good one to use from Windows?
Click to expand...
Click to collapse
Because your device is rooted, you use ADB ( read: Android Debug Bridge ) - what you've to install on your Windows computer - to manage this device - you must have turned on Developer options -> USB Debugging on it, of course: IMHO the only the chance you have.
Once done so, you connect your device via USB cable with Windows computer, then in Windows command prompt run the commands as follows - one after one:
Code:
adb devices
adb root
adb shell mount -o rw,remount / -t auto
If success then your Android device completly is switched to READ-WRITE mode, you then via further relevant ADB commands can remove folders/files which you consider dispensable, even apps if you know their package name, and so on ...
jwoegerbauer said:
Because your device is rooted, you use ADB ( read: Android Debug Bridge ) - what you've to install on your Windows computer - to manage this device - you must have turned on Developer options -> USB Debugging on it, of course: IMHO the only the chance you have.
Once done so, you connect your device via USB cable with Windows computer, then in Windows command prompt run the commands as follows - one after one:
Code:
adb devices
adb root
adb shell mount -o rw,remount / -t auto
If success then your Android device completly is switched to READ-WRITE mode, you then via further relevant ADB commands can remove folders/files which you consider dispensable, even apps if you know their package name, and so on ...
Click to expand...
Click to collapse
Thanks for your details.
So I tired this but the adb root command wasn't working. It was coming up with the message:
adbd cannot run as root in production builds
So after a bit of research, I found the adp insecure app from Chainfire, that apparently resolves this exact problem. So I've deployed that to the tab and run it, but now when I connect the tablet to my PC, the PC doesn't connect. I get the charging symbol on the tab, so the connection is in place, but it is not detected by the pc, so I can't connect using adb.
Any suggestions would be much appreciated?
Thanks
DotNetDude said:
Thanks for your details.
So I tired this but the adb root command wasn't working. It was coming up with the message:
adbd cannot run as root in production builds
So after a bit of research, I found the adp insecure app from Chainfire, that apparently resolves this exact problem. So I've deployed that to the tab and run it, but now when I connect the tablet to my PC, the PC doesn't connect. I get the charging symbol on the tab, so the connection is in place, but it is not detected by the pc, so I can't connect using adb.
Any suggestions would be much appreciated?
Thanks
Click to expand...
Click to collapse
I realise I am responding to my own message!
Now that I am running with adb insecure, I have realisd that the USB debugging mode from developer settings is working in reverse. That is, if I enable it, the tab detaches form the PC. If I disable it, the tab reconnects to the pc. However with that setting disabled, and the pc connected, when I then run the command adb devices, it says there are no devices connected (even though I can browse to the tablet through windows explorer)
From within the adb insecure app on the tablet, when I enable the app, I can see it displays a message that says USB debugging is disabled.
I have no idea what is going on here...
Any help much appreciated?
Thanks
@DotNetDude
May be reading this helps.
jwoegerbauer said:
@DotNetDude
May be reading this helps.
Click to expand...
Click to collapse
Thanks for this. Actually, adbd insecure was just causing more problems. In the end I have resolved this by extracting the PIT file and re-partitioning. Firmware then restored correctly and all the problems are now gone, and there is plenty of free space remaining.

Categories

Resources