FreeBSD-11.2 routing and networks
James B. Byrne
byrnejb at harte-lyne.ca
Mon Jan 7 16:16:00 UTC 2019
On Mon, January 7, 2019 11:06, Odhiambo Washington wrote:
> On Mon, 7 Jan 2019 at 19:01, James B. Byrne via freebsd-questions <
> freebsd-questions at freebsd.org> wrote:
>
>> I am working on a FreeBSD-11.2p17 host where I must change the IP
>> address and gateway frequently to carry out tests. Following making
>> such changes I have tried resetting the network interfaces and
>> routing tables by use of the command:
>>
>> service netif restart && service routing restart &
>>
>> However, I have discovered that this does not have the desired
>> effect and I am reduced to restarting the host system to make
>> such changes.
>>
>> Is there something else I should be doing?
>>
>>
> When you are physically on the machine's console, this is easy:
> Assume your interface is called em0
>
>
> ifconfig em0 down
> ifconfig em0 inet n.n.n.n netmask z.z.z.z up
> route add default y.y.y.y
>
> Then run your tests.
> When you reboot, the IP/MASK/ROUTE specified in rc.conf takes effect
>
As it happens, for the moment this case is true, I do have console
access. However, the configuration testing that I am doing locally
will need to be applied to a remote host at some point, and the
console will not be an option. Is there no way to make FreeBSD reset
the network connection and routing tables remotely?
--
*** e-Mail is NOT a SECURE channel ***
Do NOT transmit sensitive data via e-Mail
Do NOT open attachments nor follow links sent by e-Mail
James B. Byrne mailto:ByrneJB at Harte-Lyne.ca
Harte & Lyne Limited http://www.harte-lyne.ca
9 Brockley Drive vox: +1 905 561 1241
Hamilton, Ontario fax: +1 905 561 0757
Canada L8E 3C3
More information about the freebsd-questions
mailing list