lg v20 刷twrp

1. re-boot into fastboot mode
2. flash twrp use fastboot command.
3. power-off the phone
4. power-on with power and volume down button holding
5. while lg log appears, release power button immediately for 1 second and then hold again
6. when recovery selection screen appears, select ‘yes’ both two times.
now phone boot to twrp recovery.

REMEMBER: WHEN YOU BOOT INTO LG’S SYSTEM AGAIN, YOU WILL LOST TWRP. IF U WANT TO USE TWRP AGAIN, U MUST RE-FLASH TWRP AND REPEAT THE STEPS ABOVE.

THIS WILL LOST ALL DATA(PHONE WILL GET FACTORY RECOVERED)!!

 

Quote:

Originally Posted by mking007cn 

here is a new problem, each time i start a normal boot, i will lost twrp again. anyone can tell me how to solve this, thank you
You need to delete the file recovery-from-boot.p in /system

Each time you boot, that file gets executed and restores the stock recovery from recoverybak. Alternatively, you can flash TWRP to both recovery and recoverybak.

-- Brian

为 netgear wndr4300 编译 lede(原创)

 

使用 image builder 快速构建

0.下载image builder

wget http://mirrors.ustc.edu.cn/lede/releases/17.01.4/targets/ar71xx/nand/lede-imagebuilder-17.01.4-ar71xx-nand.Linux-x86_64.tar.xz

1.修改源为中科大的mirror

将repositories.conf修改如下

## Place your custom repositories here, they must match the architecture and version.
# src/gz reboot http://mirrors.ustc.edu.cn/lede/releases/17.01.4
# src custom file:///usr/src/lede/bin/ar71xx/packages

## Remote package repositories
src/gz reboot_core http://mirrors.ustc.edu.cn/lede/releases/17.01.4/targets/ar71xx/nand/packages
src/gz reboot_base http://mirrors.ustc.edu.cn/lede/releases/17.01.4/packages/mips_24kc/base
src/gz reboot_luci http://mirrors.ustc.edu.cn/lede/releases/17.01.4/packages/mips_24kc/luci
src/gz reboot_packages http://mirrors.ustc.edu.cn/lede/releases/17.01.4/packages/mips_24kc/packages
src/gz reboot_routing http://mirrors.ustc.edu.cn/lede/releases/17.01.4/packages/mips_24kc/routing
src/gz reboot_telephony http://mirrors.ustc.edu.cn/lede/releases/17.01.4/packages/mips_24kc/telephony

This is the local package repository, do not remove!
src imagebuilder file:packages

2.扩展128m分区

17.04

sed -i s/'23552k(ubi),25600k@0x6c0000(firmware)'/'120832k(ubi),122880k@0x6c0000(firmware)'/ target/linux/ar71xx/image/legacy.mk

18.06+  patch

patch:
--- trunk/target/linux/ar71xx/image/legacy.mk 2017-01-13 10:48:39.549787945 +0000
+++ trunk-ipvs/target/linux/ar71xx/image/legacy.mk 2016-12-27 21:32:11.480977031 +0000
@@ -199,7 +199,7 @@
LZMA_TEXT_START=0x80a00000 LOADADDR=0x80060000 \
LOADER_DATA="$(KDIR)/vmlinux$(5).bin.lzma" BOARD="$(1)" \
compile loader.$(2)
- -$(if $(5),$(CP) $(KDIR)/loader-$(1).$(2) $(KDIR)/loader-$(1)$(5).$(2))
+ -$(CP) $(KDIR)/loader-$(1).$(2) $(KDIR)/loader-$(1)$(5).$(2)
endef

#
@@ -281,7 +281,7 @@
wnr2000v4_mtdlayout=mtdparts=spi0.0:192k(u-boot)ro,64k(u-boot-env)ro,3776k(firmware),64k(art)ro
r6100_mtdlayout=mtdparts=ar934x-nfc:128k(u-boot)ro,256k(caldata)ro,256k(caldata-backup),512k(config),512k(pot),2048k(kernel),122240k(ubi),25600k@0x1a0000(firmware),2048k(language),3072k(traffic_meter)
tew823dru_mtdlayout=mtdparts=spi0.0:192k(u-boot)ro,64k(nvram)ro,15296k(firmware),192k(lang)ro,512k(my-dlink)ro,64k(mac)ro,64k(art)ro
-wndr4300_mtdlayout=mtdparts=ar934x-nfc:256k(u-boot)ro,256k(u-boot-env)ro,256k(caldata)ro,512k(pot),2048k(language),512k(config),3072k(traffic_meter),2048k(kernel),23552k(ubi),25600k@0x6c0000(firmware),256k(caldata_backup),-(reserved)
+wndr4300_mtdlayout=mtdparts=ar934x-nfc:256k(u-boot)ro,256k(u-boot-env)ro,256k(caldata),512k(pot),2048k(language),512k(config),3072k(traffic_meter),2048k(kernel),121856k(ubi),123904k@0x6c0000(firmware),256k(caldata_backup),-(reserved)
zcn1523h_mtdlayout=mtdparts=spi0.0:256k(u-boot)ro,64k(u-boot-env)ro,6208k(rootfs),1472k(kernel),64k(configure)ro,64k(mfg)ro,64k(art)ro,7680k@0x50000(firmware)
mynet_rext_mtdlayout=mtdparts=spi0.0:256k(u-boot)ro,7808k(firmware),64k(nvram)ro,64k(ART)ro
zyx_nbg6716_mtdlayout=mtdparts=spi0.0:256k(u-boot)ro,64k(env)ro,64k(RFdata)ro,-(nbu);ar934x-nfc:2048k(zyxel_rfsd),2048k(romd),1024k(header),2048k(kernel),-(ubi)

 

3.编译

make image PROFILE="WNDR4300V1" PACKAGES="wget ca-bundle ca-certificates iptables-mod-tproxy ip luci-app-samba block-mount kmod-usb-storage-extras kmod-fs-ntfs kmod-fs-vfat kmod-fs-exfat ip kmod-ip6tables ip6tables luci-proto-ipv6 odhcp6c ip6tables luci-ssl openssh-server openssh-sftp-server libssh2"

参考来源:https://simonsmh.cc/2016/03/为wndr4300编译openwrt/

准备工作

  1. sudo apt-get install subversion build-essential libncurses5-dev zlib1g-dev gawk git ccache gettext libssl-dev xsltproc
  2. cd
  3. git clone git://git.openwrt.org/15.05/openwrt.git
  4. cd openwrt

源代码同步构建 (out of dated)

  1. git pull
  2. #git checkout 15.05.01 #检查15.05.01稳定分支
  3. ./scripts/feeds update -a
  4. ./scripts/feeds install luci
  5. wget https://downloads.openwrt.org/chaos_calmer/15.05.01/ar71xx/nand/config.diff
  6. sed -i s/'CONFIG_TARGET_ar71xx_nand_R6100=y'/'CONFIG_TARGET_ar71xx_nand_WNDR4300=y'/ config.diff
  7. sed -i s/'23552k(ubi),25600k@0x6c0000(firmware)'/'120832k(ubi),122880k@0x6c0000(firmware)'/ target/linux/ar71xx/image/Makefile
  8. cat config.diff >> .config
  9. make defconfig
  10. make -j #多线程

使用 openwrt image builder 快速构建

  1. wget https://downloads.lede-project.org/releases/17.01.2/targets/ar71xx/nand/lede-imagebuilder-17.01.2-ar71xx-nand.Linux-x86_64.tar.xz
  2. tar -xf lede-imagebuilder-17.01.2-ar71xx-nand.Linux-x86_64.tar.xz
  3. cd lede-imagebuilder-17.01.2-ar71xx-nand.Linux-x86_64
  4. make info #查看默认软件包和硬件支持列表
  5. sed -i s/'23552k(ubi),25600k@0x6c0000(firmware)'/'120832k(ubi),122880k@0x6c0000(firmware)'/ target/linux/ar71xx/image/legacy.mk
  6. make image PROFILE="WNDR4300V1" -j #指定机型+多线程

常用软件包

  1. opkg install wget ca-bundle ca-certificates luci-i18n-base-file-zh-cn luci-i18n-firewall-zh-cn iptables-mod-tproxy ip shadowsocks-libev luci-app-shadowsocks ChinaDNS luci-app-chinadns pdnsd luci-app-pdnsd luci-app-samba luci-i18n-samba-zh-cn block-mount kmod-usb-storage-extras kmod-fs-ntfs kmod-fs-vfat kmod-fs-exfat

This blog is under a CC BY-NC-SA 3.0 Unported License 
本文链接:https://simonsmh.cc/2016/03/为wndr4300编译openwrt/

LiveUpdate 更新受阻的解决方案

一、选取可用 IP 地址。
使用 PING 测试下列三组 IP,各选出一个可连通且延迟最低的 IP.

  1. liveupdate.symantec.com
  2. 152.195.12.135
  3. 152.195.132.120
  4. 152.195.38.43

复制代码

  1. liveupdate.symantecliveupdate.com
  2. 152.195.12.171
  3. 152.195.132.156
  4. 152.195.38.63

复制代码

  1. update.symantec.com
  2. 165.254.106.202
  3. 165.254.106.196
  4. 165.254.106.226
  5. 165.254.106.208
  6. 69.192.2.38
  7. 124.40.41.156
  8. 69.192.2.35
  9. 69.192.2.34
  10. 69.192.2.37
  11. 69.192.2.36
  12. 124.40.41.235
  13. 124.40.41.146
  14. 124.40.41.236
  15. 69.192.2.39
  16. 69.192.2.39
  17. 69.192.2.35
  18. 104.94.101.45
  19. 104.94.101.44
  20. 104.94.101.48
  21. 104.94.101.49
  22. 104.94.101.46

复制代码

二、添加至 HOSTS 文件。
将上一步选取的三个 IP 地址添加至 HOSTS 文件。方法不再赘述。
提供一个模板如下:

  1. # Symantec LiveUpdate IP Address
  2. 152.195.132.120 liveupdate.symantec.com
  3. 152.195.12.171  liveupdate.symantecliveupdate.com
  4. 69.192.2.39     update.symantec.com

复制代码

三、刷新本地 DNS 缓存。
管理员权限运行命令:

  1. ipconfig /flushDNS

复制代码

四、已知问题。

  • 重定向 Norton 更新域名后,Norton 可能会报 SecurityRisk.URLRedir