Eddie Wilson wrote:
> 
> I downloaded the v3.tar from Sangoma and it seems to work. I get the bootup
> errors referred to. I also have to manually run wanconfig and reload the
> network script.
> 
> Any ideas on how I can get the card activated before the network script
> runs during boot?

OK, I've been meaning to post this for feedback for a couple weeks ;>

First, we need to understand the difference between a device and an
interface.  For ethernet, this is handled transparently; however, with
wanpipe (and, ostensibly, competing products) we need to handle this
ourselves.

So, I suggest adding these to /etc/init.d/network :

##############################################################################
# Start & stop WAN *ALL* devices
# Specifically designed for Sangoma wanpipe
# Probably applicable to others
# -- mds, 28Nov2001 --
##############################################################################
wan_start () {
        test -x /usr/sbin/wanconfig || return 1;
        /usr/sbin/wanconfig start
}

wan_stop () {
        test -x /usr/sbin/wanconfig || return 1;
        /usr/sbin/wanconfig stop
}


Then, we need to modify start () :

start () {
        echo -n "Starting Network: "
        wan_start
        start_auto_ipkrnlswch
...


As well as, modify stop () :

stop () {
        echo "Stopping Network: "
        iface_down all
        wan_stop
        if [ "$IPFWADM" ]; then
...


Now, for a couple changes to /etc/network.conf :

if_up () ...

# Set up each interface
case $1 in
chdlc*|fr*|wan*|wp*)
        ip addr add $IPADDR peer $PTPADDR dev $1
        for ADDR in $IP_EXTRA_ADDRS
        do
                ip addr add $ADDR dev $1
        done
        ip link set $1 up
        # Fair queuing - this can be selected for any interface
        ip_frQoS $1
        ;;
...

if_down () ...

case $1 in
chdlc*|fr*|wan*|wp*)
        qt ip link set dev $1 down
        qt ip addr flush dev $1
        ;;
...


Now, wan interfaces are handled properly, with the device coming up
first, then the interfaces can be handled as are any other interfaces.

Is this acceptable to everybody?

What do you think?

-- 

Best Regards,

mds
mds resource
888.250.3987

Dare to fix things before they break . . .

Our capacity for understanding is inversely proportional to how much we
think we know.  The more I know, the more I know I don't know . . .

_______________________________________________
Leaf-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/leaf-user

Reply via email to