Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Mar 2004 07:53:28 -0800 (PST)
From:      Mike <mikef@zerompg.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   i386/64572: kernel panic when running ifconfig in perl to create vlans
Message-ID:  <200403221553.i2MFrSgG071347@www.freebsd.org>
Resent-Message-ID: <200403221600.i2MG0ZRZ039837@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>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@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:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200403221553.i2MFrSgG071347>