Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am serianox on github.
  • I am serianox (https://keybase.io/serianox) on keybase.
  • I have a public key whose fingerprint is 7182 DF9D 3B5E 1355 2BBC E4D9 9FE8 9D94 949E DC25

To claim this, I am signing this object:

@serianox
serianox / install-change-dns.sh
Last active August 28, 2022 00:48
Very basic script for Android to set Google public DNS instead of mobile operator DNS
#!/bin/sh
# create a small script /sdcard/change-dns.sh that configures Google public DNS (requires to be run as root)
adb shell "echo \"#\0041/system/xbin/bash\" > /sdcard/change-dns.sh"
adb shell "echo \"su\" >> /sdcard/change-dns.sh"
adb shell "echo \"setprop net.dns1 8.8.8.8\" >> /sdcard/change-dns.sh"
adb shell "echo \"setprop net.dns2 8.8.4.4\" >> /sdcard/change-dns.sh"
adb shell "echo \"setprop net.rmnet0.dns1 8.8.8.8\" >> /sdcard/change-dns.sh"
adb shell "echo \"setprop net.rmnet0.dns2 8.8.4.4\" >> /sdcard/change-dns.sh"