2010年4月20日 星期二

HTC Tattoo 取得root權限方法 in Windows

工具檔案:TattooRoot.zip

1. 將 Tattoo 以 HTC Sync 連線類型連接電腦

2. 將 TattooRoot.zip 解壓在 C: 中

3. 開啟命令提示字元並執行
cd \
install-tattoo-root
會顯示
C:\>install-tattoo-root
--------------------------------------------------
Creating /data/local/bin (it's ok to get an error)
adb server is out of date.  killing...
* daemon started successfully *
293 KB/s (4695 bytes in 0.015s)
164 KB/s (356916 bytes in 2.125s)
--------------------------------------------------

4. 執行
adb shell
會顯示
$

5. 執行
while 'true' ; do /data/local/bin/m7; done
順利的話會顯示
#
例外情況會顯示
usage: reboot [-n] [-p] [rebootcommand]
這時候請耐心稍等一會直到顯示
Wrote shellcode e0400000 line 0
Wrote shellcode e3a07023 line 1
Wrote shellcode ef000000 line 2
Wrote shellcode e0400000 line 3
Wrote shellcode e3a07017 line 4
Wrote shellcode ef000000 line 5
Wrote shellcode e0433003 line 6
Wrote shellcode e28f0014 line 7
Wrote shellcode e50d0008 line 8
Wrote shellcode e50d3004 line 9
Wrote shellcode e24d1008 line 10
Wrote shellcode e24d2004 line 11
Wrote shellcode e3a0700b line 12
Wrote shellcode ef000000 line 13
Wrote shellcode 7379732f line 14
Wrote shellcode 2f6d6574 line 15
Wrote shellcode 2f6e6962 line 16
Wrote shellcode 6873 line 17
Wrote shellcode 0 line 18
[ Overwritten 0xb0000100
# usage: reboot [-n] [-p] [rebootcommand]
usage: reboot [-n] [-p] [rebootcommand]
usage: reboot [-n] [-p] [rebootcommand]
usage: reboot [-n] [-p] [rebootcommand]
這時再按 Enter 就會顯示
#

6. 此時執行 id 會顯示
id: not found
為正常現象請跟著繼續執行
export LD_LIBRARY_PATH=/system/lib
export PATH=/system/bin
然後執行 id 會顯示
uid=0(root) gid=2000(shell) groups=1003(graphics),1004(input),1007(log),1011(adb),1015(sdcard_rw),3001(net_bt_admin),3002(net_bt),3003(inet)
這裡請注意紅字部份有看到 root 就表示成功了
以下步驟非必要請自行斟酌操作
7. 請接着執行
chmod 755 /data/local/bin/su
chown root.root /data/local/bin/su
chmod 4755 /data/local/bin/su
mount -o rw,remount /dev/block/mtdblock5 /data
mount -o rw,remount /dev/block/mtdblock3 /system
然後請按 ctrl + c 退回 dos

8. 執行
adb shell
顯示
$
再執行
/data/local/bin/su
顯示
#
就完成所有操作與設定 Tattoo

注意:上述步驟成功後重開機執行 /data/local/bin/su 會發生無法取得 root 的情況,需要重頭 run 一遍。

Link from http://www.wretch.cc/blog/nidgetgod/7851229

How to use simple speedtest in RaspberryPi CLI

  pi@ChunchaiRPI2:/tmp $  wget -O speedtest-cli https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py --2023-06-26 10:4...