summaryrefslogtreecommitdiffstats
path: root/dhcp_wizard
diff options
context:
space:
mode:
authorAntoine Ginies <aginies@mandriva.com>2004-02-06 12:12:00 +0000
committerAntoine Ginies <aginies@mandriva.com>2004-02-06 12:12:00 +0000
commit2b8d4b9ebf8449d474ffde8ae3d88fa1e6e9008a (patch)
tree2cfcdcc0b2a6d18a3447edcc399ec2e96d83eb72 /dhcp_wizard
parentef5bca3fd5db1c42ad91b3eb36e7ff91d0a8571b (diff)
downloaddrakwizard-2b8d4b9ebf8449d474ffde8ae3d88fa1e6e9008a.tar
drakwizard-2b8d4b9ebf8449d474ffde8ae3d88fa1e6e9008a.tar.gz
drakwizard-2b8d4b9ebf8449d474ffde8ae3d88fa1e6e9008a.tar.bz2
drakwizard-2b8d4b9ebf8449d474ffde8ae3d88fa1e6e9008a.tar.xz
drakwizard-2b8d4b9ebf8449d474ffde8ae3d88fa1e6e9008a.zip
now use check_started
Diffstat (limited to 'dhcp_wizard')
-rwxr-xr-xdhcp_wizard/Dhcp.pm25
1 files changed, 17 insertions, 8 deletions
diff --git a/dhcp_wizard/Dhcp.pm b/dhcp_wizard/Dhcp.pm
index d3dbccae..441ba0fa 100755
--- a/dhcp_wizard/Dhcp.pm
+++ b/dhcp_wizard/Dhcp.pm
@@ -25,11 +25,12 @@ package MDK::Wizard::Dhcp;
use strict;
use common;
+use services;
use MDK::Wizard::Varspaceval;
use MDK::Wizard::Wizcommon;
my $wiz = new MDK::Wizard::Wizcommon;
-my $interface = 'eth1';
+my $interface = 'eth0';
my $wiz_ip_server = $wiz->{net}->itf_get("IPADDR");
if (!$wiz_ip_server) {
($wiz_ip_server) = `/sbin/ip addr show dev $interface` =~ /^\s*inet\s+(\d+\.\d+\.\d+\.\d+)/m;
@@ -113,18 +114,25 @@ $o->{pages} = {
{ label => N("Lowest IP Address:"), fixed_val => \$o->{var}{ip1} },
{ label => N("Highest IP Address:"), fixed_val => \$o->{var}{ip2} },
{ label => N("Gateway IP Address:"), fixed_val => \$o->{var}{gateway} },
- { label => N("Interface:"), fixed_val => \$o->{var}{interface} },
+ { label => N("Interface:"), fixed_val => \$o->{var}{einterface} },
{ label => N("Enable PXE:"), fixed_val => \$o->{var}{pxeornot} },
],
post => \&do_it,
next => 'end'
},
- end => {
- name => N("Congratulations") . "\n\n" . N("The wizard successfully configured the DHCP services of your server."),
- end => 1,
- next => 0
- },
-};
+ end => {
+ name => N("Congratulations") . "\n\n" . N("The wizard successfully configured the DHCP services of your server."),
+ end => 1,
+ next => 0
+ },
+ error_end => {
+ name => N("Failed"),
+ data => [ { label => N("Relaunch drakwizard, and try to change some parameters.") } ],
+ no_back => 1,
+ end => 1,
+ next => 0,
+ },
+ };
sub compute_range {
my $n;
@@ -251,6 +259,7 @@ mask = $wiz_ip_netmask, rng1 = $wiz_ip_range1, rng2 = $wiz_ip_range2, dname = $w
services::start('dhcpd')
}
10;
+ check_started('dhcpd');
}
sub new {