Connected to my android device using ADB but not able to use ls command, it says permission denied - General Questions and Answers

I connected to my android device (stock android, 10) using ADB on ubuntu, now when I go to /data/ and do ls, it says permission denied.
Why? How to solve this problem?

Android must be rooted to access the /data partition via ADB, that's all

Related

Problems with ADB

Trying to do some push/pull and do the new lag fix to no avail. After adb devices, the phone shows up as attached, but after adb remount I get "remount failed: No such file or directory" I'm not able to execute a push or pull command, and therefore I'm not able to run the lag fix.
I have USB Debugging selected, and I was able to delete the bloatware via adb shell, but none of the other commands go through for me...
Which version of Windows are you running?
Windows 7 64 bit
Still haven't found a fix to this, so I'll post up what I'm inputting and what I'm getting in return.
Here is the code I use to get into ADB and then attempt a remount:
Code:
cd C:\android-sdk-windows
cd tools
adb remount
remount failed: No such file or directory
When I try to push and/or pull, I get this:
Code:
adb push ./smoothcalendar.apk /system/app
failed to copy './smoothcalendar.apk' to '/system/app/smoothcalendar.apk': Permission denied
I've tried adb kill-server, then adb remount with the same issues.
currently experiencing the same problem...
Do you have BusyBox Installer installed on your phone? I believe you have to have it installed in order to use Android SDK.
I've got Busybox 1.17.1 on mine.
I'm wondering, is this a problem at the computer level or at the phone level? I know the Vibrant had some issues with push/pull, but I see some stuff here in the dev thread (lagfixes, sideloader stuff) that if I run from my computer attempt push/pull commands that fail and therefore the thing I'm running (lagfix most recently) doesn't actually work and I'm stuck with a slower phone.
If its a phone issues, I can just exchange it under warranty, since I'm out of my 30 days. But I'm hoping it's not as I'd like to keep this one that other than this has worked great for me.
When I first starting using ADB, I was connecting my phone like when I was using Windows Explorer to muck around on it. I had mounted the usb connection in the notification window. I kept getting errors when I tried to push/pull. I reconnected once and forgot to mount the usb connection and everything worked perfectly. Make sure the usb debugging is check marked in Applications in settings. Try to do the push/pull without using remount command and don't click on the USB connected notification option when you plug it in. I'm really new at this linux stuff so I could be wrong. I'm just trying to share my experience in hopes that maybe you're doing the same things I was doing before I stumbled onto the right way to do it.
Hmm, odd, I've tried that very method many times before, to no avail.
I try it just now, and having no problems with push or pull. Works for me! Thanks!

Changing permissions without ADB

I have a phone that came pre-installed with su, busybox and superuser; but the permissions are not set correctly for the user to access su and get root. The phone is running Android 1.6 and when you connect it to a computer in debug mode it is not recognized as an Android device; even though the phone says it is plugged into a computer and in debug mode. The only thing that comes up is the drive to access the SD card. My question is thus: Is there any way to change the permissions of su on the device itself? I have tried running a terminal emulator but when I type "su" the result is permission denied. Since I don't have permissions I cannot do a chmod on the device itself. If anyone knows a method I can do this I would appreciate it very much.

[Q] Accessing ADB shell of a device with a broken screen

Hi,
I'm trying to access ADB shell of a device (Samsung Galaxy s4 Mini LTE) where Androis 4.2 is installed.
Obviously it won't pass me because of missing public key on a device.
/adt-bundle-linux-x86_64-20140321/sdk/platform-tools $ ./adb devices
List of devices attached
x.x.x.138:5555 unauthorized
xxxx17d3 unauthorized
I have an access to ADB shell of a CWM installed on recovery partition and through that shell I'm able to access filesystem.
I have tried of: adb push ~/.android/adbkey.pub /data2/data/misc/adb
where /data2 is: mount /dev/block/platform/msm_sdcc.1/by-name/userdata /data2
But this is not working.
Anything else I could try?
There are apps out there that let you control your device remotely. But these still depend on you being able to install and launch the program.Using a package called Screencast you can get the image from the screen on your computer. It runs on your computer and doesn’t need to be installed on the phone, but it will require a rooted phone.
The phone is rooted but I can not install any apps because I cannot access ADB shell nor use display because it is all black and no touchscreen is working. Not a single pixel is lit up on a screen.

Android 4.1.1 - Files executed with an ADB connection

Hi.
I'm trying to control the access to ADB on Android 4.1.1. I already have root access to the device and now I'm trying to execute some access control code at the start of an ADB connection.
Are there any scripts that are executed with the "adb shell" access?
Thank you!

Connected to my android device using ADB but not able to use ls command, it says permission denied

I connected to my android device (stock android, 10) using ADB on ubuntu, now when I go to /data/ and do ls, it says permission denied.
Why? How to solve this problem?
Did you root your phone and did you run "adb root"?
Reference: https://stackoverflow.com/a/1043722/2908623

Categories

Resources