Bro, I can't describe how awesome I feel after watching your tutorial. This router gave me so much headache and consumed so much of my time. It was well worth throwing it away and buying a new one. But I'm one of those people who want to try everything they can before they do so. And man, your instructions were spot on you helped me do exactly that - fix something that others would've given up on within the first 5 minutes. THANK YOU from the bottom of my soul.
Followed your guidelines, device flashed orange forever, realized I had bricked it ,realized my model was not English but Intl 😢, debricked the device using your video and after trying again it worked🎉 thanks a lot👌
Worked like a charm. I used Ubuntu desktop directly so I didn't need the VirtualBox part. Also, I used ftp command from Ubuntu bash shell to copy the bin file from local to the 4C router. The rest is exactly the same. Many many thanks to Hoddy!
I just came back to your original video and am so glad that you posted this update...i brought my xiaomi r4ag all the way back to new york from istanbul JUST to try your instructions and now months later (and I think maybe three years after I bought it) and im finally getting to it because my grandmother needs a router so she doesnt have to keep funding those criminal ISPs with her extra $5/month haha thanks a ton!!!!!
Thank you! I recommend LTS generally because it's less bleeding edge and has better compatibility generally but obviously, that wasn't what you found with it so sorry about that, glad you got it working though!
Thanks, debricking Chinese 4A GIG was success to me, but I have to make additional reboot: After transferring the firmware with a tool the 1st LED start blinking blue colour constantly, but the router didn't reacted on connections. I've to reboot the router and that helped.
Thank you so much for this great explanation, I didn't run into any issues except for running the openwrt commands, which I had to run through python venv, otherwise everything else went perfectly thanks to your amazing in depth easy to follow guide.
THANK YOU VERY MUCH ❤️. Finally made it (after 3 months and so many useless tutorials on TH-cam) through your video . Many thanks for your time making a great tutorial ❤️
Hi friend, I'm really counting on your help, because I've had a really bad accident. After installing OpenWrt through the console, my mi 4ac went to reboot, but it didn't reboot even after 20 minutes. The red light on the router started to light up constantly and the router does not respond to the reset key. When I connect it to a port and try to use the Debrick tool, I get the following result: DHCPc:no other DHCPd discovered. I really hope you will help me UPDATE: It was probably my mistake in unscrewing it, but after a few months I managed to do it very easily. The author is a genius, deserves millions of subscribers
Thank you very much. I followed your instruction and I successfully installed openwrt on my Xiaomi R4a version 2.28.8 chinese version. Subscribe automatically to your channel.
congratulations for the excellent video, I thought I had lost my router because I put a global firmware, and its version is Chinese, thank you very much for this excellent video.👌🙌👏
Thank you very much for this vídeo... O seen a lot off videos and consult a lot of sites about this theme and never was able to concludes openwrt installation in my 4c. Finally, with your help, I easly install it. Thank you for your great job
if the LED in the router flashes white light is a sign that you are holding the reset button too short. you need to hold it while turning on tiny pxe for a while.
Thank you su much for this video !! Long time I was looking to update my Mii router firmware to something more "serious"... Just in case, for someone else benefit, I fisrt get error when using the exploit, I factory reset my router & then was able to use the exploit & flash with OpenWRT without any issue.
Best video on the topic and trust me, I have seen over 30 of them before finally attempting this. There were some issues with the latest version of VirtualBox unfortunately, but nothing too complicated to handle. By the way, I (And probably many others as well) would REALLY appreciate it if you made a video about the ideal settings we should select on OpenWRT to get the maximum out of the Mi router 4A; like more range (if possible). Keep up the good work.
Hello, thank you for your guide. Nicely explained. Unfortunately, the debrick tools link in the descriptions won't open. Are there any alternative links?
Thank you very much for the instruction. I wanna take the installation even further by installing vr2ay client on top of OpenWrt. While reading through the comment section, you had mentioned that the space within the router is insufficient to install the vr2ay client. Can I please know how much space is required to install vr2ay client on top of OpenWrt and this can be done on the Xiaomi Mi Router 4A Gigabit Edition?
I dont remember saying that, im not sure how big that is but no doubt if there isnt enough space you could remove some of the default software if you arent ever going to use it. Package sizes and info about how much space your route has can all be found on the openwrt website.
Firstly, thank you for this amazing guide! I am using my router as repeater right now. For installing openwrt, should i connect it to my desktop via cable? Will this be enough to get an IP? Or shall i convert it into another mode?
Thanks for the detailed tutorial! However, I've faced some issues. First, I coudn't get a root access it might be due to firmware version. Secondly, I couldn't get recovery mode -( I thought what if change stock firmware via recovery mode to another version which is ok for openwrt but when I press reset button firmware is writing to memory and led is starting to blink without any thinking. After reboot I still get a stock firmware. No change! I've tried all of the firmwares and tools (tinypxe and miwifi repair tool) process finishes too fast. My router MI 4A gigabit (chinese) Thank you
@alexcool8980 likely not accepting the firmware version, try looking for other versions, i know the openwrt github hosts some and there's a few knocking about in the openwrt forums. Just replace the test.bin file with the other fw (ensure to rename it test.bin)
thanks a lot! I succesfully debrick my device following your instructions. However, I'm linux Ubuntu user, I needed to move to my windows computer to do this. Wish there is a linux based tutorial to debrick.
Not too much difference you just need to setup any tftp server, unfortunately for any novice watching the video it would be really difficult for me to explain but if you have a decent amount of linux background setting up a tftp server is probably quite trivial so try that
Hi, thanks for this great video. After installing the virtual box and clicking on Finish, the powering vm ... starts loading that black box for inputting the commands, which appears for a second and then disappears. Then, on the right corner, it gives this error: "Not in a hypervisor partition (HVP=0) (VERR_NEM_NOT_AVAILABLE). VT-x is disabled in the BIOS for all CPU modes (VERR_VMX_MSR_ALL_VMX_DISABLED)", What should I do? How can I solve this problem, please? Thanks a lot.
Ah, for that you need to switch on a setting in your bios to allow vms or your pc, if you google you motherboard model and enable virtualisaton you should find some info on how to turn that on
Xiaomi Mi Router 4A (R4AS, what to do, the update was not successful, it was turned off during the update, now it is constantly orange. The computer and the phone no longer see it. Does the computer have to be connected to a working network?
Great video, came upon this while searching for a way to debrick my Xiaomi AX3600 can you provide me with a way or tool to help me debrick my router? It's stuck with the orange led. Thanks a lot!
I have r3gv2 with Padavan that I flashed to Owrt, but I really dont recommend the newest 23 RC2 version because its unstable and 2,4GHz wifi is not working. Reverting back to Padavan didnt work from SSH. Debrick method worked with the stock 4A firmware version 3 only. I guess the Invasion method doesnt need a whole VM and a WSL2 linux console would be enough for that.
Padavan changes the UBoot partition which is what is used when it goes into recovery mode so thats why i say this guide is not for people with Padavan. Good tip on the version though thanks
@@HoddysGuides Dont know that. I followed a russian forum and russian windows bat/py scripts to switch r3gv2 stock chinese version 2 to an universal version 3 uboot first (that has the PXE debrick function I guess) that I suspect based on 4A fw, as chinese r3gv2 dont have version 3 stock fw, and after that could flash Padavan easily. I had serious problem after I wanted to switch back to Padavan from OWRT, because OWRT wrote an error message in SSH after flashing for a reboot command and after that it bricked it.
It's like tech ASMR with your voice. Thanks! But I didn't get the connection thing. My laptop can be connected to the internet via either LAN or Wi-Fi. Do I need to connect the router to the laptop via LAN? Or it's okay to have my router and PC connected via LAN?
aah finaly a video which is worthy. can i have little assistence, have you faced any wan port assignment issue or any wifi strength issues, because someone in a forum said that it losses the wifi strength, signal drops to half, i want to upgrage and just worried about these. btw i have mi 3c, and thanks for this video man i really needs this.
Thank you! In some of the early firmwares yes there were a few issues with that sort of thing, however, now with the current newest firmwares i see none of these issues. Worst case, try it, if you see any issues use the debrick guide and you will be back to stock firmware.
@@xtxo Depends on what you do with it, stock openwrt is about the same, in fact if anything I think it runs cooler (the Xiaomi default firmware is based on openwrt so it was never going to be that much different).
hi man thanks for your incredible video i have the global version of the 4a gigabit with English language running 3.0.24 can i use your debrick method to flash the Chinese firmware on your website on my device? and would i be able to recover from it if things went down?
@@HoddysGuides but i can still setup open wrt right? Sorry 3 more questions before i start doing this 1- does the Chinese firmware supports L2TP VPN? and second does OpenWRT support the 5GHz wifi on the router? And last one can i setup L2TP or OpenVPN on the router with OpenWRT? Sorry for asking too many question You seem like someone with deep knowledge about this router
Sorry if its a dumb question but.. does this take all the security (ie xiaomi eavesdropping) risk from these routers? Compared to a local bought one like a Asus/tp link ? thanks
@@инкогнито7 its not been mentioned in the githus as working yet ao im guessing not or hasnt been tried. If you find it doea work please open an issue and inform the owner of the github that it works
hello expert i have a Mi router 4c, i changed the original firmware by openwrt-23.05.4 after that i added zerotier paquage. how can i use and configure this paquage. no changes on interface after paquage installation thank you
@@jelladtarek looks like its command line only, so you would need to login to the router via SSH then configure it via the command line. Info is shown how on its wiki: openwrt.org/docs/guide-user/services/vpn/zerotier
Great tutorial, congratulations. My Xiaomi 3g v1 entered in bootloop, I tryied follow 4C turorial, but when "mtd -e OS1 -r write firmware.bin OS1" gave error I tried "improvise" putting kernel1.bin from firmware-selector.openwrt in kernel1 partition. R3G don't has OS1 partition. Is there any way to save my router? Thank you very much.
I suggest following the steps for your device on the openwrt wiki, they might be slightly different from this guide as i recently found with someone in stalling on the 4 (not the 4A) so check there for the official method it may say you need to flash kenel1 then the image if its the same
The router has a USB port, I tried to restore official firmware, saving miwifi.bin on a flash drive formatted in fat32, keeping the reset button pressed while turning on the router, but it does not enter recovery mode. I tried to recover using tftp, but the router is in bootloop, the orange led stays on and after about 12 seconds it goes off and comes back on. It doesn't blink when I turn on the router with the reset button pressed.
@joaopaulonamiuti7163 im not sure if you can debrick your device with USB but im sure you can with the tftp version (tinypxe) that i show at the end of the video so i suggest you try that, in the tftp method the firmware file must be named test.bin so if you want to use your own fw download any of my tools and swap the test.bin file for your fw
Every im running "python3 remote_command_execution_vulnerability.py " on Ubuntu VM i cant connect to mi router 4a, stok, ip and password is correct. Telnet connect doesnt work too. Someone can help?
Since OPENWRT file you have downloade it's jsut a bin file, can't it be used on the router's firmware upgrade page instead? Or it's only xiaomi's been accepted on that page?
When I set my pc to 192.168.1.2, (I followed what u did exactly) but when I open the Tiny PXE server, it shows the DHCP server is 127.0.0.1, how can I edit that ? Thank you🙏🏻
You can manually type it in, or use the drop down box and select it. It should however be the first option so check you have closed all the windows after changing the IP, and make sure the tool is not open before changing the IP
@@HoddysGuides I tried again with another computer but it’s still not showing the correct ip, when I edit the IP address within the Pxesrv.exe, it won’t allow me to do so. The dropdown menu only shows 127.0.0.1, any ideas? I am running with an Win10 admin account, mi router Chinese firmware. Thank you🙏🏻
@@user-zr7kz4vs7c i have the same too. the 127.0.0.1 comes from another ethernet adapter. please check and close everything. still cannot do this though. Once it was saying doFile but nothing happened. I have closed all antiviruses
@@user-zr7kz4vs7c i have the same isuse too,and here is the solution: do you have any modem or router, you put the Ethernet Cable from that first,then you set the IP : 192.168.1.2, and then you unplug it, and change the cable from your LAN port Mi Router ,then you open the file in TinyPXE suit w your Mi Router,then you follow the guide in video
do you need to have the xiaomi router installed and running and have your computer using the that router? i am very new to this stuff so i do not know allot about this.
I have a router model 4A R4AC (international), and there is no file for this model on the OpenWRT website. I googled and found the appropriate file, and I managed to flash it, but it turned out that this file is for another model: 5g does not work and constant failures in operation. With the help of your instructions, I returned it to the standard, but I want to try again: please tell me where to find the right bin file!
@@HoddysGuidesThanks so much for your fast answer but I meant before flashing openwrt to router which mode will we use at mi router? That means may I connect my router to my modem via Ethernet cable or use wireless repeater mode at my router?
@@tuygunzaimoglu Appologise, i thought you ment after, as far as i am aware it shouldn't make a difference, but i had mine in wired repeater mode i belive.
@JuanSanchez-rb4qu as far as I know any device with Openwrt version 19.07 or later can be used in a mesh (with other openwrt routers) more info here: openwrt.org/docs/guide-user/network/wifi/mesh/80211s
hi i have a mi router 3c its not showng any lights i dont know why Sometimes it shows yellow light sometimes it doesn't lan Not working no Light on the router can you tell how to use debrick method
It does not work, the purple light flashes. The router seems to have switched to the locked mode and does not allow you to download the firmware any further. Mi WiFi 4A Gigabit Edition
I have a serious problem, I have a R4AC to which I had already installed OpenWRT, but I returned it to the factory settings for certain issues, I want to reinstall it and it is impossible, I tried all possible firmware versions, going from one version to another, it is stuck in the Chinese version and every time I try to run the OpenWRTInvasion fails, try from Linux Subsistem, Ubuntu VM and Docker, nothing works!
@@HoddysGuides In the very beginning, OpenWRTInvasion fails to enable telnet, it told me to check and retry, I tried with each version available for the Chinese version
@tei3228 might have been the version that you were running, its worth trying the newest version of the openinvasion tool or if you are/were then try the debrick method first to downgrade the firmware on the device and try again
Hi ! I've followed every step you mentionned in your video even the debrick method which works like a charm but when i write the OpenWrt.bin inside I can see the rebooting but the led blink in orange and I don't have any ping or ssh or http on the ip 192.168.1.1 Have you encounter this error ? Thanks a lot
Likely the firmware you have used isn't compatible? Are you sure you have the correct version for your router (there is a difference between the gig and 100m versions and all other variants)
Amazing video, however i do need some help because the chinese firmware for R4AC isnt really doing it for me, and 3.0.5 wont get flashed for some reason (mine came with 3.0.8 int at first) is it possible to get back to that version somehow ? also i have a friends router which has the 3.0.12, can i somehow copy it from his router and flash it on mine ?
You would need to download that version from somewhere (try the openwt forums) and then follow my debrick guide but change the test.bin file in the tool to the firmware (make sure you rename it test.bin)
when I get to the step at 11:00 I get an error message that it is an externally managed environment and it doesn't install.. It gives me three possible solutions, but I am not at home in linux, so don't know how to continue. The 3 options are for: installing a python package system wide, or a non debian package or a non debian application. Can somebody advise?
When I type pip3 install -r requirements.txt I get externally-managed-environment error. I suppose I'm not running the command with said router? My plan was to connect it under another router doing the gateway, do I have to connect the Xiaomi as modem-router?
@@andreasschmidt6007 not nessassarilly but it will need to habe access to the internet if you want to download things, i would check tour firewall is setup correctly to allow it to do so
Thanks for the guide. I've done this 2 years before and didn't work. Now I'm trying to debrick. It's now 1 hour sending and receiving pack. Is this ok? 1 hour?
No shouldn't take more than 15 mins generally, how do you know it's sending/receiving? I would check your firewall/Anti-v isn't blocking the tool and ensure you have the correct tool and language for your device.
@@HoddysGuides I changed the lan cable and now it's ok. I remember 2 years ago I used the same LAN cable and didn't work. So funny after two years. Thanks a lot for this tutorial. I wonder if I can remove some unnecessary packages in order to have more space. And finally, how should we backup firmware in case we do somthing wrong with router 😁🙏.
Hi i just somehow broke my Mi 4A(International Vers). After installation of the OpenWrt i tried to do sysupgrade via LuCi interface by downloading it from OpenWrt page and uploading to the interface. BUT before uploading to LuCi interface i changed the name of the upgrade file i guess it leads me to stuck in "Flashing..." Screen forever. After waiting more than 1 hour i decided to debrick my Router. I successfully do the Debrick steps you have provided but still cant reach the internet. Problem is in the router, system status light flashing blue and network status light is only blue (not flashing) In the users manual there is no information about flashing blue light (only purple flashing and it says "Safe mode". But mine is not purple. Therefore i don't have any internet connection via LAN. (In the Windows settings still says Undefined Network on my Ethernet.) Also i can't visit 192.168.31.1 for the mi panel. What should i do? Is my brand new router going to trash can?
@@HoddysGuides i tried and tried and tried again result is same. To the 24:06 everything goes same with you and then nothing changes the blue flashing lights never ends and my PC can't identify the ethernet so i cant get any internet via ethernet (WAN is also connected to the modem). I'm stuck at that step...😞
@@DD-ow4or doing what? Most of the guide is done in linux, for the debrick part it can be done by setting up a tftp sever and then just using the test.bin file from my tools
Can't unbrick the device. It's only blinking, more than 20 mins. And the app is keep scrolling down the "sent" messages, but it never shows the filename.
@@HoddysGuides not exacly, I managed it somehow. Now I have trouble with cyberduck, it's kust don't allow to connect. My router is 4AC, I've tried a lot of firmwares including recommended, but I just can't conenct via ssh and ftp. It says maybe firmware is wrong. Also openwrt instructions says "Check the firmware layout with cat /proc/mtd and only proceed if mtd6: 00200000 00010000 “overlay”" but mine is "00010000 00010000" for some reason. Upd: I finally solvedit. The prolems was my router is v2. So your approach is not completely fits. Actually, I've found some scripts on 4pda which allows to install it automatically, works like a charm. Hovewer, your video part about unbricking was extremely helpful.
Depends on your device but you can do quite a bit with 8m on a router. If you want file storage or something like that i guess you could look into hardware modding yours with a usb input im not sure how yoi would go about doing that but you could try the openwrt forums for help
I have a weird problem and need help I flashed openwrt on 4A perfectly fine no issues but whenever I use 5ghz radio to connect as client to another wifi and test via lan ( like a wifi to ethernet brige? ) the download speed is very low most of the time , it burts at 100mbps then trickles down to 21-30 mostly , on the other hand the upload speed is stable 130-150mbps . Do I have any routing problems , or need any specific settings to change ( tried hardware offloading, didn't help) . For reference in stock firmware wireless repeater mode over lan I get 130-150mbps download & download both (isp plan of 150mbps)
Not something ive seen before, best thing i can do i suggest you play around with the settings make sure they are set for your country and narrow the frequency as much as possible that might help. Also make sure you are being objective dont use things like speed testers to test this as they can fluctuate a lot by the hour as can your ISP, use something like IPerf to get an actual true reading of whats going on as you might find bottlenecks elsewhere
the beginning set up instructions is not working on MACOS. The APT commands are only specific to linux. Also virtual box cannot work on Mac m1 chip. Can someone please help me?
This guide was not made for MacOS unfortunately i dont have a mac so have no way to trouble shoot. You could try asking for help on the openwrt offical forums.
All you need to do is setup a tftp server on the pc then, download the correct tool and put the test.bin file in the root of the tftp server, then follow the rest of the steps as normal
Thank you so much! It's been extremely easy thanks to your video, keep it up!
Bro, I can't describe how awesome I feel after watching your tutorial. This router gave me so much headache and consumed so much of my time. It was well worth throwing it away and buying a new one. But I'm one of those people who want to try everything they can before they do so. And man, your instructions were spot on you helped me do exactly that - fix something that others would've given up on within the first 5 minutes. THANK YOU from the bottom of my soul.
Followed your guidelines, device flashed orange forever, realized I had bricked it ,realized my model was not English but Intl 😢, debricked the device using your video and after trying again it worked🎉 thanks a lot👌
Worked like a charm. I used Ubuntu desktop directly so I didn't need the VirtualBox part. Also, I used ftp command from Ubuntu bash shell to copy the bin file from local to the 4C router. The rest is exactly the same. Many many thanks to Hoddy!
Great thanks for the comment, enjoy your openwrt router!
I just came back to your original video and am so glad that you posted this update...i brought my xiaomi r4ag all the way back to new york from istanbul JUST to try your instructions and now months later (and I think maybe three years after I bought it) and im finally getting to it because my grandmother needs a router so she doesnt have to keep funding those criminal ISPs with her extra $5/month haha
thanks a ton!!!!!
Glad it helped! Enjoy your OpenWrt router!
這個教學是完全正確的.感謝版主.只有一個地方有誤.下載ubuntu絕對不要選擇LTSC.
一定要選擇目前最新版本的.才不會有硬體支援相容性的問題.我重灌了五次.才找到問題
Thank you! I recommend LTS generally because it's less bleeding edge and has better compatibility generally but obviously, that wasn't what you found with it so sorry about that, glad you got it working though!
Thanks, debricking Chinese 4A GIG was success to me, but I have to make additional reboot: After transferring the firmware with a tool the 1st LED start blinking blue colour constantly, but the router didn't reacted on connections. I've to reboot the router and that helped.
Thanks for sharing
yours is the most descriptive guide i have seen, thank you for the content you have made and i wish you success
Thank you so much for this great explanation, I didn't run into any issues except for running the openwrt commands, which I had to run through python venv, otherwise everything else went perfectly thanks to your amazing in depth easy to follow guide.
thanks bro! successful on my 3rd attempt. the trick was to total reset the router before following this guide.
Glad I could help
What you meant with total reset? If the router its bricked how to reset it?
THANK YOU VERY MUCH ❤️.
Finally made it (after 3 months and so many useless tutorials on TH-cam) through your video . Many thanks for your time making a great tutorial ❤️
Glad you finally got it working
many thanks, your method has work, finaly one person that he knows how to make tutorial
God Bless you, and in case you don't believe in one, may the forth be with you.
I just de-bricked my router and I'm very thankful
Glad I could help!
Hi friend, I'm really counting on your help, because I've had a really bad accident. After installing OpenWrt through the console, my mi 4ac went to reboot, but it didn't reboot even after 20 minutes. The red light on the router started to light up constantly and the router does not respond to the reset key. When I connect it to a port and try to use the Debrick tool, I get the following result: DHCPc:no other DHCPd discovered. I really hope you will help me
UPDATE:
It was probably my mistake in unscrewing it, but after a few months I managed to do it very easily. The author is a genius, deserves millions of subscribers
Check your firewall, and AV arent blocking the tool.
@@HoddysGuidesUnfortunately, the problem is not in firewall and antivirus :(
How did you manage to solve the problem?
Thank you !! Very helpful guidelines.
Спасибо тебе, добрый человек. Благодаря тебе я смог "раскирпичить" свой роутер
This guide was a life saver! Thanks a billion!
Glad it helped!
Thank you very much. I followed your instruction and I successfully installed openwrt on my Xiaomi R4a version 2.28.8 chinese version. Subscribe automatically to your channel.
congratulations for the excellent video, I thought I had lost my router because I put a global firmware, and its version is Chinese, thank you very much for this excellent video.👌🙌👏
You are welcome! Enjoy!
Thanks for such a good video, made installing openwrt on this router a piece of cake!
Thank you so much!
you are the best. After all i had to reboot physically btw.after it worked.Thank you man
thanks a ton!! Made it 100% after following your guide.
Glad it helped!
Thank you very much for this vídeo... O seen a lot off videos and consult a lot of sites about this theme and never was able to concludes openwrt installation in my 4c. Finally, with your help, I easly install it. Thank you for your great job
Hello, my friend, cyberdock does not connect. Does it require special settings?
You're very welcome!
You are great!
I have been looking for this video which explains whole process simply in a short time period. Greetings from Turkiye.
Many thanks ❤
It is bricked now and can't come back even i tried all the things you said..
After hours of trying, finally got it to work using the ssh method at the 13 minute mark of this video. 0n my 3Gv1.
Glad you got it working!
Thanks!
I used my system OpenSuse for setting with FileZilla.
Glad it helped!
if the LED in the router flashes white light is a sign that you are holding the reset button too short. you need to hold it while turning on tiny pxe for a while.
Thank you su much for this video !! Long time I was looking to update my Mii router firmware to something more "serious"...
Just in case, for someone else benefit, I fisrt get error when using the exploit, I factory reset my router & then was able to use the exploit & flash with OpenWRT without any issue.
Best video on the topic and trust me, I have seen over 30 of them before finally attempting this. There were some issues with the latest version of VirtualBox unfortunately, but nothing too complicated to handle.
By the way, I (And probably many others as well) would REALLY appreciate it if you made a video about the ideal settings we should select on OpenWRT to get the maximum out of the Mi router 4A; like more range (if possible).
Keep up the good work.
Thank you so much for the feedback!
Hello, thank you for your guide. Nicely explained.
Unfortunately, the debrick tools link in the descriptions won't open. Are there any alternative links?
Site is currently up with no issues, dont know what to say.
the software is TinyPXE 1.0.0.23 , for the test.bin you have to find the suitable ROM for your device
Very helpfull. Thanks.
Thank you very much for the instruction. I wanna take the installation even further by installing vr2ay client on top of OpenWrt. While reading through the comment section, you had mentioned that the space within the router is insufficient to install the vr2ay client.
Can I please know how much space is required to install vr2ay client on top of OpenWrt and this can be done on the Xiaomi Mi Router 4A Gigabit Edition?
I dont remember saying that, im not sure how big that is but no doubt if there isnt enough space you could remove some of the default software if you arent ever going to use it. Package sizes and info about how much space your route has can all be found on the openwrt website.
Firstly, thank you for this amazing guide! I am using my router as repeater right now. For installing openwrt, should i connect it to my desktop via cable? Will this be enough to get an IP? Or shall i convert it into another mode?
Yes at first you will need to connect via cable to the router from your pc and then you can setup the wifi
@@HoddysGuides thanks!
Thanks for the detailed tutorial!
However, I've faced some issues. First, I coudn't get a root access it might be due to firmware version. Secondly, I couldn't get recovery mode -( I thought what if change stock firmware via recovery mode to another version which is ok for openwrt but when I press reset button firmware is writing to memory and led is starting to blink without any thinking. After reboot I still get a stock firmware. No change!
I've tried all of the firmwares and tools (tinypxe and miwifi repair tool) process finishes too fast.
My router MI 4A gigabit (chinese)
Thank you
Have you modified the uboot with something like Padavan or breed?
@@HoddysGuides No. When router starts in recovery mode it takes the firmware (bar is moving) but not installing it
@alexcool8980 likely not accepting the firmware version, try looking for other versions, i know the openwrt github hosts some and there's a few knocking about in the openwrt forums. Just replace the test.bin file with the other fw (ensure to rename it test.bin)
thanks a lot! I succesfully debrick my device following your instructions. However, I'm linux Ubuntu user, I needed to move to my windows computer to do this. Wish there is a linux based tutorial to debrick.
Not too much difference you just need to setup any tftp server, unfortunately for any novice watching the video it would be really difficult for me to explain but if you have a decent amount of linux background setting up a tftp server is probably quite trivial so try that
Thanks you so much bro.❤
Excellent work! Thank you so much!
Good work bro 🎉
Hi, thanks for this great video. After installing the virtual box and clicking on Finish, the powering vm ... starts loading that black box for inputting the commands, which appears for a second and then disappears. Then, on the right corner, it gives this error: "Not in a hypervisor partition (HVP=0) (VERR_NEM_NOT_AVAILABLE). VT-x is disabled in the BIOS for all CPU modes (VERR_VMX_MSR_ALL_VMX_DISABLED)", What should I do? How can I solve this problem, please? Thanks a lot.
Ah, for that you need to switch on a setting in your bios to allow vms or your pc, if you google you motherboard model and enable virtualisaton you should find some info on how to turn that on
Xiaomi Mi Router 4A (R4AS, what to do, the update was not successful, it was turned off during the update, now it is constantly orange. The computer and the phone no longer see it. Does the computer have to be connected to a working network?
@@KoLiBri97 follow the debrick guide at end of video
Thanks. BRO..
You have great knowledge
Thank you!
Great video, came upon this while searching for a way to debrick my Xiaomi AX3600 can you provide me with a way or tool to help me debrick my router? It's stuck with the orange led. Thanks a lot!
Likley the same method but you would need the correct firmware for your device.
Graet guide! I thought it was funny that you switched to root user and even after that you're using sudo.
Force of habit, i guess!
I have r3gv2 with Padavan that I flashed to Owrt, but I really dont recommend the newest 23 RC2 version because its unstable and 2,4GHz wifi is not working. Reverting back to Padavan didnt work from SSH. Debrick method worked with the stock 4A firmware version 3 only. I guess the Invasion method doesnt need a whole VM and a WSL2 linux console would be enough for that.
Padavan changes the UBoot partition which is what is used when it goes into recovery mode so thats why i say this guide is not for people with Padavan. Good tip on the version though thanks
@@HoddysGuides Dont know that. I followed a russian forum and russian windows bat/py scripts to switch r3gv2 stock chinese version 2 to an universal version 3 uboot first (that has the PXE debrick function I guess) that I suspect based on 4A fw, as chinese r3gv2 dont have version 3 stock fw, and after that could flash Padavan easily. I had serious problem after I wanted to switch back to Padavan from OWRT, because OWRT wrote an error message in SSH after flashing for a reboot command and after that it bricked it.
It's like tech ASMR with your voice. Thanks! But I didn't get the connection thing. My laptop can be connected to the internet via either LAN or Wi-Fi. Do I need to connect the router to the laptop via LAN? Or it's okay to have my router and PC connected via LAN?
To follow the guide it must be connected via lan only, openwrt cannot be installed over wifi, after its installed you can use whatever you like
@@HoddysGuides Yep. I just had LAN cables connected in the loop. I finally managed to update the router's firmware, thanks!
Is it working with Xiaomi AC1200 router? Thx.
thanks you man , u save my life
No worries!
aah finaly a video which is worthy.
can i have little assistence, have you faced any wan port assignment issue or any wifi strength issues, because someone in a forum said that it losses the wifi strength, signal drops to half, i want to upgrage and just worried about these. btw i have mi 3c, and thanks for this video man i really needs this.
Thank you! In some of the early firmwares yes there were a few issues with that sort of thing, however, now with the current newest firmwares i see none of these issues. Worst case, try it, if you see any issues use the debrick guide and you will be back to stock firmware.
@@HoddysGuides Thanks👍😊
@@HoddysGuides i have heard it runs hot and more memory hungry
@@xtxo Depends on what you do with it, stock openwrt is about the same, in fact if anything I think it runs cooler (the Xiaomi default firmware is based on openwrt so it was never going to be that much different).
hi man
thanks for your incredible video
i have the global version of the 4a gigabit with English language running 3.0.24
can i use your debrick method to flash the Chinese firmware on your website on my device?
and would i be able to recover from it if things went down?
Yes i belive so, once chinese i dont think you can revert it back to english as far as i am aware.
@@HoddysGuides but i can still setup open wrt right?
Sorry 3 more questions before i start doing this
1- does the Chinese firmware supports L2TP VPN?
and second does OpenWRT support the 5GHz wifi on the router?
And last one can i setup L2TP or OpenVPN on the router with OpenWRT?
Sorry for asking too many question
You seem like someone with deep knowledge about this router
Thanks a lot man.
Sorry if its a dumb question but.. does this take all the security (ie xiaomi eavesdropping) risk from these routers? Compared to a local bought one like a Asus/tp link ? thanks
Yeah strips it right back and replaces it with a different operating system that is open source.
Can I do this wirelessly? Or do I have to be wired to the router? thanks
No wired only.
Thanks
No problem hope it helped
Bro, Thanks for the guide! Does this patcher support Xiaomi 4A Gigabit Edition v2 (r4av2)?
@@инкогнито7 its not been mentioned in the githus as working yet ao im guessing not or hasnt been tried. If you find it doea work please open an issue and inform the owner of the github that it works
Hi, is there a way to set this router's dBm to 30 like the AX3600? How's the range/speed on OpenWRT compared with the stock fw?
Yes, check out my video on setting up openwrt on how to do that
hello expert
i have a Mi router 4c, i changed the original firmware by openwrt-23.05.4
after that i added zerotier paquage.
how can i use and configure this paquage. no changes on interface after paquage installation
thank you
@@jelladtarek looks like its command line only, so you would need to login to the router via SSH then configure it via the command line. Info is shown how on its wiki: openwrt.org/docs/guide-user/services/vpn/zerotier
Great tutorial, congratulations. My Xiaomi 3g v1 entered in bootloop, I tryied follow 4C turorial, but when "mtd -e OS1 -r write firmware.bin OS1" gave error I tried "improvise" putting kernel1.bin from firmware-selector.openwrt in kernel1 partition. R3G don't has OS1 partition.
Is there any way to save my router?
Thank you very much.
I suggest following the steps for your device on the openwrt wiki, they might be slightly different from this guide as i recently found with someone in stalling on the 4 (not the 4A) so check there for the official method it may say you need to flash kenel1 then the image if its the same
But for saving the debrick method dhould always work as long as you have the correct stock firmware
The router has a USB port, I tried to restore official firmware, saving miwifi.bin on a flash drive formatted in fat32, keeping the reset button pressed while turning on the router, but it does not enter recovery mode.
I tried to recover using tftp, but the router is in bootloop, the orange led stays on and after about 12 seconds it goes off and comes back on. It doesn't blink when I turn on the router with the reset button pressed.
@joaopaulonamiuti7163 im not sure if you can debrick your device with USB but im sure you can with the tftp version (tinypxe) that i show at the end of the video so i suggest you try that, in the tftp method the firmware file must be named test.bin so if you want to use your own fw download any of my tools and swap the test.bin file for your fw
Every im running "python3 remote_command_execution_vulnerability.py " on Ubuntu VM i cant connect to mi router 4a, stok, ip and password is correct. Telnet connect doesnt work too. Someone can help?
Since OPENWRT file you have downloade it's jsut a bin file, can't it be used on the router's firmware upgrade page instead? Or it's only xiaomi's been accepted on that page?
No unfortunately not, the Xiaomi update looks for a signed version of Xiaomi firmware
thanks bro your best
I installed OpenWRT and i have access to admin panel but there is no internet connection. What did i do wrong?
@@user-kh1uq3ze5w try watching my getting started with openwrt video
When I set my pc to 192.168.1.2, (I followed what u did exactly) but when I open the Tiny PXE server, it shows the DHCP server is 127.0.0.1, how can I edit that ? Thank you🙏🏻
You can manually type it in, or use the drop down box and select it. It should however be the first option so check you have closed all the windows after changing the IP, and make sure the tool is not open before changing the IP
@@HoddysGuides I tried again with another computer but it’s still not showing the correct ip, when I edit the IP address within the Pxesrv.exe, it won’t allow me to do so. The dropdown menu only shows 127.0.0.1, any ideas? I am running with an Win10 admin account, mi router Chinese firmware. Thank you🙏🏻
@@user-zr7kz4vs7c i have the same too. the 127.0.0.1 comes from another ethernet adapter. please check and close everything. still cannot do this though. Once it was saying doFile but nothing happened. I have closed all antiviruses
@@user-zr7kz4vs7c i have the same isuse too,and here is the solution: do you have any modem or router, you put the Ethernet Cable from that first,then you set the IP : 192.168.1.2, and then you unplug it, and change the cable from your LAN port Mi Router ,then you open the file in TinyPXE suit w your Mi Router,then you follow the guide in video
do you need to have the xiaomi router installed and running and have your computer using the that router? i am very new to this stuff so i do not know allot about this.
Yes it has to be wire connection directly to the pc not wifi
I cant connect to router by cyberduck
say "Connection refused"
pls help me
Check your firewall or antivirus isn't blocking rhe program
Firewall is off and there is no any antivirus @@HoddysGuides
I have a router model 4A R4AC (international), and there is no file for this model on the OpenWRT website. I googled and found the appropriate file, and I managed to flash it, but it turned out that this file is for another model: 5g does not work and constant failures in operation. With the help of your instructions, I returned it to the standard, but I want to try again: please tell me where to find the right bin file!
They seem to have changed the location of the files, you should be able to use the firmware selector here: firmware-selector.openwrt.org/
MiR4AC 100M china language ok.
Thank you very much!
Glad it helped!
Hi, btw I would like to ask if there's any way to go back to mi firmware? same way as debricking method?
Yes follow the debrick guide to revert
@@HoddysGuides Thanks. Any idea where I could get fw 3.10.18 ?
Which mode should we use for this steps?
1- Main Wi-Fi Mode
2- Wireless Repeater Mode
3- Wired Repeater Mode
I think this video i made should help:
th-cam.com/video/uhJF0XmVhME/w-d-xo.html
@@HoddysGuidesThanks so much for your fast answer but I meant before flashing openwrt to router which mode will we use at mi router? That means may I connect my router to my modem via Ethernet cable or use wireless repeater mode at my router?
@@HoddysGuides And on Ubuntu wireless settings dns numbers are very much there are about twenty numbers so I can’t write them to terminal
@@tuygunzaimoglu Appologise, i thought you ment after, as far as i am aware it shouldn't make a difference, but i had mine in wired repeater mode i belive.
Can this be done in Windows Subsystem for Linux 2 (WSL2) in Windows 10?
It can its not very simple though and for explanation to masses its easiest the way i describe.
Its 4A V2 supported ? Because in the official openwrt page of the router its not
@@TommasoScardi-k3z ive not seen this confirmed as of yet. If it does please let me know
Hey do you know if it supports mesh with another router?
@JuanSanchez-rb4qu as far as I know any device with Openwrt version 19.07 or later can be used in a mesh (with other openwrt routers) more info here:
openwrt.org/docs/guide-user/network/wifi/mesh/80211s
Hello, is this the same procedure for xiaomi 4a gigabit?
@@lestherartillaga yes
@@HoddysGuides ok,thank you
hi i have a mi router 3c its not showng any lights i dont know why Sometimes it shows yellow light sometimes it doesn't lan Not working no Light on the router can you tell how to use debrick method
Yeah, follow the guide at the end of the video
It does not work, the purple light flashes. The router seems to have switched to the locked mode and does not allow you to download the firmware any further. Mi WiFi 4A Gigabit Edition
Follow the debrick method at end of video, next time ensure you use correct firmware for your device.
I have a serious problem, I have a R4AC to which I had already installed OpenWRT, but I returned it to the factory settings for certain issues, I want to reinstall it and it is impossible, I tried all possible firmware versions, going from one version to another, it is stuck in the Chinese version and every time I try to run the OpenWRTInvasion fails, try from Linux Subsistem, Ubuntu VM and Docker, nothing works!
Hope you found a solution, im not really sure at what point of the guide you had problems but happy to help if i can
@@HoddysGuides In the very beginning, OpenWRTInvasion fails to enable telnet, it told me to check and retry, I tried with each version available for the Chinese version
@tei3228 might have been the version that you were running, its worth trying the newest version of the openinvasion tool or if you are/were then try the debrick method first to downgrade the firmware on the device and try again
hi, how about using wsl2 instead of virtualbox?
@@nauvalalzidane8235 possily, it was a bit undoumented when i did this but it could be done
@@HoddysGuides all right, thankyou very much.
Hi !
I've followed every step you mentionned in your video even the debrick method which works like a charm but when i write the OpenWrt.bin inside I can see the rebooting but the led blink in orange and I don't have any ping or ssh or http on the ip 192.168.1.1
Have you encounter this error ?
Thanks a lot
Likely the firmware you have used isn't compatible? Are you sure you have the correct version for your router (there is a difference between the gig and 100m versions and all other variants)
Amazing video, however i do need some help because the chinese firmware for R4AC isnt really doing it for me, and 3.0.5 wont get flashed for some reason (mine came with 3.0.8 int at first) is it possible to get back to that version somehow ? also i have a friends router which has the 3.0.12, can i somehow copy it from his router and flash it on mine ?
You would need to download that version from somewhere (try the openwt forums) and then follow my debrick guide but change the test.bin file in the tool to the firmware (make sure you rename it test.bin)
when I get to the step at 11:00 I get an error message that it is an externally managed environment and it doesn't install.. It gives me three possible solutions, but I am not at home in linux, so don't know how to continue. The 3 options are for: installing a python package system wide, or a non debian package or a non debian application. Can somebody advise?
@@daanwolthuis system wide is fine, tbh all options will work for what we are doing but system wide is probably the best
Hi, i have a v2 international router. When i tried flashing the bin file, the led blinking in purple. Can you please help me?
Follow the debrick guide at the end of the video
When I type pip3 install -r requirements.txt I get externally-managed-environment error. I suppose I'm not running the command with said router? My plan was to connect it under another router doing the gateway, do I have to connect the Xiaomi as modem-router?
@@andreasschmidt6007 not nessassarilly but it will need to habe access to the internet if you want to download things, i would check tour firewall is setup correctly to allow it to do so
Will the RCE no longer work after installing this? Scary stuff
No after the install the RCE stops working
Hello!
24:00 If my Router Mi 4a 100M Chinese blinks a yellow light and DoReadFile appears, but is stuck on that, what could it be?
Make sure you have the correct firmware file for your router.
Thanks for the guide. I've done this 2 years before and didn't work. Now I'm trying to debrick. It's now 1 hour sending and receiving pack. Is this ok? 1 hour?
No shouldn't take more than 15 mins generally, how do you know it's sending/receiving? I would check your firewall/Anti-v isn't blocking the tool and ensure you have the correct tool and language for your device.
@@HoddysGuides I changed the lan cable and now it's ok. I remember 2 years ago I used the same LAN cable and didn't work. So funny after two years. Thanks a lot for this tutorial. I wonder if I can remove some unnecessary packages in order to have more space.
And finally, how should we backup firmware in case we do somthing wrong with router 😁🙏.
@Soheil Bahrekazemi stock firmware cant be done without a chip programmer, openwrt can be done from the backup tab
@@HoddysGuides thanks. 🙏😀
good work, thx for u deep guide
Hi i just somehow broke my Mi 4A(International Vers).
After installation of the OpenWrt i tried to do sysupgrade via LuCi interface by downloading it from OpenWrt page and uploading to the interface. BUT before uploading to LuCi interface i changed the name of the upgrade file i guess it leads me to stuck in "Flashing..." Screen forever. After waiting more than 1 hour i decided to debrick my Router.
I successfully do the Debrick steps you have provided but still cant reach the internet.
Problem is in the router, system status light flashing blue and network status light is only blue (not flashing)
In the users manual there is no information about flashing blue light (only purple flashing and it says "Safe mode". But mine is not purple.
Therefore i don't have any internet connection via LAN. (In the Windows settings still says Undefined Network on my Ethernet.)
Also i can't visit 192.168.31.1 for the mi panel. What should i do? Is my brand new router going to trash can?
@mertkilic1 sounds like the debrick didn't work tray again and be sure to have the correct firmware for your device (the language matters)
@@HoddysGuides i tried and tried and tried again result is same.
To the 24:06 everything goes same with you and then nothing changes the blue flashing lights never ends and my PC can't identify the ethernet so i cant get any internet via ethernet (WAN is also connected to the modem). I'm stuck at that step...😞
By the way I'm %100 sure about using right Debricker tool for my router. It's Mi 4A (R4AC - International Version)
@@mertkilic1same here… Did you figure it out?
any sort of way of doing it on linux will be appreciated
@@DD-ow4or doing what? Most of the guide is done in linux, for the debrick part it can be done by setting up a tftp sever and then just using the test.bin file from my tools
Why can't I open terminal
I dont know, are you using ubuntu? Did you try typing terminal in the search bar?
It happened to me as well. Apparently it’s this version of VirtualBox's fault. Delete the Ubuntu and reinstall, this time without the guest mode.
@@DatsWhatSheSaid hey, did you mean install without guest additions?
@@ahmetsimsek336 Yes. Sorry I didn't remember what it was back then.
Whatever this problem is solved via changing the language to English UK, inside the Settings, Language menu.
after su command I enter password from user, and it says Authentication failure. I never set up root pass though.
@@hirasavayui9799 follow the guide, the password is root as well as the username
Can't unbrick the device. It's only blinking, more than 20 mins. And the app is keep scrolling down the "sent" messages, but it never shows the filename.
If you dont see in the log:
Do.read.file test.bin
Then its likely the tool got blocked by something like your firewall or antivirus
@@HoddysGuides not exacly, I managed it somehow. Now I have trouble with cyberduck, it's kust don't allow to connect. My router is 4AC, I've tried a lot of firmwares including recommended, but I just can't conenct via ssh and ftp. It says maybe firmware is wrong. Also openwrt instructions says "Check the firmware layout with cat /proc/mtd and only proceed if mtd6: 00200000 00010000 “overlay”" but mine is "00010000 00010000" for some reason.
Upd: I finally solvedit. The prolems was my router is v2. So your approach is not completely fits. Actually, I've found some scripts on 4pda which allows to install it automatically, works like a charm. Hovewer, your video part about unbricking was extremely helpful.
why disk space is 8m ? how can we increase it ?
Depends on your device but you can do quite a bit with 8m on a router. If you want file storage or something like that i guess you could look into hardware modding yours with a usb input im not sure how yoi would go about doing that but you could try the openwrt forums for help
Hi, i have a big problem
Cyberdock does not connect.
Did the expoit say it worked?
I have a weird problem and need help
I flashed openwrt on 4A perfectly fine no issues but whenever I use 5ghz radio to connect as client to another wifi and test via lan ( like a wifi to ethernet brige? ) the download speed is very low most of the time , it burts at 100mbps then trickles down to 21-30 mostly , on the other hand the upload speed is stable 130-150mbps . Do I have any routing problems , or need any specific settings to change ( tried hardware offloading, didn't help) . For reference in stock firmware wireless repeater mode over lan I get 130-150mbps download & download both (isp plan of 150mbps)
Not something ive seen before, best thing i can do i suggest you play around with the settings make sure they are set for your country and narrow the frequency as much as possible that might help. Also make sure you are being objective dont use things like speed testers to test this as they can fluctuate a lot by the hour as can your ISP, use something like IPerf to get an actual true reading of whats going on as you might find bottlenecks elsewhere
If all else fails post your results and issues on the openwrt forums as they might be able to help you too
Hi, i used every bin file i found in the internet and and i got a flashing purple led. Can you help me find the correct rom file?
When using the tool does the log box show a line like:
"do.read.file test.bin"
?
thank you
Hi i get "Connection refused" error by FTP [linux and windows]
@@rezanezhadmusavi2465 check you havent got an antivirus or firewall blocking your connection
the beginning set up instructions is not working on MACOS. The APT commands are only specific to linux. Also virtual box cannot work on Mac m1 chip. Can someone please help me?
This guide was not made for MacOS unfortunately i dont have a mac so have no way to trouble shoot. You could try asking for help on the openwrt offical forums.
@@HoddysGuides Thanks. I think I bricked my router. I can't seem to find a Debrick program for Mac either :(
@@JasonAzad-df4zs any tftp server should work and take the test.bin file and place it in the root directory
Is this for r4a or r4av2?
Both as far as im aware, but feel free to read up on the github page mentioned in the description for all the routers that are supported
i have no windows computer. please guide me debricking the router in linux.
All you need to do is setup a tftp server on the pc then, download the correct tool and put the test.bin file in the root of the tftp server, then follow the rest of the steps as normal
thank you bro