J.A. Magallon wrote: > On 2003.01.16 Frederic Lepied wrote: > But I do not think it is the way to go... There can be tons of exceptions, old > cards and new cards which have a driver but it still does not support mii. > Filling a list with exceptions is so error prone... > Wouldn't it be better to skip the ifplug-ging if ONBOOT = yes, and force ifcfg ? > And some way to test if mii work, and fall back to 'traditional-slow-but-safe' > method ? > > AH, and I have also found this: > > werewolf:~# ifstatus -v lo > lo: > SIOCETHTOOL failed (Operation not supported) > SIOGGMIIPHY failed (Operation not supported) > SIOCDEVPRIVATE failed (Operation not supported) >
Why not just test the exit status of 'ifstatus $DEV' ? It seems exit codes are as follows: 1: Failure (Operation not supported) 2: supported and connected (link beat detected) 3: unplugged So, of course, only if exit status is 3 should the device not be brought up. This would solve both types of issues AFAICS. Buchan -- |--------------Another happy Mandrake Club member--------------| Buchan Milne Mechanical Engineer, Network Manager Cellphone * Work +27 82 472 2231 * +27 21 8828820x121 Stellenbosch Automotive Engineering http://www.cae.co.za GPG Key http://ranger.dnsalias.com/bgmilne.asc 1024D/60D204A7 2919 E232 5610 A038 87B1 72D6 AC92 BA50 60D2 04A7
