C:\Users\purpl\AppData\Local\Android\Sdk\platform-tools>ADB SHELL RM /DATA/SYSTEM/PASSWORD.KEY
adb: usage: unknown command SHELL
This line should run android sdk, but it doesn't and comes up with this
Unlike Windows file system adb commands are case-sensitive even on Windows.
Related
I was trying to install a gsi with DSU sideloader. It needs me to type a command using adb to initialize the installation. But I keep getting this error while running the adb shell command on my pc
adb shell sh/storage
/system/bin/sh: sh/storage: inaccessible or not found
The actual command was adb shell sh/storage/emulated/0/Dsu/workspace_dsuhelper/install
Which also results in the same error: /system/bin/sh: sh/storage/emulated/0/Dsu/workspace_dsuhelper/install : inaccessible or not found.
I know that /storage/emulated/0... exists but I am unable to access it. What could be the issue?
use this command to get the storage status
adb shell df /data
I am trying to execute iperf through adb shell, however I am getting following error:
syntax error: unexpected 'newline'
here are the steps:
push android compiled iperf binary to /data/local/tmp
enter adb shell, go to /data/local/tmp folder.
chmod +x ./iperf2.0.10
./iperf2.0.10
I tried executing command from outside like: adb shell "command"
I tried few other phones.
I tried few iperf versions.
host machine: tried both mac and windows. on windows version info:
Android Debug Bridge version 1.0.41
Version 31.0.3-7562133
phone info: adb shell getprop ro.product.cpu.abilist
arm64-v8a,armeabi-v7a,armeabi
I made sure to pick relevant iperf binary form: https://github.com/KnightWhoSayNi/android-iperf
This is a galaxy S7 SM-G930U, android version 8.0.0, kernel version 3.18.71-14970140
I looked at the iperf source code and could not find any place which would print this error message, so seems like some issue with how adb is treating my command.
Please suggest what can I do now ?
Edit: updated some details
I'm writing script to run iperf on linux device accessible via adb.
From a terminal, when I run the command: adb shell iperf -c ......
I get the log of the command 50 s after the command starting.
inconvenient: during 50 s you are not sure that iperf has started
I tried the logcat command (logcat --pid ...), It gives the same result.
From a terminal, when I enter adb session first and then I run the command: iperf -c .....
I get the log of the command in real time.
inconvenient: I'm not able to automate the procedure, because I have to start the adb session first
For the first use case: Is there a way to force "log flush" in order to get the log in real time?
For the second use case: Is there a way to send commands to already opened adb shell session?
Is there any other ways to launch iperf on device and get the log in real time?
The solution i found is the library pexpect that allow to interact with adb session.
I want to check a file in a sdcard but I have to use ADB.
I made this :
adb shell ls $EXTERNAL_STORAGE
It prompts me a list of directories but it's not my sdCard.
How can I find a file in my sdcard using adb ?
#paralleles. You can use the following adb command below to check if an external storage card exists:
adb shell echo /$EXTERNAL_STORAGE
If the above command executes successfully, you'll see a similar output as below :
Alternatively you can start an adb shell session and traverse the directory so as to find the desired file in your sdcard as follows :
adb shell
cd $EXTERNAL_STORAGE
If the above commands executes successfully, you'll see a similar output as below (depending on the files/folders in your SdCard):
I've installed Sencha by using the Terminal but I can't run if from the Terminal
samuel#samuel-pc:~/Downloads$ sudo ./SenchaCmd-6.5.0.180-linux-i386.sh -q
Starting Installer ...
The installation directory has been set to /root/bin/Sencha/Cmd/6.5.0.180.
Extracting files ...
Finishing installation ...
samuel#samuel-pc:~/Downloads$ sencha
sencha: command not found
Because you don't set environment variable.
If running sencha results in the error message sencha: command not
found on OSX/Linux or 'sencha' is not recognized as an internal or
external command, operable program or batch file on Windows, follow
these steps: ...
This is official guide: https://docs.sencha.com/cmd/guides/intro_to_cmd.html#intro_to_cmd_-_command_not_found