From e24523cda77d3277844bfe638c086bcf85348f7d Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Tue, 15 Jun 2010 10:08:16 -0700 Subject: Remove sudo from ip command No longer need sudo on ip because of cap_net_admin --- scripts/vyatta-interfaces.pl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'scripts/vyatta-interfaces.pl') diff --git a/scripts/vyatta-interfaces.pl b/scripts/vyatta-interfaces.pl index d5abaa36..a303c82c 100755 --- a/scripts/vyatta-interfaces.pl +++ b/scripts/vyatta-interfaces.pl @@ -314,14 +314,14 @@ sub update_mac { if (POSIX::strtoul($flags) & 1) { # NB: Perl 5 system return value is bass-ackwards - system "sudo ip link set $intf down" + system "ip link set $intf down" and die "Could not set $intf down ($!)\n"; - system "sudo ip link set $intf address $mac" + system "ip link set $intf address $mac" and die "Could not set $intf address ($!)\n"; - system "sudo ip link set $intf up" + system "ip link set $intf up" and die "Could not set $intf up ($!)\n"; } else { - system "sudo ip link set $intf address $mac" + system "ip link set $intf address $mac" and die "Could not set $intf address ($!)\n"; } exit 0; -- cgit v1.2.3