Friday, October 27, 2023
Friday, April 28, 2023
Understanding the Importance of the EnterpriseID in Google's EMM Program and locate EnterpriseID
To find the EnterpriseID in the Google Cloud Console, follow these steps:
- Log in to the Google Cloud Console with your EMM administrator account.
- In the left-hand navigation menu, click on "IAM & Admin."
- Click on "Settings" in the submenu that appears.
- Under "Organization Settings," you should see your EnterpriseID listed.
To find the EnterpriseID in the Google Admin Console, follow these steps:
- Log in to the Google Admin Console with your EMM administrator account.
- In the left-hand navigation menu, click on "Billing."
- Under "Subscriptions," you should see your EnterpriseID listed next to your EMM subscription.
- If you do not have access to either the Google Cloud Console or the Google Admin Console, you may need to contact your EMM administrator or Google Workspace support for assistance in finding your EnterpriseID.
Sunday, February 12, 2023
Top 10 Awesome Tricks that Android User Should Know
Lets go through the tricks quickly:
Enable System UI Tuner: This feature allows you to customize the status bar icons, add a battery percentage indicator, rearrange the quick settings tiles, and more. To enable it, go to "Settings" > "System" > "About phone" and tap the "Build number" several times until you see a message saying "You are now a developer." Then, go back to "Settings" > "System" and you should see a new option for "System UI Tuner."
Take advantage of Google Lens: Google Lens is a feature that uses your camera to recognize objects and provide information about them. Simply launch the Google Lens app and point your camera at an object or text to get started.
Use Google Maps street view: This feature allows you to explore locations as if you were actually there. Simply open Google Maps and search for a location, then tap on the "Street View" option to see a 360-degree panoramic view.
Automate tasks with Tasker: Tasker is an app that allows you to automate tasks and actions on your Android device. For example, you can set it up to turn off Wi-Fi when you leave home, turn on your music player when you plug in headphones, and more.
Enable Google Now on Tap: Google Now on Tap allows you to quickly search for information related to what's on your screen without leaving the app you're in. Simply long-press the home button and Google Now on Tap will analyze the screen and provide relevant information.
Use Google Keep for quick notes: Google Keep is a simple note-taking app that integrates with other Google services, making it easy to access your notes from anywhere. You can create text, voice, and image notes, and set reminders to keep track of what you need to do.
Set custom ringtones and notifications: You can set custom ringtones and notifications for individual contacts, making it easy to know who's calling or texting without looking at your phone. Simply go to "Contacts" > select the contact > "Edit" > "Ringtone" or "Notification tone" to set a custom sound.
Use two apps at once with App Twin: Some Android devices support App Twin, which allows you to run two instances of the same app on one device. This is useful if you want to run two WhatsApp accounts, for example. The feature may be located in the settings under "Dual apps" or "App twin," depending on your device.
Control your phone with your voice: You can use voice commands to control your phone, such as making calls, sending texts, and more. Simply say "Ok Google" to activate the Google Assistant and start using voice commands.
Manage apps with Android's App Info: You can access Android's App Info to see which apps are using the most data, battery, and storage, and to force stop or uninstall apps as needed. To access it, go to "Settings" > "Apps" and select the app you want to manage. From there, you can view its usage stats, clear its cache, and more.
Sunday, January 29, 2023
Android App directories and methods to be used to access these app directories
Next is external storage and directories present in external path like SDCard
/storage/emulated/obb/<pkg>/*.obb - Shared by multi-users, exposed in following view)
/storage/emulated/<user_id>/Android/obb/<pkg>/*.<pkg>.obb - To fetch data from this path use getObbDirs()
/storage/emulated/<user_id>/Android/media/<pkg> - To fetch data from this path use getExternalMediaDirs()
/storage/emulated/<user_id>/Android/data/<pkg>/ - To fetch data from this path use getExternalMediaDirs()
/storage/emulated/<user_id>/Android/data/<pkg>/files - To fetch data from this path use getExternalFilesDirs()
/storage/emulated/<user_id>/Android/data/<pkg>/[code_]cache - To fetch data from this path use getExternalCacheDirs()
Sunday, November 13, 2022
Here is a basic and important info how to resolve this issue.
What is fastboot mode?
What is Recovery mode?
Recovery Mode is used for Zip files from OEMs or Update the OS version or firmware version. You can also use for deleting Userdata or do a factory Reset of your phone.
Recovery does not use command line tool instead it itself can flash the files which can be kept in the phone memory (if phones memory has partition available) or file can be kept in external SD card.
Recovery Mode on Xiaomi phones :
While you struggle to find out what and where exactly the problem is, your battery might get drained out and then you are out of options now. With drained battery, you can neither check further nor you can reflash new OS.
After digging a lot, I found a way to charge the battery atleast. So that I could confirm that, problem is because of Power Button and not because of corrupted OS.
While trying to do all of this , I tried flashing a complete OS image using the Xiaomi flash and that deleted everything from my phone including OS, so phone was just rebooting in fastboot mode.
To start with, I am assuming you have fastboot.exe on your system. If not, please refer this: https://wiki.lineageos.org/adb_fastboot_guide
And quickly need to flash the TWRP Recovery Image.
In my case - I renamed the file to recoveryb.img
fastboot flash recovery <path to recoveryb.img/recoveryb.img
The file size is around 14MB so it would be flashed quickly before your phone switches off or reboot.
Even if your battery is dead you can flash via fastboot.

Alternately, you can double click and run the flash_recovery.bat file to flash the TWRP recovery image when phone is in Fastboot mode.
Once flashing is done, you will start seeing the MIUI logo.
Now, Connect your phone to a charger and you can remove the battery and connect it back while holding Power key and volume up key.
This will take you to TWRP recovery screen (as device was flashed with TWRP recovery image)
Quickly at bottom of the screen press up or down to move to some other page in recovery screen.
It seems, for me Power button had no impact on Recovery screen and I was able to charge the phone to 100% in recovery mode.
You would notice that phone is charging at the top right , where battery percentage is append with "+" symbol
Let the phone charge completely to be on the safer side.
Meanwhile, you can download the complete OS for your phone from MIUI.com
and keep it in SDCARD

Once phone is completely charged or charge is greater than 80%. Keep the sdcard inside the phone.
Press the Power key and volume up key to go to TWRP recovery screen.
Click on Install button.
Select the SDCARD path where OS zip image is kept (remember flashing the complete image will make you loose your all data)
And select Yes to start the phone flashing.
Now your phone has a proper OS image which is supposed to boot properly.
But if phone continues to boot again and again from MIUI logo screen.
That confirms something is wrong with the power button of the device.
Go to nearest mobile repair shop and get the power button replaced.
He might argue that the issue is with OS or flashing but as you have done your homework, ask him to replace the button blindly. It just would cost you few bucks. There you go, you will have your phone working afterwards for sure.
Friday, September 9, 2022
What is WorkspaceOne Intelligent Hub
And Removing VMware WorkspaceOne Intelligent Hub from Android phonesLet's start with the basic question, what WorkspaceOne Intelligent Hub is and what does it do?
Well, it's not easy to get this one answered in short. It would require its own post. But anyways, I will try to summarise it in a short way. Please do comment if you are looking for a complete post on it. I've seen multiple reviews on Google Playstore where many users have asked, "I've installed Intelligent Hub but how to remove this app" or "can someone help to uninstall this app, I am not able to remove the Intelligent Hub".So, lets start first with, what VMware WorkspaceOne Hub is - WorkspaceOne Intelligent Hub is a Mobile Device Management application for Android phones and it falls under an umbrella term called Enterprise Mobility Management (EMM) app. Similar apps are also available on different Platforms like iOS, Windows and different companies have their own client application created. For example, Microsoft has InTune, IBM has MaaS360, Ivanti got MobileIron and there are many more. This client app allows organizations to securely enable employees to use their mobile phones and the applications on them. EMM apps help IT department of a company to control the device (not as in actual control but manage the device settings, applications, etc). They can deploy and remove the applications on the phone remotely. They also can deploy restrictions on the device like Not allowing a user to open Camera or to open Playstore app etc. Thus, managing the device to increase the productivity of the workforce. Most of the device users are either being requested by the company to install the Hub app from Google playstore OR the company's IT department itself would install the app and have it enrolled for the user.
Why can't you uninstall Hub?
The moment you try to enrol the phone with Intelligent Hub, the app would request certain permission which I will be discussing later in the article, which is the cause of the issue. Be it company-owned mobile devices (i.e. Corporate Owned) or your personal device (i.e. Bring Your Own Device - BYOD), the day you do not want to use this app, you will have to unenrol yourself from the Intelligent Hub application first. Point to note here is unenroling from the Hub app will not uninstall the app.
Although, it's just a 100MB-150MB app, but no one would want an app that just sits on device ideally and consume space. You try to go to Settings > Apps > Find Hub. Here, what you find is, Uninstall Option is Disabled. This is what annoys everyone, why would an App which is installed by you, does not get uninstall.
And you would ask, why I am not able to uninstall it from my Android mobile. The simple reason is - it's Google (of course because Android is from Google) and your company's IT Admin does not want you to uninstall it from the phone. But if you have a mobile enrolled in a specific mode you should be able to. Let's look into it further.
Now another question arises, what is Device Admin? Let's do a small quick dive into it before proceeding.
As the name suggests, Device Admin applications are the ones that have control of the device.
For example, "Google Find my Device" will be pre-installed on every Google Playstore supported device and this app will be de-facto a Device Admin. As the app has elevated permission already given by Android OS, this app is capable of ringing the device and locating the device without user's intervention. That is the only reason, we are able to find the device even if the mobile screen is locked and no one is using it.
You can see the same on your mobile phone under the Settings > Security & Location > Advanced > Device Admin App . The Find My Device app is set as Device Admin with a Tick mark. The Tick suggests that the listed app is Device Admin and Un-tick refers that the app is installed but not set as Device Admin.
Steps to Uninstall Intelligent Hub from Android phones
So, if you want to Uninstall the Intelligent Hub from your mobile and if your phone is enrolled with and Android Legacy mode of enrolment called Device Admin mode, you just need to perform the below steps. For more details, you can check this guide from Google on Legacy Deprecation.
Go to Settings > Security & Location > Advanced > Device admin apps
Untick or Disable the WorkspaceOne Intelligent Hub
On the next screen, select "Deactivate this device admin app"
Go to Settings > Applications & notifications > Search for Hub and click on Uninstall
When you cannot Uninstall Android Hub
There is one more real-time scenario when you see Hub is installed on the device but the option to "Deactivate this device Admin app" is Disabled (Grayed out). This is the case, where the mobile was enrolled in Work Managed or Device Owner mode or Corporate Owner Personally Enabled (COPE). You can confirm this by launching the Hub app and clicking on "This device" option. If you are seeing "Work Managed" or Corporate Owner Personally Enabled as in the below screenshot, you can be sure that the Hub app is Device Owner app and your Company or IT department is in complete control of the mobile phone.
As the option is grayed-out , you will not be able un-install the Hub app. If your Company IT Admin has permitted you to see and launch Hub, you can try launching the Hub app. From the Account screen, tap on This Device option and then tap on the Enrollment option. You would find Unenroll Hub if IT admin has kept the option enabled. If it's enabled by mistake, try not to click on it. Click it in Work Managed Mode or Corporate Owner Personally Enabled device would factory reset the device. This is expected Designed behaviour.
Incoming searches:
How to uninstall VMware Intelligent hub
Uninstall steps for VMware Intelligent hub
Sunday, July 17, 2022
You can run adb command - adb install <apk> to install apps from command line if you have Android SDK installed. You can download them directly from the links here or you can search and get them from Google play store and install them from the mobile's File Manager.
Here is the list of Small Size Test Apks
1. Chhotu- The Smallest APK
Playstore link:
https://play.google.com/store/apps/details?id=a.i
Size of app: 2.4k
2. Smallest App - 4G Switch and Network Info
2nd on the list is Info app with size slightly more than above . It's just 2.8KB and displays information like SIM cards, IMEI number, phone number, current network etc.
3. I'm small app
Playstore link:
https://play.google.com/store/apps/details?id=com.vkopitsa.droid.smallapp
Size: 3.38 KB
4. Smallest app
Playstore link:
https://play.google.com/store/apps/details?id=z.m
Size: 3k
Sunday, May 23, 2021
ADB SHELL COMMANDS LIST
adb is included in the Android SDK Platform-Tools package. You can download this package with the SDK Manager, which installs it at android_sdk/platform-tools/
. Or if you want the standalone Android SDK Platform-Tools package, you can download it here.
For information on connecting a device for use over ADB, including how to use the Connection Assistant to troubleshoot common problems, see Run apps on a hardware device.
- Below is the comprehensive List of ADB commands that are used regularly
adb sideload - adb shell settings
- adb shell dumpsys
- adb shell wm
- adb shell dumpsys battery
- adb shell pm
- adb shell input keyevent <>
- adb shell input text
- adb shell input tap
- adb shell cat
- adb shell top
- adb shell ifconfig
- adb shell screenrecord
- adb shell screencap
- adb shell mount
- adb shell date
- adb shell netstat
- adb shell ps
- adb install
- adb uninstall
- adb root
- adb pull
- adb push
- adb shell am
- adb shell ping
adb sideload
adb sideload ota_file.zip
Updating Phones OTA Images manually via command.
Prior to this need to take phone to recovery mode (adb reboot recovery)
adb shell dumpsys iphonesubinfo
adb shell dumpsys iphonesubinfo
Get Android device IMEI (Only for Android 4.4 or lower, otherwise needs ROOT permission)
adb shell getprop
adb shell getprop
Get Android system properties info.
adb shell getprop ro.build.version.sdk
Get SDK API level.
adb shell getprop ro.build.version.security_patch
Get Android security patch version.
adb shell getprop ro.board.platform
Get SOC info.
adb shell getprop ro.build.version.release
Get Android version info.
adb shell getprop ro.vendor.product.model
Get Android device model.
adb shell getprop ro.product.manufacturer
Get Android device manufacturer.
adb shell getprop ro.serialno
Get ADB serial number.
adb shell getprop ro.oem_unlock_supported
Get OEM unlock status.
adb shell getprop ro.bootimage.build.fingerprint
Get Android device build fingerprint.
adb shell getprop ro.boot.wifimacaddr
Get WiFi MAC Address
adb shell settings
adb shell getprop
Get Android system properties info.
adb shell getprop ro.build.version.sdk
Get SDK API level.
adb shell getprop ro.build.version.security_patch
Get Android security patch version.
adb shell getprop ro.board.platform
Get SOC info.
adb shell getprop ro.build.version.release
Get Android version info.
adb shell getprop ro.vendor.product.model
Get Android device model.
adb shell getprop ro.product.manufacturer
Get Android device manufacturer.
adb shell getprop ro.serialno
Get ADB serial number.
adb shell getprop ro.oem_unlock_supported
Get OEM unlock status.
adb shell getprop ro.bootimage.build.fingerprint
Get Android device build fingerprint.
adb shell getprop ro.boot.wifimacaddr
Get WiFi MAC Address
adb shell settings list system
Android Settings provider (system namespace)
adb shell settings get system volume_system
Get current system volume level in Android.
adb shell settings get system notification_sound
Get current system notification sound in Android.
adb shell settings list secure
Android Settings provider (secure namespace)
adb shell settings get secure android_id
Find Android Device Identifier(Device Id)
adb shell settings get secure bluetooth_address
Find Bluetooth MAC address in android.
adb shell settings list global
Android Settings provider (global namespace)
adb shell settings get global mobile_data
Get current mobile data status in Android.
adb shell settings get global wifi_on
Get current WiFi status in Android.
adb shell pm
adb shell pm list packages
Get List of Installed Apps in Android.
adb shell pm list packages -s
Get list of System apps
Other params:
-d : Disabled apps
-e : Enabled apps
-u : Uninstalled apps
adb shell pm list packages -3
lists 3rd-Party apps
adb shell pm list packages <keywords>
Keyword filtering
adb shell pm path <package-name>
Get the APK path on the device's filesystem
adb shell pm uninstall <package name>
-k - keeps the app data and cache as is on mobile
e.g. adb shell pm uninstall -k --user 0 com.facebook.appmanager
adb shell pm disable-user --user 0 <package name>
to disable a system app on your Android mobile device
adb shell pm hide -user 0 <package name>
to hide an app from device
adb shell pm create-user <username>
to create another user on the device
adb shell pm remove-user <user_id>
to remove another user on the device
adb shell wm density
Get screen physical density in Android
adb shell wm size
Get screen physical size in Android
adb shell wm density
Get screen physical density in Android
adb shell wm size
Get screen physical size in Android
adb shell dumpsys battery
adb shell dumpsys battery
Get battery info in Android.
Current Battery Service state:
AC powered: false
USB powered: true
Wireless powered: false
Max charging current: 500000
Max charging voltage: 5000000
Charge counter: 3367082
status: 2
health: 2
present: true
level: 98
scale: 100
voltage: 4393
temperature: 325
technology: Li-ion
adb shell dumpsys battery
Get battery info in Android.
Current Battery Service state:
AC powered: false
USB powered: true
Wireless powered: false
Max charging current: 500000
Max charging voltage: 5000000
Charge counter: 3367082
status: 2
health: 2
present: true
level: 98
scale: 100
voltage: 4393
temperature: 325
technology: Li-ion
adb shell pm
adb shell pm list packages
Get List of Installed Apps in Android.
adb shell pm list packages -s
System apps
adb shell pm list packages -3
3rd-Party apps
adb shell pm list packages <keywords>
Keyword filtering
adb shell pm path <package-name>
Get the APK path on the device's filesystem.
adb shell pm list features
lists phone features
adb shell pm list packages
Get List of Installed Apps in Android.
adb shell pm list packages -s
System apps
adb shell pm list packages -3
3rd-Party apps
adb shell pm list packages <keywords>
Keyword filtering
adb shell pm path <package-name>
Get the APK path on the device's filesystem.
adb shell pm list features
lists phone features
adb shell input keyevent
adb shell input keyevent [--longpress] <key code number or name>
Control Keypress events on Android
adb shell input keyevent 187
KEYCODE_APP_SWITCH
adb shell input keyevent 3
KEYCODE_HOME
adb shell input keyevent 84
KEYCODE_SEARCH
adb shell input keyevent 219
KEYCODE_ASSIST
adb shell input keyevent 231
Voice Assist key
adb shell input keyevent 5
KEYCODE_CALL
adb shell input keyevent 6
KEYCODE_ENDCALL
adb shell input keyevent 7
KEYCODE_0
adb shell input keyevent 16
KEYCODE_9
adb shell input keyevent 29
KEYCODE_A
adb shell input keyevent 54
KEYCODE_Z
adb shell input keyevent 66
KEYCODE_ENTER
adb shell input keyevent 67
KEYCODE_DEL
adb shell input keyevent 24
KEYCODE_VOLUME_UP
adb shell input keyevent 25
KEYCODE_VOLUME_DOWN
adb shell input keyevent 164
toggle MUTE the speaker
adb shell input keyevent 91
toggle MUTE the microphone
adb shell input keyevent --longpress 26
Long PRESS power key
adb shell input keyevent 26
KEYCODE_POWER
adb shell input keyevent 27
KEYCODE_CAMERA
adb shell input keyevent 223
Lock screen.
adb shell input keyevent 224
Wakes up the device.
adb shell input keyevent [--longpress] <key code number or name>
Control Keypress events on Android
adb shell input keyevent 187
KEYCODE_APP_SWITCH
adb shell input keyevent 3
KEYCODE_HOME
adb shell input keyevent 84
KEYCODE_SEARCH
adb shell input keyevent 219
KEYCODE_ASSIST
adb shell input keyevent 231
Voice Assist key
adb shell input keyevent 5
KEYCODE_CALL
adb shell input keyevent 6
KEYCODE_ENDCALL
adb shell input keyevent 7
KEYCODE_0
adb shell input keyevent 16
KEYCODE_9
adb shell input keyevent 29
KEYCODE_A
adb shell input keyevent 54
KEYCODE_Z
adb shell input keyevent 66
KEYCODE_ENTER
adb shell input keyevent 67
KEYCODE_DEL
adb shell input keyevent 24
KEYCODE_VOLUME_UP
adb shell input keyevent 25
KEYCODE_VOLUME_DOWN
adb shell input keyevent 164
toggle MUTE the speaker
adb shell input keyevent 91
toggle MUTE the microphone
adb shell input keyevent --longpress 26
Long PRESS power key
adb shell input keyevent 26
KEYCODE_POWER
adb shell input keyevent 27
KEYCODE_CAMERA
adb shell input keyevent 223
Lock screen.
adb shell input keyevent 224
Wakes up the device.
adb shell input text
adb shell input text <string>
Sending Keyboard input to your Android device.
adb shell input text Nexus
adb shell input text ADB%sInstaller
Tips: %s means SPACE, replace spaces with %s
adb shell input text <string>
Sending Keyboard input to your Android device.
adb shell input text Nexus
adb shell input text ADB%sInstaller
Tips: %s means SPACE, replace spaces with %s
adb shell input tap
adb shell input tap <x> <y>
Simulate a touchscreen tap X,Y position.
adb shell input tap 620 1300
To find the exact X,Y position go to "Settings" > "Developer Options" > Check the option "Pointer location"
adb shell input tap <x> <y>
Simulate a touchscreen tap X,Y position.
adb shell input tap 620 1300
To find the exact X,Y position go to "Settings" > "Developer Options" > Check the option "Pointer location"
adb shell cat
adb shell cat /proc/cpuinfo
CPU Info
adb shell cat /proc/meminfo
RAM Info
adb shell cat /proc/cpuinfo
CPU Info
adb shell cat /proc/meminfo
RAM Info
adb shell top
adb shell top
The top command allows users to monitor processes and system resource usage on Linux.
adb shell top
The top command allows users to monitor processes and system resource usage on Linux.
adb shell ifconfig
adb shell ifconfig
Display or configure network interface
adb shell ifconfig wlan0
WiFi Connection Info
adb shell ifconfig
Display or configure network interface
adb shell ifconfig wlan0
WiFi Connection Info
adb shell screenrecord
adb shell screenrecord /sdcard/test.mp4
Records the device's display to a .mp4 file
adb pull /sdcard/test.mp4
Download test.mp4 file from Android Device.
adb shell screenrecord [options] <filename>
Options:
--size WIDTHxHEIGHT
Set the video size, e.g. "1280x720". Default is the device's main
display resolution (if supported), 1280x720 if not. For best results,
use a size supported by the AVC encoder.
--bit-rate RATE
Set the video bit rate, in bits per second. Value may be specified as
bits or megabits, e.g. '4000000' is equivalent to '4M'. Default 20Mbps.
--bugreport
Add additional information, such as a timestamp overlay, that is helpful
in videos captured to illustrate bugs.
--time-limit TIME
Set the maximum recording time, in seconds. Default / maximum is 180.
--verbose
Display interesting information on stdout.
adb shell screenrecord /sdcard/test.mp4
Records the device's display to a .mp4 file
adb pull /sdcard/test.mp4
Download test.mp4 file from Android Device.
adb shell screenrecord [options] <filename>
Options:
--size WIDTHxHEIGHT
Set the video size, e.g. "1280x720". Default is the device's main
display resolution (if supported), 1280x720 if not. For best results,
use a size supported by the AVC encoder.
--bit-rate RATE
Set the video bit rate, in bits per second. Value may be specified as
bits or megabits, e.g. '4000000' is equivalent to '4M'. Default 20Mbps.
--bugreport
Add additional information, such as a timestamp overlay, that is helpful
in videos captured to illustrate bugs.
--time-limit TIME
Set the maximum recording time, in seconds. Default / maximum is 180.
--verbose
Display interesting information on stdout.
adb shell screencap
adb shell screencap -d 0 /sdcard/test.png
Take a screenshot on Android
adb shell pull /sdcard/test.png
Download test.png file from Android Device.
adb shell screencap -d 0 /sdcard/test.png
Take a screenshot on Android
adb shell pull /sdcard/test.png
Download test.png file from Android Device.
adb shell mount
adb shell mount
Mount new filesystem(s) on directories. With no arguments, display existing mounts.
mount [-afFrsvw] [-t TYPE] [-o OPTION,] [[DEVICE] DIR]
-a mount all entries in /etc/fstab (with -t, only entries of that TYPE)
-O only mount -a entries that have this option
-f fake it (don't actually mount)
-r read only (same as -o ro)
-w read/write (default, same as -o rw)
-t specify filesystem type
-v verbose
OPTIONS is a comma separated list of options, which can also be supplied as --longopts.
This mount autodetects loopback mounts (a file on a directory) and bind mounts (file on file, directory on directory), so you don't need to say --bind or --loop. You can also "mount -a /path" to mount everything in /etc/fstab under /path, even if it's noauto
adb shell mount
Mount new filesystem(s) on directories. With no arguments, display existing mounts.
mount [-afFrsvw] [-t TYPE] [-o OPTION,] [[DEVICE] DIR]
-a mount all entries in /etc/fstab (with -t, only entries of that TYPE)
-O only mount -a entries that have this option
-f fake it (don't actually mount)
-r read only (same as -o ro)
-w read/write (default, same as -o rw)
-t specify filesystem type
-v verbose
OPTIONS is a comma separated list of options, which can also be supplied as --longopts.
This mount autodetects loopback mounts (a file on a directory) and bind mounts (file on file, directory on directory), so you don't need to say --bind or --loop. You can also "mount -a /path" to mount everything in /etc/fstab under /path, even if it's noauto
adb shell date
adb shell date
Get the current datetime
adb shell date
Get the current datetime
adb shell netstat
adb shell netstat
Display networking information. Default is netsat -tuwx
-r routing table
-a all sockets (not just connected)
-l listening server sockets
-t TCP sockets
-u UDP sockets
-w raw sockets
-x unix sockets
-e extended info
-n don't resolve names
-W wide display
-p PID/Program name of sockets
adb shell netstat
Display networking information. Default is netsat -tuwx
-r routing table
-a all sockets (not just connected)
-l listening server sockets
-t TCP sockets
-u UDP sockets
-w raw sockets
-x unix sockets
-e extended info
-n don't resolve names
-W wide display
-p PID/Program name of sockets
adb shell ps
adb shell ps
List processes running in the android
Which processes to show (selections may be comma separated lists):
-A All processes
-a Processes with terminals that aren't session leaders
-d All processes that aren't session leaders
-e Same as -A
-g Belonging to GROUPs
-G Belonging to real GROUPs (before sgid)
-p PIDs (--pid)
-P Parent PIDs (--ppid)
-s In session IDs
-t Attached to selected TTYs
-T Show threads
-u Owned by USERs
-U Owned by real USERs (before suid)
Output modifiers:
-k Sort FIELDs in +increasing or -decreasting order (--sort)
-M Measure field widths (expanding as necessary)
-n Show numeric USER and GROUP
-w Wide output (don't truncate fields)
adb shell ps
List processes running in the android
Which processes to show (selections may be comma separated lists):
-A All processes
-a Processes with terminals that aren't session leaders
-d All processes that aren't session leaders
-e Same as -A
-g Belonging to GROUPs
-G Belonging to real GROUPs (before sgid)
-p PIDs (--pid)
-P Parent PIDs (--ppid)
-s In session IDs
-t Attached to selected TTYs
-T Show threads
-u Owned by USERs
-U Owned by real USERs (before suid)
Output modifiers:
-k Sort FIELDs in +increasing or -decreasting order (--sort)
-M Measure field widths (expanding as necessary)
-n Show numeric USER and GROUP
-w Wide output (don't truncate fields)
adb install
adb install test.apk
app installation
install [-lrtsdg] [--instant] <PACKAGE-NAME>
install-multiple [-lrtsdpg] [--instant] PACKAGE...push package(s) to the device and install them
-l: forward lock application
-r: replace existing application
-t: allow test packages
-s: install application on sdcard
-d: allow version code downgrade (debuggable packages only)
-p: partial application install (install-multiple only)
-g: grant all runtime permissions
--instant: cause the app to be installed as an ephemeral install app
adb install test.apk
app installation
install [-lrtsdg] [--instant] <PACKAGE-NAME>
install-multiple [-lrtsdpg] [--instant] PACKAGE...push package(s) to the device and install them
-l: forward lock application
-r: replace existing application
-t: allow test packages
-s: install application on sdcard
-d: allow version code downgrade (debuggable packages only)
-p: partial application install (install-multiple only)
-g: grant all runtime permissions
--instant: cause the app to be installed as an ephemeral install app
adb uninstall
adb uninstall <PACKAGE-NAME>
remove this app package from the device
adb uninstall <PACKAGE-NAME>
remove this app package from the device
adb root
adb root
restart adbd with root permissions
adb unroot
restart adbd without root permissions
-k: keep the data and cache directories
adb root
restart adbd with root permissions
adb unroot
restart adbd without root permissions
-k: keep the data and cache directories
adb pull
adb pull /sdcard/test.png
copy files/dirs from device
-a: preserve file timestamp and mode
adb pull /sdcard/test.png
copy files/dirs from device
-a: preserve file timestamp and mode
adb push
adb push test.png /sdcard/test.png
copy local files/directories to device
--sync: only push files that are newer on the host than the device
adb push test.png /sdcard/test.png
copy local files/directories to device
--sync: only push files that are newer on the host than the device
adb shell am
adb shell am
Activity manager (activity) commands
adb shell am start -n com.android.vending/com.google.android.finsky.activities.MainActivity
Launch Google Play Store
adb shell am
Activity manager (activity) commands
adb shell am start -n com.android.vending/com.google.android.finsky.activities.MainActivity
Launch Google Play Store
adb shell ping
adb shell ping www.yahoo.com
pings www.yahoo.com
adb shell ping www.yahoo.com
pings www.yahoo.com
adb shell ls
adb shell ls
list directory contents
adb shell ls -s
print size of each file
adb shell ls -R
list subdirectories recursively
Other Generic Commands commonly used:
adb reboot-recovery (reboot device into recovery mode)
adb reboot fastboot (reboot device into fastboot mode)
adb reboot bootloader - Reboots the device to the bootloader
adb shell screencap -p "/path/to/screenshot.png" (capture screenshot)
adb shell screenrecord "/path/to/record.mp4" (record device screen)
adb backup -apk -all -f backup.ab (backup settings and apps)
adb backup -apk -shared -all -f backup.ab (backup settings, apps and shared storage)
adb backup -apk -nosystem -all -f backup.ab (backup only non-system apps)
adb restore backup.ab (restore a previous backup)
adb shell am start|startservice|broadcast <INTENT>[<COMPONENT>]
-a <ACTION> e.g. android.intent.action.VIEW
-c <CATEGORY> e.g. android.intent.category.LAUNCHER (start activity intent)
adb shell am start -a android.intent.action.VIEW -d URL (open URL)
adb shell am start -t image/* -a android.intent.action.VIEW (opens gallery)
adb shell permissions groups (list permission groups definitions)
adb shell list permissions -g -r (list permissions details)
adb shell ip -o a - To get list of all IP Address
adb shell ip addr show wlan0 -
adb shell "svc data disable" - Disables the Mobile Data
adb shell "svc data enable" - Enables the Mobile Data
adb shell ip addr show wlan0 - Shows Wlan0 IP config.
Output:
11: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether aa:84:17:9c:df:1b brd ff:ff:ff:ff:ff:ff
inet 192.168.0.27/24 brd 192.168.0.255 scope global wlan0
valid_lft forever preferred_lft forever
inet6 fe80::a884:17ff:fe9c:df1b/64 scope link
valid_lft forever preferred_lft forever
adb shell getevents (tool runs on the device and provides information about input devices and a live dump of kernel input events)
Other Generic Commands commonly used:
adb reboot-recovery (reboot device into recovery mode)
adb reboot fastboot (reboot device into fastboot mode)
adb reboot bootloader - Reboots the device to the bootloader
adb shell screencap -p "/path/to/screenshot.png" (capture screenshot)
adb shell screenrecord "/path/to/record.mp4" (record device screen)
adb backup -apk -all -f backup.ab (backup settings and apps)
adb backup -apk -shared -all -f backup.ab (backup settings, apps and shared storage)
adb backup -apk -nosystem -all -f backup.ab (backup only non-system apps)
adb restore backup.ab (restore a previous backup)
adb shell am start|startservice|broadcast <INTENT>[<COMPONENT>]
-a <ACTION> e.g. android.intent.action.VIEW
-c <CATEGORY> e.g. android.intent.category.LAUNCHER (start activity intent)
adb shell am start -a android.intent.action.VIEW -d URL (open URL)
adb shell am start -t image/* -a android.intent.action.VIEW (opens gallery)
adb shell permissions groups (list permission groups definitions)
adb shell list permissions -g -r (list permissions details)
adb shell ip -o a - To get list of all IP Address
adb shell ip addr show wlan0 -
adb shell "svc data disable" - Disables the Mobile Data
adb shell "svc data enable" - Enables the Mobile Data
adb shell ip addr show wlan0 - Shows Wlan0 IP config.
Output:
11: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether aa:84:17:9c:df:1b brd ff:ff:ff:ff:ff:ff
inet 192.168.0.27/24 brd 192.168.0.255 scope global wlan0
valid_lft forever preferred_lft forever
inet6 fe80::a884:17ff:fe9c:df1b/64 scope link
valid_lft forever preferred_lft forever
adb shell getevents (tool runs on the device and provides information about input devices and a live dump of kernel input events)