What's new

CFE bootloader update

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Status
Not open for further replies.
Hi,

What are my benefits if I update the Cfe to 1.0.1.3,did the n66u runs better ? Do I have any disadvantages if I stay with 1.0.1.2 ?
Andy i did not understand why i must keep the old CFE ?

Best regards
stargate
 
Hi,

What are my benefits if I update the Cfe to 1.0.1.3,did the n66u runs better ? Do I have any disadvantages if I stay with 1.0.1.2 ?
Andy i did not understand why i must keep the old CFE ?

Best regards
stargate

There is no benefit to upgrading the CFE if you are still running Asuswrt or Asuswrt-Merlin.

Even with DD-WRT now, the CFE upgrade is no longer necessary, as Brainslayer recently released a build that handles any CFE version.
 
I checked Brainslayer's list but cannot find one for n66u. I sure would like to find one that doesnt require my having to update the CFE. I'm too worried about the implications of screwing something up. Hehe.
 
Hi.It's taken from new RT-N66U device. You may check current CFE version this way:
Where do we enter in these commands? in the browser bar as
eg. 192.168.1.2 # strings /dev/mtd0ro | grep bl_version

or via the GUI in an admin section ?
 
Where do we enter in these commands? in the browser bar as
eg. 192.168.1.2 # strings /dev/mtd0ro | grep bl_version

or via the GUI in an admin section ?

If you have RMerlin firmware, like 270.26b, you can enter it in the admin web GUI "Tools" tab under the "Run Command" tab there.

If you have Asus firmware, I believe that you would have to telnet or ssh into your router as user "admin" at 192.168.1.1, and issue the commands at a shell prompt. It's been a while since I've used the Asus firmware, but last time I did, they didn't have a "Run Command" kind of thing in their web GUI. If they do now, then you can run it there without having to telnet or ssh directly into the router.
 
I tried this today on the latest firmware Version:3.0.0.4.354.27 BETA1 from Merlin

Got this result

[4/5] Checking differences between NVRAM from old and new CFE's
./diff: can't resolve symbol '_stdlib_mb_cur_max' in lib './diff'.
If you see only two differences: one is for 'bl_version' variable change
and second is a new 'odmpid=ASUS' variable then all goes well!

After that i did a manual compare of the two text files and they were fine so executed the CFE update anyway.

Just wanted to let you know

Hi Soul-Reaver

Im getting the same message ("can't resolve ..."). My N66U is running on Merlin 3.00.254.29 BETA1. Your cfe/firmware update worked well despite the warning message? How did you find out it should work well?

Thanks!
 
CFE version no longer of interest

There is no benefit to upgrading the CFE if you are still running Asuswrt or Asuswrt-Merlin.

Even with DD-WRT now, the CFE upgrade is no longer necessary, as Brainslayer recently released a build that handles any CFE version.

True, here is the proof:
25-May-2013: Since the experimental K3.X Broadcom Builds are out, you do not need to care what CFE you have. DD-WRT detects it automatically and extends 32KB NVRAM Version to 64KB. Which Image you have to flash, depends on your previous Image ( Stock, Merlin, K2.6 DD-WRT ).

Source: http://www.dd-wrt.com/wiki/index.php?title=Asus_RT-N66U#New_K3.X_Builds
 
Hi Soul-Reaver

Im getting the same message ("can't resolve ..."). My N66U is running on Merlin 3.00.254.29 BETA1. Your cfe/firmware update worked well despite the warning message? How did you find out it should work well?

Thanks!

It is supposed to compare two different text files created prior to the compare. I manually compared these two files using Total Commander and found out that the only differences were the ones that were to be expected

My CFE update was/is without issues
 
CFE version no longer of interest
…for DD-WRT users. I'm not using it, but I was interested to return CFE ability to read NVRAM variables to:
  • set CPU clock frequency,
  • RAM timings,
  • kernel loading arguments,
and so on. That «scary»*things is never used by ordinary users, that's for developers mostly:)
 
I've just tried to update my N66U bootloader. Firmware:3.0.0.4.374.32 (Merlin build).
Following step by step the 1st page procedure, I have this output error.
Here's the log of my operations.

Code:
[4/5] Checking differences between NVRAM from old and new CFE's
./diff: can't resolve symbol '_stdlib_mb_cur_max' in lib './diff'.
If you see only two differences: one is for 'bl_version' variable change
and second is a new 'odmpid=ASUS' variable then all goes well!
[5/5] Flashing new CFE...
Do you want to flash a new CFE bootloader that? [y,n]nflashing canceled!
admin@RT-N66U:/tmp/home/root#

I answered "n" and I thinks it's all ok. :)
Any idea?
Thanks


UPDATE
After manually checked differences between nvram files I update the CFE.
All was ok, CFE now is 1.0.1.3
 
Last edited:
Old CFE file is a 256KB file, new CFE file is 128KB, is this normal?? Can i flash the 128KB file?

I see new CFE files dumped from RT-N66U and they're size is still 256KB :-S

./cfe_update.sh cfe_old.bin

[root@proxy cfe]$ ./cfe_update.sh cfe_old.bin
[1/4] Dumping default NVRAM settings from original CFE...
nvram header found:
start 0x400
end 0x1374
len 3956
crc 0x07
ver 0x01
[2/4] Preparing new CFE...
nvram header created:
start 0x400
end 0x137c
len 3964
crc 0x5b
ver 0x01
[4/5] Checking differences between NVRAM from old and new CFE's
--- nvram_orig.txt 2013-09-07 17:22:41.000000000 +0100
+++ nvram_updated.txt 2013-09-07 17:22:41.000000000 +0100
@@ -1 +1 @@
-bl_version=1.0.1.2
+bl_version=1.0.1.3
@@ -16,0 +17 @@
+odmpid=ASUS
If you see only two differences: one is for 'bl_version' variable change
and second is a new 'odmpid=ASUS' variable then all goes well!
[5/5] Flashing new CFE...
Do you want to flash a new CFE bootloader that? [y,n]nflashing canceled!

[root@proxy cfe]$ ls -l
total 640
-rw-r--r-- 1 root root 133428 Sep 7 17:22 cfe.new
-rw-r--r-- 1 root root 133428 Oct 2 2012 cfe_n66u-1.0.1.3.empty.bin
-rw-r--r-- 1 root root 262144 Sep 7 02:46 cfe_old.bin
-rwxr-xr-x 1 root root 1828 Dec 4 2012 cfe_update.sh
-rwxr-xr-x 1 root root 92708 Dec 4 2012 diff
-rw-r--r-- 1 root root 4023 Sep 7 17:22 nvram.txt
-rw-r--r-- 1 root root 4011 Sep 7 17:22 nvram_orig.txt
-rw-r--r-- 1 root root 4023 Sep 7 17:22 nvram_updated.txt
-rwxr-xr-x 1 root root 9056 Dec 4 2012 nvsimple-mipsel
 
Last edited:
Old CFE file is a 256KB file, new CFE file is 128KB, is this normal?? Can i flash the 128KB file?
It's normal. Backup is a partition image, but new CFE file is a program image.

Look into old CFE image with some HEX editor. CFE itself take approx. half of image, other half is just a garbage.
 
Yup exactly ;)

I've got another device to recover (JTAG) from a friend should i flash the backup CFE or can i flash directly the new file?

Theres a curious thing, if you analise the CFE (1.0.1.3) via Hex Editor after the conversion you will still see the MAC address there, but if you analise the same CFE (1.0.1.3) dumped from the new RT-N66U devices with new revision / cfe you will not see the MAC address from the device.

Thanks
 
Last edited:
I've got another device to recover (JTAG) from a friend should i flash the backup CFE or can i flash directly the new file?
cfe_n66u-1.0.1.3.empty.bin image contains no MAC addresses. You have to modify update script to embed MAC's into CFE image.

Theres a curious thing, if you analise the CFE (1.0.1.3) via Hex Editor after the conversion you will still see the MAC address there, but if you analise the same CFE (1.0.1.3) dumped from the new RT-N66U devices with new revision / cfe you will not see the MAC address from the device.
Really curious. My update is for older devices only, there was no sense to analyse new devices, where CFE 1.0.1.3 is already installed.
 
cfe_n66u-1.0.1.3.empty.bin image contains no MAC addresses. You have to modify update script to embed MAC's into CFE image

I was refering to the converted file, i know the empty does not contain MAC address :p

Thanks once again.
 
Hello, this might be a dumb question so excuse my ignorance on the subject but does it matter where the scripts are stored and unpacked on the desktop after being downloaded? It is not put on a flash drive and have to be mounted or anything correct? I take it the command will automatically find it then
 
Hello, this might be a dumb question so excuse my ignorance on the subject but does it matter where the scripts are stored and unpacked on the desktop after being downloaded? It is not put on a flash drive and have to be mounted or anything correct? I take it the command will automatically find it then

The easiest way is to follow the instructions in post 1, which tells you to telnet/SSH to router and using the commands DL the zipped file onto the router and unpack it on there.

BTW, the upgrade is no longer necessary with recent firmwares.
 
RT-N66U (B1) 1.0.1.4 CFE UPGRADE:
========================


1. Install RMerlin FW and connect a storage USB device. (Mounted on /tmp/sda/pen in my case)

2. Go to "http://192.168.1.1/Tools_Sysinfo.asp" and check for your Bootloader (CFE) version.

3. Backup your current CFE and download the new CFE 1.0.1.4 version:

http://www.4shared.com/zip/luaT_AhNce/rt-n66u_b1_1014.html

Use one of this commands to backup your current CFE via Telnet/SSH (enable it on the router):

cat /dev/mtd0 > /tmp/sda/pen/original_cfe.bin
(change your path if that's the case)

dd if=/dev/mtd0 of=/tmp/sda/pen/original_cfe.bin
(change your path if that's the case)

4. Unmount your USB device via http://192.168.1.1 webpage and remove it from the router.

5. Use an Hex Editor software (i use HXD) and open your backup Bootloader (CFE) file "original_cfe.bin" and the new CFE "rt-n66u_b1_1.0.1.4.bin".

6. Search (CTRL+F) on both files for "mac" word to find the three entries that we need, use F3 key to go the next one:

et0macaddr=XX:XX:XX:XX:XX:XX
macaddr=XX:XX:XX:XX:XX:XX
macaddr=XX:XX:XX:XX:XX:XX

You should also compare these two entries on both CFE to make sure they match your region:

regulation_domain
regulation_domain_5G

Where you see XX:XX:XX:XX:XX:XX, these are the three MAC Address entries we need to change, just copy them from your "original_cfe.bin" (select only the MAC Address and copy it with CTRL+C) to the new CFE file "rt-n66u_b1_1.0.1.4.bin" (select only the MAC Address and paste it with CTRL+V) and double check that you have not changed any other part.

NOTE: YOUR BACKUP CFE FILE "original_cfe.bin" HAS YOUR DEVICE REAL MAC ADDRESS AND THE NEW CFE FILE "rt-n66u_b1_1.0.1.4.bin" HAS XX:XX:XX:XX:XX:XX FOR REFERENCE ONLY, YOU SHOULD REPLACE IT WITH YOUR REAL DEVICE MAC ADDRESSES.

7. After MAC Address replacement save the new file with a new name "new_cfe.bin" and copy it to your storage USB device.

8. Connect the storage USB device to the router and go to the directory where "new_cfe.bin" is located and use this command to update CFE:

mtd-write -i new_cfe.bin -d pmon

9. Reboot your router and enjoy your new CFE version.

10. Go to "http://192.168.1.1/Tools_Sysinfo.asp" and check for your NEW 1.0.1.4 upgraded Bootloader (CFE) version.

WARNING:

IF THESE METHOD IS DONE EXACTLY HOW EXPLAINED YOU WILL EASILY UPDATE YOUR CFE WITHOUT A PROBLEM, DO IT AT YOUR OWN RISK.

BE AWARE, IF SOMETHING GOES WRONG WITH UPDATE YOU WILL BRICK YOUR ROUTER AND THE ONLY WAY TO RECOVER IT IS VIA JTAG.
 
Last edited:
I did it this way in 1m, but you are free to use the best method for you...
 
Last edited:
Status
Not open for further replies.

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top