I'm using Manjaro but this is valid for Arch.
Install atftp
and net-tools
. I'm using trizen
and ohmyzsh aliases.
trin atftp net-tools
Set up OEM firmware in TFTP server home
cd /tmp
wget ftp://ftp2.zyxel.com/ARMOR_Z2_(NBG6817)/firmware/ARMOR%20Z2%20(NBG6817)_V1.00(ABCS.9)C0.zip
unzip ARMOR\ Z2\ \(NBG6817\)_V1.00\(ABCS.9\)C0.zip
rm NBG*
rm ARMOR\ Z2\ \(NBG6817\)_V1.00\(ABCS.9\)C0.zip
mv V1.00\(ABCS.9\)C0.bin ras.bin
mv ras.bin /srv/atftp
cd /srv/atftp
sudo chown atftp:atftp ras.bin
Start and check TFTP server
# BEFORE Starting
# change your LAN ip to 192.168.1.99
# start tftp server
sudo systemctl start atftp.service
# check status
sudo systemctl status atftp.service
# check you can retrieve the file
cd ~
atftp 192.168.1.99
get ras.bin
quit
# check the file is in the current directory
ls -lah ras.bin
Before rebooting the router with the WPS button pressed, make sure you open a terminal and run:
journalctl /usr/bin/atftpd -f
You should see something similar to this, while rebooting the router:
nov 10 17:45:42 yolosan-pc atftpd[27663]: Serving ras.bin to 192.168.1.1:2383
nov 10 17:45:42 yolosan-pc atftpd[27663]: timeout option -> 5
nov 10 17:45:42 yolosan-pc atftpd[27663]: blksize option -> 1468
nov 10 17:45:46 yolosan-pc atftpd[27663]: Server thread exiting
It means that the router got the firmware.