Results 1 to 4 of 4
Is there a way to set the equv of "ifconfig eth0:0 192.168.10.12 netmask 255.255.255.0 broadcast 192.168.10.255" through /etc/rc.inet1.conf ??...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 08-05-2006 #1
rc.inet1.conf - multiple ips
Is there a way to set the equv of "ifconfig eth0:0 192.168.10.12 netmask 255.255.255.0 broadcast 192.168.10.255" through /etc/rc.inet1.conf ??
- 08-05-2006 #2Linux Enthusiast
- Join Date
- Jun 2005
- Posts
- 668
Hi
I believe this feature was added to rc.inet1.conf in 10.2
anyway
try this, I see that rc.inet1 does this:
anyway, I believe in rc.inet1.conf if you set IFNAME too, you can specify the interface, you can try it at least.Code:############################ # DETERMINE INTERFACE LIST # ############################ # Compose a list of interfaces from /etc/rc.d/rc.inet1.conf (with a maximum # of 6 interfaces, but you can easily enlarge the interface limit # - send me a picture of such a box :-). # If a value for IFNAME[n] is not set, we assume it is an eth'n' interface. # This way, the new script is compatible with older rc.inet1.conf files. # The IFNAME array will be used to determine which interfaces to bring up/down. MAXNICS=6 i=0 while [ $i -lt $MAXNICS ]; do IFNAME[$i]=${IFNAME[$i]:=eth${i}} i=$(($i+1)) done if [ "$DEBUG_ETH_UP" = "yes" ]; then echo "/etc/rc.d/rc.inet1: List of interfaces: '${IFNAME[@]}'" | $LOGGER fi
at the end of your /etc/rc.d/rc.inet1.confCode:# Config information for eth0:0 IFNAME[7]="eth0:0" IPADDR[7]="192.168.0.100" NETMASK[7]="255.255.255.0" USE_DHCP[7]="no" DHCP_HOSTNAME[7]=""
I'm not sure it'll work but its worth an attempt.
- 08-05-2006 #3
nope that doesn't work kern... really good idea.. I really don't think there is a way.. Guess its just gonna have to be a shell script and a cron job
.. thanx anway.
- 08-05-2006 #4Linux Enthusiast
- Join Date
- Jun 2005
- Posts
- 668
did you try a different number than 7? I just noticed $MAXNICS is 6
*shrug*


Reply With Quote
