diff options
author | Olivier Blin <oblin@mandriva.org> | 2005-07-07 07:44:35 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.org> | 2005-07-07 07:44:35 +0000 |
commit | 0b73e58474d653def8257ab66faf8bfabc916a09 (patch) | |
tree | 11e700abc09b4e5e2cbfc275cac519ec358881dc /perl-install/network/tools.pm | |
parent | f0f54fec1e8a3c7b8e24be3de3dc12deac4998dc (diff) | |
download | drakx-backup-do-not-use-0b73e58474d653def8257ab66faf8bfabc916a09.tar drakx-backup-do-not-use-0b73e58474d653def8257ab66faf8bfabc916a09.tar.gz drakx-backup-do-not-use-0b73e58474d653def8257ab66faf8bfabc916a09.tar.bz2 drakx-backup-do-not-use-0b73e58474d653def8257ab66faf8bfabc916a09.tar.xz drakx-backup-do-not-use-0b73e58474d653def8257ab66faf8bfabc916a09.zip |
add start/stop_ifplugd
Diffstat (limited to 'perl-install/network/tools.pm')
-rw-r--r-- | perl-install/network/tools.pm | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/perl-install/network/tools.pm b/perl-install/network/tools.pm index 4be315700..9305fbd46 100644 --- a/perl-install/network/tools.pm +++ b/perl-install/network/tools.pm @@ -85,6 +85,17 @@ sub stop_net_interface { stop_interface($net->{net_interface}, $detach); } +sub start_ifplugd { + my ($interface) = @_; + run_program::run('/sbin/ifplugd', '-b', '-i', $interface); +} + +sub stop_ifplugd { + my ($interface) = @_; + my $ifplugd = chomp_(cat_("/var/run/ifplugd.$interface.pid")); + $ifplugd and kill(15, $ifplugd); +} + sub connected() { gethostbyname("mandrakesoft.com") ? 1 : 0 } # request a ref on a bg_connect and a ref on a scalar |