slug
antic
summary
总有一些逆天的应用和工具因为滥用被屏蔽:Google翻译、github、deepl等等。优质的服务体验和高度依赖无法割舍怎么办?想办法找回来呀!
无法使用github解决方案
1、找到hosts 文件
hosts 文件在每个系统的位置不一,详情如下:Windows 系统:C:\Windows\System32\drivers\etc\hostsLinux 系统:/etc/hostsMac(苹果电脑)系统:/etc/hostsAndroid(安卓)系统:/system/etc/hostsiPhone(iOS)系统:/etc/hosts
2、打开hosts文件
Windows 使用记事本(padnote++)。Linux、Mac 使用 Root 权限:sudo vi /etc/hostsiPhone、iPad 须越狱、Android 必须要 root
3、复制下面代码的内容到设备的hosts文件末尾
20.205.243.166 www.github.com 20.205.243.166 github.com ## ctl+s保存
4、大部分情况下是直接生效,如未生效可尝试下面的办法,刷新 DNS:
Windows:在 CMD 窗口(
win+r
然后输入cmd
回车)输入:ipconfig /flushdns
Linux 命令:
sudo rcnscd restar
tMac 命令:
sudo killall -HUP mDNSResponder
Tips: 上述方法无效可以尝试重启机器。
无法使用Google翻译解决方案
查找可用服务器地址
按
Win + R
键打开运行 → 输入 cmd 回车,打开命令提示符 → 输入 ping google.cn
回车。记录下这个【目标IP】(一串数字,类似 192.168.123.123 格式),下面要用到。
正在 Ping google.cn [180.163.150.34] 具有 32 字节的数据: 来自 180.163.150.34 的回复: 字节=32 时间=30ms TTL=119 来自 180.163.150.34 的回复: 字节=32 时间=31ms TTL=119 来自 180.163.150.34 的回复: 字节=32 时间=30ms TTL=119 来自 180.163.150.34 的回复: 字节=32 时间=35ms TTL=119 180.163.150.34 的 Ping 统计信息: 数据包: 已发送 = 4,已接收 = 4,丢失 = 0 (0% 丢失), 往返行程的估计时间(以毫秒为单位): 最短 = 30ms,最长 = 35ms,平均 = 31ms
修改 hosts 文档
hosts 文档地址:
- Windows:
C:\Windows\System32\drivers\etc
- Mac:
/etc
- Linux:
/etc
在最末尾添加如下文本,保存。
目标IP translate.googleapis.com
刷新 DNS 解析缓存
Windows:在 CMD 窗口(
win+r
然后输入cmd
回车)输入:ipconfig /flushdns
无法使用DeepL翻译
这个最简单直接,将你的Windows位置信息改成
香港
就好了。设置⇒时间和语言⇒区域

win7/10卡在配置windows update
想彻底关闭Win10自动更新,可以在Windows服务中找到Windows Update选项将其设置为禁用即可。您可以按照以下步骤进行操作。
- 按“
Windows + R
”键,打开运行对话框,并输入“services.msc
”,然后再单击“enter
”。
- 在弹出的服务窗口中,按
W
找到“Windows Update
”选项并双击打开它。
- 在弹出的“Windows Update的
属性
”对话框中,将“启动类型
”设置为“禁用
”。
- 然后再单击“
恢复
”,将图中框选的部分都设置为“无操作
”,再单击“应用
”和“确定
”。

安卓手机充当软路由
相关代码文档信息
安卓shell
电脑使用adb
- 下载地址:
Windows版本:https://dl.google.com/android/repository/platform-tools-latest-windows.zipMac版本:https://dl.google.com/android/repository/platform-tools-latest-darwin.zipLinux版本:https://dl.google.com/android/repository/platform-tools-latest-linux.zip
- 使用方式:
需开启“Android调试”,在「设置」-「开发者选项」-「Android 调试」,如果找不到“开发者选项”,需要在「设置」-「关于手机」连续点击「版本号」7 次
查看设备:
adb devices
无线连接:
adb connect 192.168.0.111
无线连接需要开启网络ADB调试
进入shell:
adb shell
上传文件到手机:
adb push 电脑路径 手机路径
下载文件到电脑:
adb pull 手机路径 电脑路径
安装APK:
adb install APK路径
手机使用Termux
- 下载地址:
- 使用方式:(略)
配置旁路网关
建议先将手机设置为固定IP,方式很多请自行Google
一键脚本
#!/system/bin/sh tun='tun0' #虚拟接口名称 dev='wlan0' #物理接口名称,eth0、wlan0 interval=3 #检测网络状态间隔(秒) pref=18000 #路由策略优先级 # 开启IP转发功能 sysctl -w net.ipv4.ip_forward=1 # 清除filter表转发链规则 iptables -F FORWARD # 添加NAT转换,部分VPN需要此设置 iptables -t nat -A tetherctrl_nat_POSTROUTING -o $tun -j MASQUERADE # 添加路由策略 ip rule add from all table main pref $pref ip rule add from all iif $dev table $tun pref $(expr $pref - 1) contain="from all iif $dev lookup $tun" while true ;do if [[ $(ip rule) != *$contain* ]]; then if [[ $(ip ad|awk '/state UP/ {print $2}') != *$dev* ]]; then echo -e "[$(date "+%H:%M:%S")]dev has been lost." else ip rule add from all iif $dev table $tun pref $(expr $pref - 1) echo -e "[$(date "+%H:%M:%S")]network changed, reset the routing policy." fi fi sleep $interval done
赋予可执行权限:
chmod +x proxy.sh
执行:
nohup ./proxy.sh &
更改网关
全局设备更改:修改主路由的DHCP设置
单一设备更改:更改设备的网关
排错
安卓系统每次切换网络设置都会将部分设置重置,一些“永久生效”的配置方式在手机重启后也会被重置
检查IP转发功能是否启用:
cat /proc/sys/net/ipv4/ip_forward
检查iptables是否允许数据包通过:
iptables -nvL -t (filter|nat|mangle)
检查路由策略:
ip rule
检查网卡接口:
ip a
Google Cloud Shell创建固定IP的RDP远程桌面
docker run -p 8080:80 dorowu/ubuntu-desktop-lxde-vnc
vscode出现错误代码
Git:fatal:unable to access 'https://github.com/***/d**.git/:OpenSSL SSL_read: Connection was reset,errno 10054
- 需要配置github代理

如何查看电脑的代理

下面是三种具体的方法
- vscode
设置里面搜索proxy
http里面输入 http://127.0.0.1:10809
- git软件
git config --global --edit
文本内输入
[http] proxy = http://127.0.0.1:10809 [https] proxy = http://127.0.0.1:10809 [credential] helper = store
- git命令
git config --global http.proxy 'http://127.0.0.1:10809' git config --global https.proxy 'http://127.0.0.1:10809'
- Author:开户通
- URL:https://fx.ssgg.net/antic
- Copyright:All articles in this blog, except for special statements, adopt BY-NC-SA agreement. Please indicate the source!