kern/78227: [netinet] [patch] Destroying a network interface
leaks kernel memory
Bruce M Simpson
bms at incunabulum.net
Wed Sep 27 07:50:20 PDT 2006
The following reply was made to PR kern/78227; it has been noted by GNATS.
From: Bruce M Simpson <bms at incunabulum.net>
To: freebsd-gnats-submit at FreeBSD.org
Cc:
Subject: Re: kern/78227: [netinet] [patch] Destroying a network interface
leaks kernel memory
Date: Wed, 27 Sep 2006 15:40:41 +0100
To reproduce this bug on 7-CURRENT:
0. Note memory usage before beginning:
sandbox# vmstat -m | grep in_multi
Type InUse MemUse HighUse Requests Size(s)
in_multi 4 1K - 4 32
1. Create a clonable interface e.g. a vlan.
sandbox# ifconfig vlan0 create
sandbox# ifconfig vlan0 vlan 1 vlandev ed0
2. Bind it to netinet by configuring an IPv4 address.
sandbox# ifconfig vlan0 10.0.0.1/24
3. Note membership of 224.0.0.1:
sandbox# netstat -g | grep vlan0
224.0.0.1 01:00:5e:00:00:01 vlan0
4. Note memory usage:
sandbox# vmstat -m | grep in_multi
in_multi 5 1K - 5 32
5. Unbind from netinet by deleting the address:
sandbox# ifconfig vlan0 delete
6. Note memory usage:
sandbox# vmstat -m | grep in_multi
in_multi 5 1K - 5 32
7. Note membership of 224.0.0.1:
sandbox# netstat -g | grep vlan0
224.0.0.1 01:00:5e:00:00:01 vlan0
8. Destroy the interface instance:
sandbox# ifconfig vlan0 destroy
9. Note memory usage:
sandbox# vmstat -m | grep in_multi
Type InUse MemUse HighUse Requests Size(s)
in_multi 5 1K - 5 32
10. Try creating another vlan interface; note than InUse does not go down.
More information about the freebsd-bugs
mailing list