Hi there, I’m looking into updating my Zyxel GS1900-8HP v2 to Openwrt 24.10.0. I’ve noted the update notes of “Users of Zyxel GS1900 series switches running OpenWrt 23.05 or earlier have to perform a new factory install with the initramfs image due to a changed partition layout.”
Reviewing various bits of info, it appears the steps I’m going to have to go through are:
Then use either the OEM easy installation or TFTP options which are included further up that same page and start by flashing the new 24.10.0 intramfs image to the correct partition
Boot into the new Openwrt intramfs environment and then sysupgrade using a new 24.10.0 sysupgrade image. Q. will this mean that there will no longer be a stock image saved on a backup partition because the partitions are merged, and so will that mean that the device can no longer be reverted so easily?
I’ve not used serial port access on that Zyxel switch (or on anything else in about 20yrs really) so just want to check a few extra things.
If I want to connect to that serial from a Windows 11 machine would the following cable be appropriate - https://www.amazon.co.uk/dp/B0CZHVRX2W - or does anyone have a better suggestion of device to use?
And from reviewing the image below have I got my cable order correct?
About that cable, that is a 5V TTL cable. In most cases a 3.3V is needed. The wiki doesn't tell which is the case here, but if you have a multimeter you can measure between GND and VCC. If that is 5V, you need a 5V cable.
Note: You should not connect the VCC, only GND, RX and TX.
I'd expect SOUT to be TXD, which means you connect the RXD from the cable. (The switch transmits, the cable receives). But nothing breaks if you connect it wrongly. You just won't see any data.
To confirm, the VCC connection isn't required? Is that because the unit is already powered through its own power supply, and the VCC is just there if you want to power the board via the serial cable? If that's the case would I be better off getting a 3.3v cable that is compatible with most devices in the unlikely event that I need to plug in the VCC.
All understood re the other connections, I'll go ahead and see how I get on. The website is slow at the moment (victim of its own success) but I guess I just use something like putty and use whatever baud rates/other settings that are mentioned on the toh wiki page for that device?
I don't think the board can be powered through that VCC. AFAIK the VCC is used by some Serial cables as reference voltage, or as power supply. I have a multivoltage cable here, which can use VCC to switch to the right mode. And of course all USB-TTL cable are already powered from USB.
I upgraded a GS1900-8.......I didn't revert to the OEM stock firmware in bootpartition 0, I just flashed the intramfs image, rebooted then flashed the sysupgrade image without keeping any settings then manually reconfigured the switch.
Good question boot partition 1 though not sure if the OEM firmware is still there although "fw_printsys" says it's still there
Did the same on my two GS1900-10HP. There is no need to revert to OEM firmware. You just have to boot into an updated initramfs before sysupgrading. And the easiest way to do that is by flashing the initramfs
Ah cool, I've ordered a "Waveshare FT232 USB-C to UART Module, USB to TTL (UART), Supports 3.3V/5V Logic Level, Compatible with Mac OS/Linux/Android/WinCE/Windows 7/8/8.1/10/11" for next to nothing anyway so I guess I can use that to get me into the backup partition if I soft brick it along the way. Thanks all x
So, I followed the advice on here, uploaded the 24.10 intramfs image without reverting to the OEM partition (so just using the Luci >> System >> Backup / Flash Image page, and selecting the force sysupgrade option). I changed my local IP address manually to be on the 192.168.1 subnet, and was able to access the Zyxel switch at 192.168.1.1. Then I flashed my own 24.10.0 sysupgrade (including a selection of packages and some etc/config files) and the switch came up a beauty. It's running a few VLANs and seems to be solid for now. In case it's of interest I've copied below the comparison of partition sizes.
Pre upgrade (on 23.05.5 that I'd faffed around with on various occassions)
In case anyone is on their own learning journey, copied below are the commands I used on my wsl instance running the local image builder to create my own image for this device:
# Install the zstd tool which allows the new package format to be unpacked
sudo apt-get install zstd
unzstd openwrt-imagebuilder-*.tar.xz.zst
tar -x -f openwrt-imagebuilder-*.tar.xz
cd openwrt-imagebuilder-*
# create the files directories to hold the settings files I wanted to copy over to my own sysupgrade image
mkdir -p files/etc/config
mkdir files/etc/crontabs
mkdir files/etc/dropbear
# Use SCP to copy the specific config files I wanted to copy across.
## NB. I had to run "opkg update && opkg install openssh-sftp-server on the router before the commands below would work
scp root@[IP ADDRESS of switch - eg. 192.168.1.1]:/etc/config/dhcp files/etc/config/
scp root@192.168.1.1:/etc/config/dropbear files/etc/config/
scp root@192.168.1.1:/etc/config/firewall files/etc/config/
scp root@192.168.1.1:/etc/config/luci files/etc/config/
scp root@192.168.1.1:/etc/config/network files/etc/config/
scp root@192.168.1.1:/etc/config/uhttpd files/etc/config/
scp root@192.168.1.1:/etc/uhttpd* files/etc/
scp root@192.168.1.1:/etc/crontabs/* files/etc/crontabs/
scp root@192.168.1.1:/etc/dropbear/* files/etc/dropbear/
scp root@192.168.1.1:/etc/passwd files/etc/
scp root@192.168.1.1:/etc/shadow files/etc/
# then the command below built my image for me
# -j10 below I think gets wsl to use more cores?
# NB. I removed the mbedtls library and installed the wolfssl library instead because I'm running wolfssl on all my other routers. The reason for this is it appears I get better wireless overall with wolfssl
make image -j10 \
PROFILE="zyxel_gs1900-8hp-v2" \
PACKAGES="-libustream-mbedtls base-files ca-bundle dropbear ethtool firewall4 fstools kmod-gpio-button-hotplug libc libgcc libustream-wolfssl logd mtd netifd odhcp6c opkg procd-ujail uboot-envtools uci uclient-fetch urandom-seed urngd luci" \
FILES="files" \
DISABLED_SERVICES="dnsmasq firewall odhcpd"
One last question - because I'm not running the firewall from this device would there be any concerns about adding -firewall4 to my packages list to save even more space on the image?
Thanks to all who replied, and again thanks to the devs/testers/contributors
@happydashery@bmork Would you mind checking your log file for errors after re-boot please? I've got a few errors but I'm pretty sure they were there on the previous version too. Everything seems to be working ok.
Wed Feb 12 14:45:46 2025 kern.err kernel: [ 0.839270] OF: Bad cell count for /soc/spi@1200/flash@0/partitions
Wed Feb 12 14:45:46 2025 kern.err kernel: [ 0.846457] OF: Bad cell count for /soc/spi@1200/flash@0/partitions
Wed Feb 12 14:45:46 2025 kern.err kernel: [ 10.081400] rtl83xx_fib_event_work_do: FIB4 default rule failed
Wed Feb 12 14:45:46 2025 kern.err kernel: [ 10.088322] rtl83xx_fib_event_work_do: FIB4 default rule failed
Wed Feb 12 14:45:46 2025 kern.err kernel: [ 23.215747] rtl83xx_fib4_del: no such gateway: 0.0.0.0
Wed Feb 12 14:45:46 2025 kern.err kernel: [ 23.221574] rtl83xx_fib4_del: no such gateway: 0.0.0.0
Wed Feb 12 14:45:46 2025 kern.err kernel: [ 23.227633] rtl83xx_fib4_del: no such gateway: 0.0.0.0
I can confirm that I have those messages as well. And many more
The DSA driver is so noisy that I've just assumed those messages are debugging noise. I had to silence a few other messages just to get a usable console. But there are plenty more left.
Don't know about the cell count message. It looks like some data is missing or wrong in the DTS. Haven't noticed any resulting problems, but that doesn't prove anything of course.
EDIT: FWIW, I get the same error message on unrelated devices and targets like the MT7621 based U6 Lite:
root@u6-1:~# dmesg|grep cell
[ 1.475820] OF: Bad cell count for /palmbus@1e000000/spi@b00/flash@0/partitions
[ 1.483159] OF: Bad cell count for /palmbus@1e000000/spi@b00/flash@0/partitions
[ 1.515413] OF: Bad cell count for /palmbus@1e000000/spi@b00/flash@0/partitions
[ 1.529412] OF: Bad cell count for /palmbus@1e000000/spi@b00/flash@0/partitions
So nothing to worry about in the realtek target context.
I'm pretty sure I've seen the bad cell count ones but not sure about the rest. I'll take a look when I get a chance (might not be till Wednesday) and will let you know. I've noted @bmork reply and I've also got a unified U6 LR and a couple of other devices so will check those as well.
But I suspect it's related to the nvmem patches exporting and using of_device_make_bus_id(), which calls of_translate_address(). This might end up printing that error message and return OF_BAD_ADDR, which is handled just fine by the caller.
I.e., the message level is wrong for the current usage. It's a debug message at best
Can I do the following?
Take a backup on OpenWrt 23.05.5
Flash the 24.10 intramfs through the openwrt upgrade then sysupgrade
load a backup and restore the config
I'm pretty sure that would work but not tested it myself. The only potential issue that might arise is one of the other config files that gets backed up being incompatible with the switch from 23.05 to 24.10. Thinking out loud I wonder if fstab is included and if that might cause problems?
Looks like it worked but I am pretty sure i am missing a bunch of vlan interfaces and bridge devices though on the GUI side, on the CLI side everything is configured the same.