[libvirt] [tck PATCH 3/4] networks: remove stray use of brctl command

Laine Stump posted 4 patches 7 years ago
[libvirt] [tck PATCH 3/4] networks: remove stray use of brctl command
Posted by Laine Stump 7 years ago
brctl has been deprecated for a long time, and distros are starting to
remove it. "ip link blah type bridge" should be used instead.

Signed-off-by: Laine Stump <laine@laine.org>
---
 scripts/networks/340-guest-network-bridge.t | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/scripts/networks/340-guest-network-bridge.t b/scripts/networks/340-guest-network-bridge.t
index e5db0ff..498bcb6 100644
--- a/scripts/networks/340-guest-network-bridge.t
+++ b/scripts/networks/340-guest-network-bridge.t
@@ -36,9 +36,9 @@ my $conn = eval { $tck->setup(); };
 BAIL_OUT "failed to setup test harness: $@" if $@;
 END { $tck->cleanup if $tck; }
 
-((system "brctl addbr tck") == 0) or die "cannot create bridge 'tck'";
+((system "ip link add name tck type bridge") == 0) or die "cannot create bridge 'tck'";
 
-END { system "brctl delbr tck" }
+END { system "ip link del tck" }
 
 my $b = Sys::Virt::TCK::NetworkBuilder->new(name => "tck");
 $b->bridge("tck");
-- 
2.20.1

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [tck PATCH 3/4] networks: remove stray use of brctl command
Posted by Daniel P. Berrangé 6 years, 12 months ago
On Thu, Feb 07, 2019 at 10:08:30PM -0500, Laine Stump wrote:
> brctl has been deprecated for a long time, and distros are starting to
> remove it. "ip link blah type bridge" should be used instead.
> 
> Signed-off-by: Laine Stump <laine@laine.org>
> ---
>  scripts/networks/340-guest-network-bridge.t | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list