In easyburn.sh, when the -n argument is passed, it sets the noburn variable to 1.
On lines 401-402, BURNIT gets set to yes whenever noburn equals 1.
the actual burning command is at line 458
here is my output when running with -n -f:
Code:
root@RB:~# update -n -f
Burn of firmware will not be done.
All dd-wrt upgrade builds available online for 2021
1) 08-25-2021-r47256 c <--- current
Current build: 47256
Select a build to install (or Q): 1
********************************************************
***** WARNING: BUILD SELECTED IS ALREADY INSTALLED *****
********************************************************
Selected 08-25-2021-r47256
Files in build 08-25-2021-r47256 for Dlink-DIR868L reva
1) dir868a-webflash.bin c <--- auto selected
2) factory-to-ddwrt.bin
Selected dir868a-webflash.bin
Build not in local cache or -f option, downloading...
Downloading https://download1.dd-wrt.com/dd-wrtv2/downloads/betas/2021/08-25-2021-r47256/dlink-dir868l-reva/dir868a-webflash.bin ...
Downloading in 8 parts: 25407488 / 25407488 bytes @ 1378 kb/s (100%)
Joining 8 parts: 8
Downloaded file OK.
WARNING THIS COULD BRICK YOUR ROUTER!!!
File to burn: /opt/easyddup/fwcache/08-25-2021-r47256/dlink-dir868l-reva/dir868a-webflash.bin
Processing callback write_report()
Callback write_report() completed.
Burning /opt/easyddup/fwcache/08-25-2021-r47256/dlink-dir868l-reva/dir868a-webflash.bin
WARNING: DO NOT INTERRUPT...
WAIT FOR BURN TO COMPLETE (at least 5 minutes)
Skipping firmware burn.
Skipping reboot.
root@RB:~#
perhaps yoyoma2 can explain to you the flow of the script.
Select a firmware file to install (or Q): 1
Selected www.dd-wrt.com
Build not in local cache or -f option, downloading...
Downloading https://download1.dd-wrt.com/dd-wrtv2/downloads/betas/2021/08-25-2021-r47256/tp-link-archer-c7-v2/http://www.dd-wrt.com ...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 415 100 415 0 0 320 0 0:00:01 0:00:01 --:--:-- 320
Downloaded file OK.
WARNING THIS COULD BRICK YOUR ROUTER!!!
File to burn: ./fwcache/08-25-2021-r47256/tp-link-archer-c7-v2/www.dd-wrt.com
Erase nvram y/n ? n
Save user settings restore point y/n ? n
./easyddup.sh: line 452: tee: not found
WARNING: DO NOT INTERRUPT...
WAIT FOR BURN TO COMPLETE (at least 5 minutes)
Skipping firmware burn.
Skipping reboot.
I think tee is included in larger builds and/or entware.
Select a firmware file to install (or Q): 1
Selected www.dd-wrt.com
Build not in local cache or -f option, downloading...
Downloading https://download1.dd-wrt.com/dd-wrtv2/downloads/betas/2021/08-25-2021-r47256/tp-link-archer-c7-v2/http://www.dd-wrt.com ...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 415 100 415 0 0 320 0 0:00:01 0:00:01 --:--:-- 320
Downloaded file OK.
WARNING THIS COULD BRICK YOUR ROUTER!!!
File to burn: ./fwcache/08-25-2021-r47256/tp-link-archer-c7-v2/www.dd-wrt.com
Erase nvram y/n ? n
Save user settings restore point y/n ? n
./easyddup.sh: line 452: tee: not found
WARNING: DO NOT INTERRUPT...
WAIT FOR BURN TO COMPLETE (at least 5 minutes)
Skipping firmware burn.
Skipping reboot.
in easyddup.ini please set
EDDUP_HARDWARE_FOLDER="tplink_archer-c7-v2"
EDDUP_EXPECTED_FW_SIZE_MIN=14000000
EDDUP_EXPECTED_FW_SIZE_MAX=28000000
and try again
In easyburn.sh, when the -n argument is passed, it sets the noburn variable to 1.
On lines 401-402, BURNIT gets set to yes whenever noburn equals 1.
The BURNIT variable just makes the utility go through the motions of burning and noburn skips the lowlevel firmware writing and the reboot. So with the -n option, YES we want to go through the motions but we don't want to actually burn. Those features were written at different times so granted less confusing variable names could have been chosen.
Does your build have which? (try "which which") I was thinking of using 'which tee' to see if tee is available.
in easyddup.ini please set
EDDUP_HARDWARE_FOLDER="tplink_archer-c7-v2"
EDDUP_EXPECTED_FW_SIZE_MIN=14000000
EDDUP_EXPECTED_FW_SIZE_MAX=28000000
and try again
the fw sizes above may need further adjustment, but those values are good enough for now
Code:
root@DD-WRT:/tmp/easyddup# ./easyddup.sh -n -f
Burn of firmware will not be done.
All dd-wrt upgrade builds available online for 2021
1) 08-25-2021-r47256 c <--- current
Current build: 47256
Select a build to install (or Q): 1
********************************************************
***** WARNING: BUILD SELECTED IS ALREADY INSTALLED *****
********************************************************
Selected 08-25-2021-r47256
Files in build 08-25-2021-r47256 for TP-Link ARCHER-C7 v2
Select a firmware file to install (or Q): 5
Selected tplink_archer-c7-v2-US.bin
Build not in local cache or -f option, downloading...
Downloading https://download1.dd-wrt.com/dd-wrtv2/downloads/betas/2021/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin ...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 15.6M 100 15.6M 0 0 1490k 0 0:00:10 0:00:10 --:--:-- 2008k
Downloaded file OK.
WARNING THIS COULD BRICK YOUR ROUTER!!!
File to burn: ./fwcache/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin
Erase nvram y/n ? n
Save user settings restore point y/n ? n
./easyddup.sh: line 452: tee: not found
WARNING: DO NOT INTERRUPT...
WAIT FOR BURN TO COMPLETE (at least 5 minutes)
Skipping firmware burn.
Skipping reboot.
in easyddup.ini please set
EDDUP_HARDWARE_FOLDER="tplink_archer-c7-v2"
EDDUP_EXPECTED_FW_SIZE_MIN=14000000
EDDUP_EXPECTED_FW_SIZE_MAX=28000000
and try again
the fw sizes above may need further adjustment, but those values are good enough for now
Code:
root@DD-WRT:/tmp/easyddup# ./easyddup.sh -n -f
Burn of firmware will not be done.
All dd-wrt upgrade builds available online for 2021
1) 08-25-2021-r47256 c <--- current
Current build: 47256
Select a build to install (or Q): 1
********************************************************
***** WARNING: BUILD SELECTED IS ALREADY INSTALLED *****
********************************************************
Selected 08-25-2021-r47256
Files in build 08-25-2021-r47256 for TP-Link ARCHER-C7 v2
Select a firmware file to install (or Q): 5
Selected tplink_archer-c7-v2-US.bin
Build not in local cache or -f option, downloading...
Downloading https://download1.dd-wrt.com/dd-wrtv2/downloads/betas/2021/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin ...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 15.6M 100 15.6M 0 0 1490k 0 0:00:10 0:00:10 --:--:-- 2008k
Downloaded file OK.
WARNING THIS COULD BRICK YOUR ROUTER!!!
File to burn: ./fwcache/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin
Erase nvram y/n ? n
Save user settings restore point y/n ? n
./easyddup.sh: line 452: tee: not found
WARNING: DO NOT INTERRUPT...
WAIT FOR BURN TO COMPLETE (at least 5 minutes)
Skipping firmware burn.
Skipping reboot.
do you have EDDUP_AUTO_SELECT_FILE='tplink_archer-c7-v2-US.bin' in your easyddup.ini? I see that you still need to manually select the fw file.
your fw download speed is already fast, but you can try EDDUP_USE_MULTIPART=8 to see if it can be even faster.
slycordinator wrote:
type is generally preferable to which for scripts, as type is a builtin.
root@DD-WRT:/tmp/easyddup# ./easyddup.sh -n -f
Burn of firmware will not be done.
All dd-wrt upgrade builds available online for 2021
1) 08-25-2021-r47256 c <--- current
Current build: 47256
Select a build to install (or Q): 1
********************************************************
***** WARNING: BUILD SELECTED IS ALREADY INSTALLED *****
********************************************************
Selected 08-25-2021-r47256
Files in build 08-25-2021-r47256 for TP-Link ARCHER-C7 v2
1) factory-to-ddwrt-IL.bin
2) factory-to-ddwrt-US.bin
3) factory-to-ddwrt.bin
4) tplink_archer-c7-v2-IL.bin
5) tplink_archer-c7-v2-US.bin c <--- auto selected
6) tplink_archer-c7-v2.bin
Selected tplink_archer-c7-v2-US.bin
Build not in local cache or -f option, downloading...
Downloading https://download1.dd-wrt.com/dd-wrtv2/downloads/betas/2021/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin ...
Downloading in 8 parts: 16449564 / 16449564 bytes @ 1338 kb/s (100%)
Joining 8 parts: 8
Downloaded file OK.
WARNING THIS COULD BRICK YOUR ROUTER!!!
File to burn: ./fwcache/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin
Erase nvram y/n ? n
Save user settings restore point y/n ? n
./easyddup.sh: line 452: tee: not found
WARNING: DO NOT INTERRUPT...
WAIT FOR BURN TO COMPLETE (at least 5 minutes)
Skipping firmware burn.
Skipping reboot.
Seems to be all working now, aside from not having tee but that's not a biggie.
I'll look at the scripts closer sometime to see if I can add further automation, like how DD_BOARD can give you most of the information that's used in both of those variables.
root@DD-WRT:/tmp/easyddup# ./easyddup.sh -n -f
Burn of firmware will not be done.
All dd-wrt upgrade builds available online for 2021
1) 08-25-2021-r47256 c <--- current
Current build: 47256
Select a build to install (or Q): 1
********************************************************
***** WARNING: BUILD SELECTED IS ALREADY INSTALLED *****
********************************************************
Selected 08-25-2021-r47256
Files in build 08-25-2021-r47256 for TP-Link ARCHER-C7 v2
1) factory-to-ddwrt-IL.bin
2) factory-to-ddwrt-US.bin
3) factory-to-ddwrt.bin
4) tplink_archer-c7-v2-IL.bin
5) tplink_archer-c7-v2-US.bin c <--- auto selected
6) tplink_archer-c7-v2.bin
Selected tplink_archer-c7-v2-US.bin
Build not in local cache or -f option, downloading...
Downloading https://download1.dd-wrt.com/dd-wrtv2/downloads/betas/2021/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin ...
Downloading in 8 parts: 16449564 / 16449564 bytes @ 1338 kb/s (100%)
Joining 8 parts: 8
Downloaded file OK.
WARNING THIS COULD BRICK YOUR ROUTER!!!
File to burn: ./fwcache/08-25-2021-r47256/tplink_archer-c7-v2/tplink_archer-c7-v2-US.bin
Erase nvram y/n ? n
Save user settings restore point y/n ? n
./easyddup.sh: line 452: tee: not found
WARNING: DO NOT INTERRUPT...
WAIT FOR BURN TO COMPLETE (at least 5 minutes)
Skipping firmware burn.
Skipping reboot.
Seems to be all working now, aside from not having tee but that's not a biggie.
I'll look at the scripts closer sometime to see if I can add further automation, like how DD_BOARD can give you most of the information that's used in both of those variables.
I see that you're running easyddup from /tmp/ folder. Just a reminder: that folder is on RAM and will be cleared on every reboot.
for your case, EDDUP_USE_MULTIPART=8 seems to be slower than tradtional curl, so it's better to remove/comment that line from your easyddup.ini
for fully automated operation, you can add/uncomment the following options in easyddup.ini:
Note that when EDDUP_AUTO_SELECT_LATEST=Y, the script will terminate if the current fw is already the latest version.
can you share the output of
Code:
nvram show | grep -i board
If there's some additional board info in nvram then yoyoma2 can use that to auto select the fw folder/image file.
Is there any other automation you have in mind? it may be already done/partially done by some of us, or yoyoma2 may decide to expand his easyddup script if the idea is good.
For me, I have a call-back script to do the following tasks:
Backup full nvram to bin file (@yoyoma2 sorry I'm lazy to figure out which variables to add to nvram-dd-wrt.ini)
Update/upgrade Entware packages
Write a report file so that I can copy/paste to the "new build" topic. The report file is sent to my email address after reboot.
Remove old downloaded fw files, only keep the latest 3 versions, so that the USB disk won't get full. @yoyoma2 do you think it's good to add this option to easyddup.sh?