Changeset 2942 in /cluster/svnroot


Ignore:
Timestamp:
Jan 23, 2011 7:38:26 PM (10 years ago)
Author:
skylar
Message:

networking init script returns 9 for non-fatal errors (#584)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • bccd-ng/branches/skylar-devel/trees/bin/bccd-nat

    r2933 r2942  
    2929my $Bccd = new Bccd();
    3030my($rc,$out);
     31$Bccd->set_debug('DEBUG');
    3132
    3233$rc = $Bccd->config_nat();
    3334if(defined($rc)) {
    34         ($rc,$out) = $Bccd->exec_system("invoke-rc.d networking restart");
    35         if($rc == 0) {
    36                 $Bccd->log_and_cont("INFO",$0,"$out");
     35        ($rc,$out) = $Bccd->exec_system("/usr/sbin/invoke-rc.d networking restart");
     36        if($rc) {
     37                $Bccd->log_and_die("ERROR",$0,"$out, RC $rc\n");
    3738        }
    3839        else {
    39                 $Bccd->log_and_die("ERROR",$0,"$out");
     40                $Bccd->log_and_cont("INFO",$0,"$out, RC $rc\n");
    4041        }
    4142}
     43else {
     44        exit 2;
     45}
     46
    4247
    4348exit 0;
Note: See TracChangeset for help on using the changeset viewer.