easyddup a simple upgrade/downgrade utility

Post new topic   Reply to topic    DD-WRT Forum Forum Index -> General Questions
Goto page Previous  1, 2, 3, 4, 5, 6, 7, 8, 9  Next
Author Message
yoyoma2
DD-WRT User


Joined: 24 Sep 2016
Posts: 211

PostPosted: Fri Apr 23, 2021 4:21    Post subject: Reply with quote
Uploaded a new version (April 22nd) that adds EDDUP_TARGET_PARTITION support to easyddup.ini (see easyddup.ini.sample for details).

I do not have a router with multiple partitions so I can't test this. If you look at the code for write, it seems that it ignores the target partition argument and intelligently/automatically alternates between linux and linux2 so it should work.

WARNING: Enable at own risk (it's disabled by default). Users experienced with more than one firmware partition can chime in.
Sponsor
00diabolic
DD-WRT User


Joined: 17 Aug 2011
Posts: 70

PostPosted: Wed Apr 28, 2021 18:05    Post subject: Can I use this to compare settings between 2 NVram bkups? Reply with quote
Hi,

Looking at this mainly focusing updates but I have been trying to find a way to compare 2 NVram backup bin files.

Can I load this up and simply output the INI files to compare settings between 2 build numbers? When I tried this with CSV conversion the settings were in different locations and could not be compared easily. I'm assuming a settings INI backup from build XYZ will have settings in your INI in a different location than Build ZWB? OR does your app standardize the ini settings backup across brainslayer builds?
SuninderSingh
DD-WRT Novice


Joined: 05 Sep 2017
Posts: 28
Location: IN

PostPosted: Thu Apr 29, 2021 9:36    Post subject: Reply with quote
yoyoma2 wrote:
With the hundreds of router model, router revision, distribution type, kernel combinations; that approach will become a maintenance nightmare. As I stated earlier, I use the community build and thus don't install/upgrade with easyddup so my maintenance contributions to easyddup are and will remain minimal.

If someone creates a gitlab project (@rkboni used gitlab on the community build) I'll link to it in the OP and development would continue there. Keep in mind that enthusiasm wanes and projects become abandonned (e.g. @al_c and yamon, @rkboni is no longer active on the community build...).


First of thanks for this script, appreciate efforts. Second is there by any chance to use in 4/32 or 8/32 router where no USB support?

_________________
>>TP-Link TL-WR841ND v9
>>DD-WRT v3.0-r43397 std (06/13/20)
>>TP-Link TL-WR841ND v9
>>DD-WRT v3.0-r45735 std (02/11/21)
yoyoma2
DD-WRT User


Joined: 24 Sep 2016
Posts: 211

PostPosted: Thu Apr 29, 2021 17:46    Post subject: Reply with quote
@00diabolic: Read QuickStart.txt which is all about the nvram-save tool. IONK wrote the included cleanupCB.sh which removes duplicate nvram backups to save USB storage space. He was able to ignore start_time and end_time variables which change on every reboot. You could look at his code. As mentioned in the OP, nvram-dd-wrt.ini needs to be augmented to store all the settings you care about. A nvram-restore script gets generated to perform the actual restore. I ported nvram-save to dd-wrt but didn't write it (see link in OP).

@SuninderSingh: Unfortunately you need a USB port. BS could theoretically include a USB-less stripped down "easyddup light" in official builds but I wouldn't hold my breath.
IONK
DD-WRT User


Joined: 19 Aug 2011
Posts: 256

PostPosted: Sun May 16, 2021 12:25    Post subject: Reply with quote
Original post quoted here:
IONK wrote:
Somehow there's no file here DD-WRT website
the other 2 links are ok HTTPS & FTP

kernel-panic69 wrote:
try another if a link does not work
currently easyddup doesn't work because it relies on this DD-WRT website link only. Will this link be fixed anytime soon?

@yoyoma2 Are you willing to add the option to switch the URL used for fetching builds? I tried swapping the link in easyddup.sh but it didn't work, probably because the regex is only intended for the original webpage

_________________
▫ RSS feed for DD-WRT releases: https://politepol.com/fd/NfCoAP5bUJXU
easyddup - A simple upgrade/downgrade utility by yoyoma2
yoyoma2
DD-WRT User


Joined: 24 Sep 2016
Posts: 211

PostPosted: Sun May 16, 2021 18:26    Post subject: Reply with quote
New version (May 16th).

Change:

If no builds are found on the website, fallback to the https link that @IONK posted in the previous post. Seems to work here. Let me know how it goes as I did minimal testing.
IONK
DD-WRT User


Joined: 19 Aug 2011
Posts: 256

PostPosted: Sun May 16, 2021 21:32    Post subject: Reply with quote
yoyoma2 wrote:
New version (May 16th).

Change:

If no builds are found on the website, fallback to the https link that @IONK posted in the previous post. Seems to work here. Let me know how it goes as I did minimal testing.
it works for me, thanks for the update
_________________
▫ RSS feed for DD-WRT releases: https://politepol.com/fd/NfCoAP5bUJXU
easyddup - A simple upgrade/downgrade utility by yoyoma2
yoyoma2
DD-WRT User


Joined: 24 Sep 2016
Posts: 211

PostPosted: Sun May 16, 2021 23:28    Post subject: Reply with quote
Great! Thanks for the feedback @IONK.

Hey my 200th post. I'll give @kernel-panic69 a run for his money... Laughing
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 9043
Location: Texas, USA

PostPosted: Mon May 17, 2021 3:43    Post subject: Reply with quote
I doubt it, I'm a post whore Twisted Evil

I had just asked if there were a way to make it poll more than one resource in the build thread. If you see the ticket that was opened, there are 3 official and one unofficial resources to download from. P.S. I emailed BrainSlayer about the website issue, no response yet.

_________________
Official Forum Rules, Guidelines & Helpful InformationFirmware FAQInstallation WikiWhere Do I Download Firmware?
DON'T use Chromium-based browsersRTFM/STFW TL;DR is NOT an excuse. • Why Should I Care What Color the Bikeshed Is?
Please DO NOT PM me with questions; Ask in the forum. ---------------------- Linux User #377467 counter.li.org / linuxcounter.net
IONK
DD-WRT User


Joined: 19 Aug 2011
Posts: 256

PostPosted: Sun May 30, 2021 13:17    Post subject: Reply with quote
@yoyoma2 when I used -d with EDDUP_AUTO_SELECT_LATEST=Y, the script auto quit as below:
Code:
root@RB:/opt/easyddup# ./easyddup.sh -r reva -d

All dd-wrt downgrade builds available online for 2021

1)      01-01-2021-r45229
2)      01-09-2021-r45385
.
.   (text removed)
.
48)     05-28-2021-r46788 c
49)     05-30-2021-r46816 c      <--- current

Current build: 46816
AUTO_SELECT_LATEST mode is on and you are up to date.  Quitting

probably it's better to ignore the EDDUP_AUTO_SELECT_LATEST=Y flag when there is -d

_________________
▫ RSS feed for DD-WRT releases: https://politepol.com/fd/NfCoAP5bUJXU
easyddup - A simple upgrade/downgrade utility by yoyoma2
yoyoma2
DD-WRT User


Joined: 24 Sep 2016
Posts: 211

PostPosted: Tue Jun 01, 2021 22:31    Post subject: Reply with quote
New version (June 1st).

Change:

The AUTO_SELECT_LATEST mode is now turned off in downgrade mode. Good catch @IONK.
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 9043
Location: Texas, USA

PostPosted: Mon Jun 14, 2021 0:04    Post subject: Reply with quote
cjnaz wrote:
I'm confused. I thought I was working to improve this project by covering a wider use cases (DDNS and guest WiFi), but then my posts have disappeared. What wrong did I commit?


I guess I didn't know nvram variables were even involved in this utility, my mistake. Feel free to re-post.

EDIT: I honestly do not keep up with this thread. I guess I will just let the train derail itself and not interject any further.

_________________
Official Forum Rules, Guidelines & Helpful InformationFirmware FAQInstallation WikiWhere Do I Download Firmware?
DON'T use Chromium-based browsersRTFM/STFW TL;DR is NOT an excuse. • Why Should I Care What Color the Bikeshed Is?
Please DO NOT PM me with questions; Ask in the forum. ---------------------- Linux User #377467 counter.li.org / linuxcounter.net


Last edited by kernel-panic69 on Mon Jun 14, 2021 5:04; edited 1 time in total
yoyoma2
DD-WRT User


Joined: 24 Sep 2016
Posts: 211

PostPosted: Mon Jun 14, 2021 3:41    Post subject: Reply with quote
@cjnaz I briefly saw your post and this is exactly the kind of help I was asking for in the OP. The nvram-save tool (see QuickStart.txt) is a mature utility that was ported from another project but nvram-dd-wrt.ini needs some variable additions to cover all the user settings you care about in dd-wrt.

To find out a setting's variable name, for example if I'm searching for a gateway related setting:

nvram show | grep gateway

and find the variable name is lan_gateway (whatever precedes the equal sign). Then you confirm you're looking at the correct variable by changing the setting in the GUI, click Save (not Apply Settings) and observe the variable again to see if it changed.

nvram get lan_gateway

Then change the setting back in the GUI to what you like and save again. Some variable names are less obvious and will require some trial and error to identify. If you share your variable additions, I'll add them to the nvram-dd-wrt.ini in the tar distribution.

@kernel-panic69: If people only care about the upgrade/downgrade easyddup features then you're right nvram variable stuff does not apply. The nvram-save utility is called by easyddup if you want to create/use a settings restore point. If people help set up nvram-dd-wrt.ini properly, then the error prone/tedious task of manually re-entering settings in the GUI would almost be a thing of the past.
cjnaz
DD-WRT Novice


Joined: 18 Jan 2012
Posts: 20

PostPosted: Mon Jun 14, 2021 3:58    Post subject: Reply with quote
Gee, I guess I shoulda kept a copy of my posts.

Ok, so per the HELP NEEDED in the OP, below I list several NVRAM vars that I've added to my local nvram-dd-wrt.ini file, as the OP suggests. I cannot get the DDNS and Guest WiFi settings to work.

My home router setup has a few differences from the baseline setup of this tool. My "Custom" DDNS setup has ddns_enable="5". I added these vars to the .ini file and the webUI looks correct but the ddns log shows "DYNDNS Server response: HTTP/1.1 404 Not Found". Vars added:

Code:
ddns_conf
ddns_custom_5
ddns_hostname_5
ddns_passwd_5
ddns_url
ddns_username_5


My setup also has a guest WiFi wl0.1 that is isolated from my LAN (per https://wiki.dd-wrt.com/wiki/index.php/Guest_WiFi_%2B_abuse_control_for_beginners). After the restore, connections to the Guest network apparently cannot get a DHCP IP issued, per the syslog: "Jun 13 16:06:34 Router daemon.warn dnsmasq-dhcp[1428]: no address range available for DHCP request via wl0.1". Again, I don't see anything misplaced in the webUI.

Vars added:

Code:
bat_wl0.1_bridge
mdhcpd
wl0.1_mode
wl0.1_ssid
wl0.1_ap_isolate
wl0.1_bridged
wl0.1_multicast
wl0.1_nat
wl0.1_isolation
wl0.1_ipaddr
wl0.1_netmask
bridges
bridgesif_count
probe_working
wl0.1_akm
wl0.1_auth_mode
wl0.1_authmode
wl0.1_radius_ipaddr
wl0.1_wpa_psk
wl0X1_security_mode
wl0.1_crypto


My method for finding needed vars was to compare the sorted nvram-save.sh generated nvram-all file from my initial working setup versus the .ini file in the easyddup distribution.
yoyoma2
DD-WRT User


Joined: 24 Sep 2016
Posts: 211

PostPosted: Mon Jun 14, 2021 14:41    Post subject: Reply with quote
There must be a variable different between the nvram-all from your working setup and the restored non-working nvram-all variables.

You tried rebooting the router right? I don't trust "Apply Settings" in all cases.

For DDNS your variable additions seem good for the case 5 code. All the DDNS variables are listed here but you probably only want to mess with the GUI settings related ones. You could look at what the code is doing when that error message is produced.

If all the GUI settings look right then you're almost there...
Goto page Previous  1, 2, 3, 4, 5, 6, 7, 8, 9  Next Display posts from previous:    Page 8 of 9
Post new topic   Reply to topic    DD-WRT Forum Forum Index -> General Questions All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum