snippetbashTip
adb forward — Forward socket connections to a connected Android device or emulator. More information: <https://dev
Viewed 0 times
connectedcommandsocketcliforwardadb forwardandroidconnections
Problem
How to use the
adb forward command: Forward socket connections to a connected Android device or emulator. More information: <https://developer.android.com/tools/adb>.Solution
adb forward — Forward socket connections to a connected Android device or emulator. More information: <https://developer.android.com/tools/adb>.Forward a TCP port to the only connected emulator or device:
adb forward tcp:{{local_port}} tcp:{{remote_port}}Forward a TCP port to a specific emulator or device (by device ID / [s]erial number):
adb -s {{device_ID}} forward tcp:{{local_port}} tcp:{{remote_port}}List all forwardings:
adb forward --listRemove a forwarding rule:
adb forward --remove tcp:{{local_port}}Remove all forwarding rules:
adb forward --remove-allCode Snippets
Forward a TCP port to the only connected emulator or device
adb forward tcp:{{local_port}} tcp:{{remote_port}}Forward a TCP port to a specific emulator or device (by device ID / [s]erial number)
adb -s {{device_ID}} forward tcp:{{local_port}} tcp:{{remote_port}}List all forwardings
adb forward --listRemove a forwarding rule
adb forward --remove tcp:{{local_port}}Remove all forwarding rules
adb forward --remove-allContext
tldr-pages: common/adb forward
Revisions (0)
No revisions yet.