Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save Alistair1231/6c2f1b5f57ea35fef3246c365fced42f to your computer and use it in GitHub Desktop.
Save Alistair1231/6c2f1b5f57ea35fef3246c365fced42f to your computer and use it in GitHub Desktop.
set tcpip port in build props on read only /system
#################
# in 1st terminal
#################
# enable usb debugging and root debugging, if no root debugging available, root device with e.g. magisk, after change remove root again
adb root
adb shell
# look at `mount` and find the read only system partition
mount -o rw,remount /
# or
# mount -o rw,remount /system

#################
# in 2nd terminal
#################
adb pull /system/build.prop

# edit build.prop (add line) e.g. with bash and tee
tee -a build.prop <<EOF
service.adb.tcp.port=5555
EOF

adb push build.prop /system/build.prop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment