The shell is a piece of software that provides an command-line interface to the operating system. Use this tag for shell-specific issues; general command-line issues should use the 'command-line' tag instead. See full tag wiki for other related tags.

learn more… | top users | synonyms

0
votes
0answers
18 views

How can I run a file on my phone, via the terminal on my computer?

I'm doing this. There is a detailed version of what I did. Now someone suggested me to install TWRP recovery, it could be installed via the playstore, but now I have no idea on how to make android ...
6
votes
3answers
153 views

Enable On-screen navigation in CM12 (Lollipop) using shell?

Device: OnePlus One (OPO); running CM12, is rooted, and has Xposed Framework installed. I need to enable On-screen navigation (it disables Hardware (HW) keys and shows soft keys at the screen; like ...
0
votes
0answers
2k views

“shell has been granted superuser permissions” on non-rooted smartphone

My Galaxy S3 has just shown the blinking message "shell has been granted superuser permissions" (when clicking a Pinterest notification). The phone is not rooted and is running Android 4.0.4. What ...
1
vote
2answers
1k views

adb shell check if a certain directory exist on avd

I want to check if a certain directory (/data/textdata/ ) exists on the avd using adb shell. reading ...
0
votes
0answers
12 views

Turn off radio layer hardware calls to save battery when your broadband hardware is gone

With reference to my question here: IM-A870L Radio Interface Layer broke down Summary: My android phone broadband chip is dead. For some reason, its not working anymore. Now I can use the phone for ...
5
votes
4answers
22k views

Android ADB Shell Recovery Mounting

*Question: I need assistance mounting an Android phone's internal data using the Android ADB Shell while the unit is connected via USB and in recovery mode. How do I form a proper mount command? See ...
13
votes
3answers
10k views

Can I change some Android settings from the command line?

I would like to activate "USB tethering" from within a bash script, so is there any possibility to run a command line with adb shell to change some Android settings ? Edit1: The following command ...
1
vote
2answers
791 views

Can't set date via shell

I've tried date -u 1407697765 output: time 1407697765 -> 1407697765.0 settimeofday failed Bad file number and busybox date -s @1407697765 output: date: can't set date: Operation not ...
0
votes
1answer
1k views

Identifying an unknown Android tablet through adb/shell without relying on build.prop

I obtained a cheap unbranded tablet from a friend, without a box or anything and I need to figure out what kind of tablet it is, through software. What I've established so far is that the tablet is ...
0
votes
1answer
1k views

Can not uninstall standard Android keyboard or get it back working

I want to uninstall the standard Android keyboard com.android.inputmethod.latin. I googled and found multiple threads discussing this problem. What I did so far: 1.) Uninstall via intent -> doesn't ...
0
votes
1answer
53 views

Getting message “Unknown id: netcfg” while setting up usb0 interface for reverse tethering

I am trying to setup reverse tethering between Sony Xperia 4.0.4(rooted) and Linux 12.04. I'm following steps from Matthew Read's answer on this post, How to set up reverse tethering over USB? All ...
0
votes
2answers
845 views

Motorla Defy+ being not possible to root. Script commands throwing errors when rooting android 2.3.6

It's getting very hard to root a Motorola Defy+ (mb256). My cellphone is accepting non android market apps, and USB debugging mode is enabled. I tried: - using z4Root app. - doing the scipt commands ...
0
votes
0answers
22 views

Where are settings for `svc power stayon true` stored?

I want to make a simple utility where I can read the current setting for the stayon portion of svc, and also change it. I got changing the setting down, but how do I find out the current value of it? ...
0
votes
1answer
23 views

What does “svc power stayon wireless” do?

Looking at the reference to svc on my phone there are options for svc power stayon [true|false|usb|ac|wireless]. I'm curious what usb, ac, and wireless do when you use them? I tried svc power stayon ...
0
votes
0answers
11 views

Android package manager (pm) returns blank on every command

For example if I run the command pm list packages, pm list permission-groups, pm uninstall com.google.android.apps.books, etc. All return blank and seem to have done nothing. I do have root, I'm ...
1
vote
0answers
18 views

Ngrok (compiled for Arm5) crash on android: can't find core dump files!

I downloaded Ngrok which I want to install on a old HTC Hero [the project is to transform the phone in a ipcam, reachable behind a NAT network], so I chose the version compiled for Arm5. You can find ...
3
votes
1answer
47 views

How to see all TCP connections being routed for hotspot?

I want to see a list of all active TCP connections on my Android device, regardless of whether they terminate in the device. E.g., when my phone is serving as a WiFi hotspot, I would like to see all ...
0
votes
0answers
33 views

How can I run a shell script when some WiFi is connected?

I have a really simple shell script, that just adds a route to my internal development machine. This is useful, as that machine has some LXC containers inside, so I can reach all my containers from my ...
3
votes
0answers
1k views

Simulate missed call from ADB shell

On the ADB shell, I run the command adb -s <serial_number> shell am start -a android.intent.action.CALL -d tel:123456 to place a call on my testing device. It works great. But I also want to ...
1
vote
2answers
2k views

How do I view/mount nandroid file on device?

From Android's terminal, I tried to mount a nandroid img: losetup -f gives "/dev/loop0". However, when I try losetup /dev/loop0 /sdcard/nandroid/... data.img it says no such directory. Same thing ...
0
votes
1answer
62 views

Why does SSH Server (Ice Cold Apps) with a command fail?

I wish to ssh into my rooted Android Samsung Galaxy S4 v4.4.2 phone and run a command. I have SSH Server installed. If I just SSH, it works fine: bash-3.2$ ssh -p 35151 10.1.10.22 ...
0
votes
0answers
32 views

Why does my PATH get set differently for SSH Droid?

I've noticed that depending upon how I enter my rooted phone I get a different PATH setting: # ADB bash-3.2$ adb shell shell@kfotetzx:/ $ echo $PATH ...
1
vote
1answer
43 views

Why does stat report no space on / (root) but space available on /system?

On my rooted Android 4.4.2 Samsung Galaxy S4 phone with armv7l chipset, if I start a shell, I can use the stat command, but some devices report strange. In particular, the / device shows zero size, ...
1
vote
0answers
18 views

Parted says external SD card has no partitions, but Android can still read it

I have a 16GB external SD card that I'm currently using for my music collection. Android reads it just fine, and CWM mounts it perfectly. I'm on Gingerbread (I have my reasons). I opened up adb shell ...
0
votes
1answer
30 views

What is the pathname to my application executable? [closed]

I wish to get the pathname for an application I am creating and have installed via Eclipse and ADB. My application is installed as I see an icon that I can invoke to launch successfully my ...
1
vote
0answers
71 views

Setting IncognitoModeAvailability policy for Google Chrome on an Android tablet?

Google Chrome supports an “IncognitoModeAvailability” policy that I want to set on my Android (Jelly Bean) tablet. Here is a link that describes the policy, if you want to read more about it: ...
1
vote
1answer
117 views

Is root ownership inherited in shell scripts? (rsync via ssh permission denied)

I am running Android Revolution HD 52.0 custom ROM (Android 4.3) with Koush's superuser 1.0.3.0 on a Samsung Galaxy S3 GT-I9300. In the hope of using some native shell applications on my phone for ...
1
vote
2answers
235 views

How do I display message from from `adb shell` (or a shell script)?

I expect it to be something like adb shell am start SomethingArcane ... "Hello, world" and the message box pops up on screen, saying "Hello, world".
2
votes
3answers
14k views

can't use adb shell in recovery mode

I have a china tablet named Quest. I have accidentally repeated pattern lock more than 5 times. Now I have also forgotten the email address. So for a factory-reset of my tablet I simply booted it ...
2
votes
1answer
750 views

Where is the battery animation called?

I have a tablet from China, it's a Q8H Allwinner. It is rooted, and I've browsed the internal storage for hours to find the battery animation, I found them at framework-res.apk... Now I want to find ...
0
votes
1answer
65 views

How do I mount an NFS share on an CM 12?

I'd like to mount an NFS share on my Android cell phone, with perhaps a mount-unmount button on the home screen. Any ideas of how to accomplish this? My /system/lib/modules is empty. It doesn't have ...
0
votes
1answer
177 views

How to query/change the default gateway via bash on CM12?

When i do a 'busybox route' on CM12 i get this: localhost / # busybox route Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 192.168.100.0 * ...
0
votes
0answers
87 views

How to find out currently running user name/ID from ADB

I am having Nexus 7 running multiple users. I am trying to find out which is currently running user using ADB. The best I could get so far was to check legacy directory linking which is either linked ...
0
votes
1answer
150 views

How to read geolocation using adb shell

Is it possible to read geolocation data (either one provided by GPS or by GSM) using adb shell?
0
votes
1answer
18 views

Getting screen dimensions in a shell script

To run a game on my Nexus 5 (5.1), I need to change my screen resolution. I'm trying to write a shell script that will detect the current resolution and change it, basically a toggle. I know that I ...
0
votes
0answers
104 views

Mounting USB in android 4.1.2

I am trying to mount USB pen drive in my old Xperia phone running andorid 4.1.2 When I connect OTG device to my phone I get an USB power consumption error. After little search I found a command to ...
7
votes
2answers
33k views

Why can't I get root access from shell?

> adb shell sh-4.1$ su Permission denied I have rooted my phone successfully. I know this because I'm able to install apps on SD card and I have a program called SD Maid that is able to operate ...
0
votes
1answer
73 views

How do I create an archive for easy extraction to /data/local/tmp/ in “adb shell”?

Usual shar archives fail to extact in adb shell due to problems with lock directory and temporary files for HERE documents. Zip archives are also not an option. How do I make an archive that can be ...
0
votes
1answer
31 views

Work-around for process substitution in mksh

An extremely useful feature of Bash, known as process substitution, is missing in the Android shell, mksh. This is highly unfortunate as it prevent you from doing things like: diff <(sort list1) ...
0
votes
0answers
47 views

is there a way to run *.sh file by just touching it in a file manager?

I mean like it is when user opens an image file a pane opens where user can select app for given type. But when I'm clicking on *.sh file the first option that shows up is to open as ...
0
votes
0answers
127 views

How to pipe output of dd to a computer via adb shell?

I've accidentally wiped my phone and lost all my photos. I'm going to try to run photorec on an image of my phone. What I'd like to do is somehow something along these lines: adb shell dd if=/data ...
14
votes
2answers
13k views

What's the best way to restart Android via command line (remotely)?

I'm looking for the best / friendliest way to reboot my rooted android 4.1.1 device. I found these solutions so far: su -c "reboot" - Causes problems with wifi after restart on my device... I read ...
3
votes
0answers
4k views

Is it possible to enable Location Services via Shell?

Is it possible to enable Location Services(GPS or Google NetworkLocation) via ADB or Terminal Emulator? I'm on a rooted Phone. Extra Points: Is it also possible to change other system-related ...
4
votes
3answers
6k views

Broken Screen + Using adb shell to run vnc server

I have an HTC HD2 with a completely busted screen, I tried repairing it with a replacement screen but broke the ribbon cable to the screen (oops) sad day, I've got two of these and I've been running ...
3
votes
3answers
2k views

What is the applypatch tool and how does one use it?

I recently stumbled upon the applypatch tool, but I couldn't find any documentation for it online. Here is the usage output (this is after typing adb shell) shell@android:/ $ applypatch --help ...
0
votes
0answers
35 views

Where in the filesystem are settings saved? Namely ADB backup password

Where in the phone filesystem are settings saved? I've lost my ADB backup password and simply want to delete it. If it affects other settings that won't matter too much. I will be interfacing the ...
0
votes
1answer
1k views

Why the file path the phone tells me ,I couldn't find in 'adb shell'?

I used my new Moto X phone, then I encountered a basic problem. It's running Android 4.4.2. I take a photo, and want to send it to my PC. The Gallery app tells me the photo is at ...
5
votes
2answers
30k views

How to start root shell with Android Studio?

I just installed Android Studio. How do I get into root shell on my phone? Or do I have to download ADB separately?
1
vote
0answers
224 views

I can't see new files throught windows explorer

i can't see my new(!) files on android throught windows explorer while i can do it by ES explorer or adb shell. Is there any way to fix it?
0
votes
2answers
960 views

Permission denied when accessing file pushed using boot insecure into my Nexus 4 with Android 5.0.1

I have a Nexus 4 with Android 5.0.1. I copy a file doing the following: I reboot to bootloader Boot using insecure boot.img: fastboot boot boot.img Pushed a file: adb push IMG_20140710_105128.jpg ...