alshabib

office cell and associated fixes (role, idle timeout)

Change-Id: Icc1fbed46c59f9be1d124569779250c0796150ce
...@@ -243,6 +243,8 @@ public abstract class AbstractOpenFlowSwitch implements OpenFlowSwitchDriver { ...@@ -243,6 +243,8 @@ public abstract class AbstractOpenFlowSwitch implements OpenFlowSwitchDriver {
243 if (role == RoleState.SLAVE || role == RoleState.EQUAL) { 243 if (role == RoleState.SLAVE || role == RoleState.EQUAL) {
244 this.role = role; 244 this.role = role;
245 } 245 }
246 + } else {
247 + this.role = role;
246 } 248 }
247 } catch (IOException e) { 249 } catch (IOException e) {
248 log.error("Unable to write to switch {}.", this.dpid); 250 log.error("Unable to write to switch {}.", this.dpid);
......
...@@ -651,7 +651,7 @@ class OFChannelHandler extends IdleStateAwareChannelHandler { ...@@ -651,7 +651,7 @@ class OFChannelHandler extends IdleStateAwareChannelHandler {
651 * @param error The error message 651 * @param error The error message
652 */ 652 */
653 protected void logError(OFChannelHandler h, OFErrorMsg error) { 653 protected void logError(OFChannelHandler h, OFErrorMsg error) {
654 - log.error("{} from switch {} in state {}", 654 + log.debug("{} from switch {} in state {}",
655 new Object[] { 655 new Object[] {
656 error, 656 error,
657 h.getSwitchInfoString(), 657 h.getSwitchInfoString(),
......
...@@ -77,6 +77,7 @@ public class FlowModBuilder { ...@@ -77,6 +77,7 @@ public class FlowModBuilder {
77 .setCookie(U64.of(cookie.value())) 77 .setCookie(U64.of(cookie.value()))
78 .setBufferId(OFBufferId.NO_BUFFER) 78 .setBufferId(OFBufferId.NO_BUFFER)
79 .setActions(actions) 79 .setActions(actions)
80 + .setIdleTimeout(10)
80 .setMatch(match) 81 .setMatch(match)
81 .setFlags(Collections.singleton(OFFlowModFlags.SEND_FLOW_REM)) 82 .setFlags(Collections.singleton(OFFlowModFlags.SEND_FLOW_REM))
82 .setPriority(priority) 83 .setPriority(priority)
...@@ -93,7 +94,7 @@ public class FlowModBuilder { ...@@ -93,7 +94,7 @@ public class FlowModBuilder {
93 OFFlowMod fm = factory.buildFlowDelete() 94 OFFlowMod fm = factory.buildFlowDelete()
94 .setCookie(U64.of(cookie.value())) 95 .setCookie(U64.of(cookie.value()))
95 .setBufferId(OFBufferId.NO_BUFFER) 96 .setBufferId(OFBufferId.NO_BUFFER)
96 - //.setActions(actions) 97 + .setActions(actions)
97 .setMatch(match) 98 .setMatch(match)
98 .setFlags(Collections.singleton(OFFlowModFlags.SEND_FLOW_REM)) 99 .setFlags(Collections.singleton(OFFlowModFlags.SEND_FLOW_REM))
99 .setPriority(priority) 100 .setPriority(priority)
......
1 +# ProxMox-based cell of ONOS instances 1,2 & ONOS mininet box
2 +. $ONOS_ROOT/tools/test/cells/.reset
3 +
4 +export ONOS_NIC="10.128.4.*"
5 +
6 +export OC1="10.128.4.60"
7 +#export OC2="192.168.97.131"
8 +
9 +#export OCN="192.168.97.130"
10 +