NethServer Version: 7.8.2003 (final)
Module: network
I’m installing on Hetzner VPS. I tried a lot of time, manual installation, standard, …
When it restart it show me to connect to corret ip addres 135.x.x.x but if I go into shell login , via remote KVM, I see with ipconfig that server ethernet is mapped on 192.168.1.1
How I can set corret IP, subnet and gateway trought commadn line shell?
Fabio
P-Soft
GG_jr
(Gabriel GHEORGHIU)
August 13, 2020, 2:01pm
2
Hi @Fabio_Codebue ,
I think that you faced with this, like I did:
NethServer Version: 7.3 Final
Module: Network
During the installation of the NS 7.3 Final from ISO, I have set the Green NIC with the following parameters:
IP: 192.168.1.2
NM: 255.255.255.0
GW: 192.168.1.1
DNS: 192.168.1.1
After the installation was finished, the NS has automatically rebooted.
In browser, I have typed https://192.168.1.2:980 for first login and first setup, but the server does not responded.
When I have checked on the NS server with “ifconfig” to see the settings of th…
The solution:
https://docs.nethserver.org/en/v7/installation.html#interactive-and-manual-modes
Kind regards,
Gabriel
@GG_jr sorry but I already red those pages… and there is not a way to set green adapter to specific static address.
I can’t understand why it not get IP from DHCP…
If I install a centOS 7.8 it got it…
mrmarkuz
(Markus Neuberger)
August 13, 2020, 5:02pm
5
Please check if this solution for Hetzner static IP configuration works for you:
In the end, this was actually a combination of 3 issues.
1. There was unnecessary shorewall spam at the console
It turns out I already raised this as a separate issue . I have put the answer in the other thread.
2. Hetzner requires static routes to allow the static IPs to work
Details (it's kind of long!) Thanks to <a class="mention" href="/u/mrmarkuz">@mrmarkuz</a> for figuring this one out too and for improvement from <a class="mention" href=&…
1 Like
I solved in this way
db networks set eno1 ethernet role green ipaddr x.x.x.x netmask 255.255.255.128 network x.x.x.0 onboot yes bootproto static
and
route ad default gw x.x.x.x
1 Like
This will not survive a network reconfiguration.
You should use the configuration database as you did with the network.
Adapt the following command:
db routes set 0.0.0.0/0 static Description “default gw” Device eno1 Metric “” Router IP_DEFAULT_GATEWAY
You can apply the configuration with signal-event interface-update
.
Warning: you could loose connection in case of mistakes.
3 Likes
Thanks a lot Filippo…done
djx
(DJX)
August 22, 2020, 9:56pm
9
This helped me too, thanks. And in case other users prefer to not use the command line, this can also be done in the Cockpit Admin UI under Network: