
Posted on • Edited on • Originally published atanasrar.github.io
Netinstall MikroTik on Linux
Background
I haveRB941-2nD-TC (hAP-Lite2)
and it seem I misconfigured, so I need to reset configuration using netinstall technique.
Requirements
- RouterOS base on your router architecture (in my case isSMIPS).
- Netinstall (CLI Linux).
- Plug out router from powerline.
Download all requirements files fromhttps://mikrotik.com/download, and selectRouterOS version (in my case isRouterOS v6).
Setup
Files
Extract all files to single folder, so we can work with the files easily.
Disable Internet Interface
Disable all internet interface such as WiFi, and only leaving with Ethernet.
IP Static
Usingip
command.
sudoip addr add 192.168.88.2/24 dev <interface>;sudoiplink setdev <interface> up
Usingifconfig
command.
sudoifconfig <interface> 192.168.88.2/24 up
Where<interface>
is your ethernet interface name, you can print list ethernet interface usingnetstat -i
, something likeeth*
orenp0s*
is your interface.
IP Gateway
Usingroute
command.
sudoroute add default gw 192.168.88.1 <interface>
Check IP
Usingroute
command to check if we success to setup IP.
route-n
It will print something like this.
Kernel IP routing tableDestination Gateway Genmask Flags Metric Ref Use Iface0.0.0.0 192.168.88.1 0.0.0.0 UG 0 0 0 enp0s25192.168.88.0 0.0.0.0 255.255.255.0 U 0 0 0 enp0s25
Netinstall
Runnetinstall
withsudo
.
sudo ./netinstall-r-a 192.168.88.1 <routeros>
- Plug ethernet cable from PC to router.
- Press reset button on router.
- Plug router to powerline.
Result
My netinstall result.
Known Issues
- ### Only Show PXE client
Disable all interface except ethernet.
- ### FAILED TO REPLY
Make sure you set IP gateway.
- ### Using server IP: 0.0.0.0
Make sure you plug out router from powerline before you run netinstall.
References
Top comments(0)
For further actions, you may consider blocking this person and/orreporting abuse