You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WNDR3800 rejects Openwrt factory images if the Openwrt version string is too long. Up-to-date git version 2.17.1 generates too long build version ID for openwrt-18.06 and master.
I tested only WNDR3800, but I assume that the same goes for other Netgear routers using the TFTP recovery mode.
I can fix my own build by forcing a shorter git hash in getver.sh
TFTP log of r7161-c8677ca89e:
Bytes transferred = 6946949 (6a0085 hex)
HW ID on board: 29763654+16+128
HW ID on image: 29763654+16+128
Firmware Image HW ID matched Board HW ID
MODEL ID on board: WNDR3800
MODEL ID on image:
Firmware Image MODEL ID do not match Board model ID
Board MODEL ID mismatch,it is forbidden to be written to flash!!
Based on that I determine that the field "version" has a maximum length that will get exceeded in buildhosts with up-to-date git 2.17
Background:
the "factory" image of WNDR3800 built by me in Ubuntu 18.04 for master or 18.06 does not install into the router in the TFTP flash mode. But the factory image for 17.01 installs ok, and so do buildbot snapshots. All of them install ok as sysupgrades, so it is about the factory image header
The error seems to be related to the router model detection in the header. For some reason the model detection goes wrong, although the model itself is quite similar way in the image header. It seems that the "version" field's length is restricted and we are now surpassing that. That field itself is not even mentioned in the TFTP console log.
The only practical difference between for the image generation in my build (in Ubuntu-18.06) and buildbot (some older hosts) is the underlying git. The new git versions generates slightly longer version ID by default as the hash is shown as 10 digits instead of 7. So it is possible that one other string in the header is too long. I will test the idea, but strange.
EDIT: my guess proved to be right.
I can fix my own build by forcing a shorter git hash in getver.sh
--- a/scripts/getver.sh
+++ b/scripts/getver.sh
@@ -40,7 +40,7 @@ try_git() {
REV="${UPSTREAM_REV}+$((REV - UPSTREAM_REV))"
fi
hnyman:
WNDR3800 rejects Openwrt factory images if the Openwrt version string is too long. Up-to-date git version 2.17.1 generates too long build version ID for openwrt-18.06 and master.
I tested only WNDR3800, but I assume that the same goes for other Netgear routers using the TFTP recovery mode.
I can fix my own build by forcing a shorter git hash in getver.sh
TFTP log of r7161-c8677ca89e:
Bytes transferred = 6946949 (6a0085 hex) HW ID on board: 29763654+16+128 HW ID on image: 29763654+16+128 Firmware Image HW ID matched Board HW ID
MODEL ID on board: WNDR3800
MODEL ID on image:
Firmware Image MODEL ID do not match Board model ID
Board MODEL ID mismatch,it is forbidden to be written to flash!!
Header:
device:WNDR3800 version:VOpenWrt.r7161-c8677ca89e region: hd_id:29763654+16+128
TFTP log of r7161-c8677ca:
Bytes transferred = 6619269 (650085 hex) HW ID on board: 29763654+16+128 HW ID on image: 29763654+16+128 Firmware Image HW ID matched Board HW ID
MODEL ID on board: WNDR3800
MODEL ID on image: WNDR3800
Firmware Image MODEL ID matched Board model ID
Header:
device:WNDR3800 version:VOpenWrt.r7161-c8677ca region: hd_id:29763654+16+128
Otherwise exactly same build, but shorted hash forced in scripts/getver.sh
Does not work: master device:WNDR3800 version:VOpenWrt.r7161-c8677ca89e region: hd_id:29763654+16+128 18.06 device:WNDR3800 version:VOpenWrt.r6995-ba204d941c region: hd_id:29763654+16+128
Works: master my build (short hash) device:WNDR3800 version:VOpenWrt.r7161-c8677ca region: hd_id:29763654+16+128 17.01 my build device:WNDR3800 version:VLEDE.r3898-4a38c0cad5 region: hd_id:29763654+16+128 master buildbot: device:WNDR3800 version:VOpenWrt.r7161-c8677ca region: hd_id:29763654+16+128 18.06 buildbot: device:WNDR3800 version:VOpenWrt.r7009-48c5d6a region: hd_id:29763654+16+128 17.01 buildbot: device:WNDR3800 version:VLEDE.r3909-b6a1f43 region: hd_id:29763654+16+128
Based on that I determine that the field "version" has a maximum length that will get exceeded in buildhosts with up-to-date git 2.17
Background:
the "factory" image of WNDR3800 built by me in Ubuntu 18.04 for master or 18.06 does not install into the router in the TFTP flash mode. But the factory image for 17.01 installs ok, and so do buildbot snapshots. All of them install ok as sysupgrades, so it is about the factory image header
The error seems to be related to the router model detection in the header. For some reason the model detection goes wrong, although the model itself is quite similar way in the image header. It seems that the "version" field's length is restricted and we are now surpassing that. That field itself is not even mentioned in the TFTP console log.
The only practical difference between for the image generation in my build (in Ubuntu-18.06) and buildbot (some older hosts) is the underlying git. The new git versions generates slightly longer version ID by default as the hash is shown as 10 digits instead of 7. So it is possible that one other string in the header is too long. I will test the idea, but strange.
EDIT: my guess proved to be right.
I can fix my own build by forcing a shorter git hash in getver.sh
--- a/scripts/getver.sh
+++ b/scripts/getver.sh
@@ -40,7 +40,7 @@ try_git() {
REV="${UPSTREAM_REV}+$((REV - UPSTREAM_REV))"
fi
The text was updated successfully, but these errors were encountered: