RE: ifconfig and route problem.
From: Anton Blajev (valqk_at_lozenetz.net)
Date: 02/24/04
- Previous message: Andrea Venturoli: "Bad loopback traffic not stopped by ipfw."
- Maybe in reply to: DrumFire: "ifconfig and route problem."
- Next in thread: Ruslan Ermilov: "Re: ifconfig and route problem."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: freebsd-net@freebsd.org Date: Tue, 24 Feb 2004 18:57:51 +0200
Please stop flooding. :)
RTFM -> man ifconfig ; man route
you CAN'T change your NIC's ip whithough deleteing your default route.
why's that?
well... route add default 192.168.0.1
when you add default gw it must be reachable on your network.
when you change ip, you have to add ne w route because you;ve changed
network.
aka you can patch ifconfig command to check if you change ip address to
other form your network(192.168.0.0 for example) and don't delete
default route... dunno ... I think ifconfig deletes it. not pretty sure.
a simple desicion will be a bash script:
---- ./chaddr.sh rl0 192.168.0.50 255.255.255.0 192.168.0.1
###############i-face ip nmask gw
#!/bin/sh
/sbin/ifconfig $0 $1 $3
/sbin/route add default 1$4
_______________________________________________
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"
- Previous message: Andrea Venturoli: "Bad loopback traffic not stopped by ipfw."
- Maybe in reply to: DrumFire: "ifconfig and route problem."
- Next in thread: Ruslan Ermilov: "Re: ifconfig and route problem."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|