Project

General

Profile

« Previous | Next » 

Revision a892dca0

Added by Scott Ullrich almost 20 years ago

  • Launch DHCLIENT in foreground mode.
  • use mwexec_bg to launch item in the background

Confusing, eh?

View differences:

etc/inc/interfaces.inc
700 700
        mwexec("/sbin/ifconfig {$optif} up");
701 701

  
702 702
        /* fire up dhclient */
703
        mwexec("/sbin/dhclient -b -c {$g['varetc_path']}/dhclient_{$optif}.conf {$optif}");
703
        mwexec_bg("/sbin/dhclient -f -c {$g['varetc_path']}/dhclient_{$optif}.conf {$optif}");
704 704

  
705 705
	return 0;
706 706
}
......
746 746
        mwexec("/sbin/ifconfig {$optif} up");
747 747

  
748 748
        /* fire up dhclient */
749
        mwexec("/sbin/dhclient -b -c {$g['varetc_path']}/dhclient_{$optif}.conf {$optif} >/tmp/{$optif}_output >/tmp/{$optif}_error_output");
749
        mwexec_bg("/sbin/dhclient -f -c {$g['varetc_path']}/dhclient_{$optif}.conf {$optif} >/tmp/{$optif}_output >/tmp/{$optif}_error_output");
750 750

  
751 751
	$fout = fopen("/tmp/ifconfig_{$optif}","w");
752
	fwrite($fout, "/sbin/dhclient -b -c {$g['varetc_path']}/dhclient_{$optif}.conf {$optif}");
752
	fwrite($fout, "/sbin/dhclient -f -c {$g['varetc_path']}/dhclient_{$optif}.conf {$optif}");
753 753
	fclose($fout);
754 754

  
755 755
	return 0;
......
793 793
        mwexec("/sbin/ifconfig {$wanif} up");
794 794

  
795 795
        /* fire up dhclient */
796
        mwexec("/sbin/dhclient -b -c {$g['varetc_path']}/dhclient_wan.conf {$wanif} >/tmp/{$wanif}_output >/tmp/{$wanif}_error_output");
796
        mwexec_bg("/sbin/dhclient -f -c {$g['varetc_path']}/dhclient_wan.conf {$wanif} >/tmp/{$wanif}_output >/tmp/{$wanif}_error_output");
797 797

  
798 798
	$fout = fopen("/tmp/ifconfig_{$wanif}","w");
799
	fwrite($fout, "/sbin/dhclient -b -c {$g['varetc_path']}/dhclient_wan.conf {$wanif}");
799
	fwrite($fout, "/sbin/dhclient -f -c {$g['varetc_path']}/dhclient_wan.conf {$wanif}");
800 800
	fclose($fout);
801 801

  
802 802
	return 0;

Also available in: Unified diff