From: Josip Rodin Date: Mon, 2 Nov 2009 13:41:17 +0000 (+0100) Subject: konzistentno koristenje ip link set up (eliminirajuci i zadnje koristenje ifconfiga... X-Git-Url: https://git.entuzijast.net/?a=commitdiff_plain;h=6821967621859a41581a4bd04ea426b75fa172ac;p=imunes.git konzistentno koristenje ip link set up (eliminirajuci i zadnje koristenje ifconfiga u engineu) --- diff --git a/linux/exec.tcl b/linux/exec.tcl index 2a96108..be7f1d6 100755 --- a/linux/exec.tcl +++ b/linux/exec.tcl @@ -771,7 +771,7 @@ proc deployCfg {} { #dodaje interface nexec brctl addif $bridge $port_if #dize bridge, interesantno ne baca error ako je bridge vec dignut - nexec ifconfig $bridge up + nexec ip link set up dev $bridge puts " L2 device $bridge is up, added interface $port_if" @@ -788,7 +788,7 @@ proc deployCfg {} { lappend bridges $bridge nexec brctl addif $bridge $host_if_a nexec brctl addif $bridge $host_if_b - nexec ifconfig $bridge up + nexec ip link set up dev $bridge puts " Bridge $bridge is up, added interface $host_if_a and $host_if_b" } diff --git a/linux/host.tcl b/linux/host.tcl index c202e69..0026a05 100755 --- a/linux/host.tcl +++ b/linux/host.tcl @@ -92,10 +92,12 @@ proc $MODULE.cfggen { node } { if { $addr != "" } { lappend cfg "ip -6 addr add $addr dev $ifc" } + lappend cfg "ip link set up dev $ifc" } # sami napravimo localhost da ne moramo u VEu imati netbase+ifupdown lappend cfg "ip addr add 127.0.0.1/8 dev lo" + lappend cfg "ip link set up dev lo" foreach statrte [getStatIPv4routes $node] { lappend cfg "ip -4 route add [lindex $statrte 0] via [lindex $statrte 1]" diff --git a/linux/pc.tcl b/linux/pc.tcl index 89ad04c..e737b1a 100755 --- a/linux/pc.tcl +++ b/linux/pc.tcl @@ -89,10 +89,12 @@ proc $MODULE.cfggen { node } { if { $addr != "" } { lappend cfg "ip -6 addr add $addr dev $ifc" } + lappend cfg "ip link set up dev $ifc" } # sami napravimo localhost da ne moramo u VEu imati netbase+ifupdown lappend cfg "ip addr add 127.0.0.1/8 dev lo" + lappend cfg "ip link set up dev lo" foreach statrte [getStatIPv4routes $node] { lappend cfg "ip -4 route add [lindex $statrte 0] via [lindex $statrte 1]"