i386/64572: kernel panic when running ifconfig in perl to create vlans

Mike mikef at zerompg.com
Mon Mar 22 08:00:36 PST 2004


>Number:         64572
>Category:       i386
>Synopsis:       kernel panic when running ifconfig in perl to create vlans
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-i386
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Mar 22 08:00:35 PST 2004
>Closed-Date:
>Last-Modified:
>Originator:     Mike
>Release:        5.2.1
>Organization:
None
>Environment:
FreeBSD hostname.blah.com 5.2.1-RELEASE FreeBSD 5.2.1-RELEASE #0: Mon Feb 23 20:45:55 GMT 2004     root at wv1u.btc.adaptec.com:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
When creating vlans manually i get no kernel panic:
Works-> ifconfig vlan30 create vlan 30 vlandev fxp2 mtu 1500 up

But when i use a perl script to pull values from an array and run it I get a kernel panic.


>How-To-Repeat:
Use this Perl script:

#!/usr/bin/perl
@vlans=(
        "30,fxp2",
        "31,fxp2",
        "32,fxp2"
);

foreach (@vlans){
        ($vnum,$int)=(split "," ,$_)[0,1];
        print("Bringing up VLAN $vnum on $int\n");
        system("ifconfig vlan$vnum create vlan $vnum vlandev $int mtu 1500 up");
}

>Fix:
It looks like the problem is just bringing the interface up in perl
if I use: system("ifconfig vlan$vnum create vlan $vnum vlandev $int mtu 1500") it works but "ifconfig vlan$vnum up" is what causes the panic
>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-i386 mailing list