Re: [RFC][PATCH] iproute: Faster ip link add, set and delete
From: Eric Dumazet <hidden>
Date: 2013-03-26 15:31:10
From: Eric Dumazet <hidden>
Date: 2013-03-26 15:31:10
On Tue, 2013-03-26 at 11:51 +0000, Benoit Lourdelet wrote:
The script to delete: for d in /sys/class/net/veth*; do ip link del `basename $d` 2>/dev/null || true Done There is a very good improvement in deletion.
I can do better ;) If you are really doing this kind of things, you could use : rmmod veth Note that "ip" command supports a batch mode ip -batch filename In this case, the caching is done only once. Eric, Stephen, one possibility would be to use the cache only in batch mode. Anyway caching is wrong because several users can use ip command at the same time.