I have two problems with this script, would be nice to solve them
for Mandrake.


1) (mdk bug?)  Lots of errors mentioning `basename'.  Reason: running
code for DHCP even if it's not enabled for interface.  Patch below.

2) (rh bug/prob?) Lines beginning "this is broken! it's only here for
compatibility with old RH systems".  Can we remove this duff code
please?  The reason is: I want different gateways for different
interfaces, but this code results in duplicating gateway which is set
in /etc/sysconfig/network-scripts/ifcfg-eth<nn> instead of global file
/etc/sysconfig/network  See my netstat below 

Cheers,

 - David.



[da@avocado da]$ netstat -r
Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface
avocado.davesne *               255.255.255.255 UH        0 0          0 eth0
129.215.96.0    *               255.255.255.0   U         0 0          0 eth0
192.168.154.0   *               255.255.255.0   U         0 0          0 vmnet1
127.0.0.0       *               255.0.0.0       U         0 0          0 lo
default         jura.dcs.ed.ac. 0.0.0.0         UG        0 0          0 eth0
default         jura.dcs.ed.ac. 0.0.0.0         UG        0 0          0 eth0  





*** /tmp/ifup   Mon May  1 14:22:35 2000
--- /tmp/ifup.new       Mon May  1 14:23:39 2000
***************
*** 104,109 ****
--- 104,110 ----
      fi
  fi    
  
+ if [ -n "$DHCP_CLIENT" ]; then
  DHCP_ARGS=
  case $(basename $DHCP_CLIENT) in
      pump|dhcpcd)
***************
*** 119,124 ****
--- 120,126 ----
      DHCP_ARGS="$DEVICE"
      ;;
  esac
+ fi
        
  if [ -n "$DHCP" ];then
      echo -n "Determining IP information for $DEVICE via $(basename $DHCP_CLIENT)..."

Reply via email to