Commit 635f1a1a authored by David Johnson's avatar David Johnson
Browse files

Enable specification of lanlinks for inner plab nodes to be/contact

inner plc on.
parent 4e128cc8
......@@ -77,6 +77,7 @@ Node instproc init {s} {
$self set failureaction "fatal"
$self set inner_elab_role ""
$self set plab_role "none"
$self set plab_plcnet "none"
$self set fixed ""
$self set nseconfig ""
......@@ -145,6 +146,7 @@ Node instproc updatedb {DB} {
$self instvar failureaction
$self instvar inner_elab_role
$self instvar plab_role
$self instvar plab_plcnet
$self instvar routertype
$self instvar fixed
$self instvar agentlist
......@@ -279,6 +281,11 @@ Node instproc updatedb {DB} {
lappend values $plab_role
}
if { $plab_plcnet != "" } {
lappend fields "plab_plcnet"
lappend values $plab_plcnet
}
if { $numeric_id != {} } {
lappend fields "numeric_id"
lappend values $numeric_id
......
......@@ -84,6 +84,7 @@ proc tb-set-link-est-bandwidth {srclink args} {}
proc tb-set-lan-est-bandwidth {lan bw} {}
proc tb-set-node-lan-est-bandwidth {node lan bw} {}
proc tb-set-node-plab-role {node role} {}
proc tb-set-node-plab-plcnet {node lanlink} {}
proc tb-set-dpdb {onoff} {}
proc tb-set-security-level {level} {
......
......@@ -1611,6 +1611,29 @@ proc tb-set-node-plab-role {node role} {
$node set plab_role $role
}
#
# Set the default inner plab network. Can be a linklan, "CONTROL", or
# "EXPERIMENTAL". If user sets CONTROL
#
#
# Set the interface on which a node will be/access PLC.
# Both a plc and a normal planetlab node can call this.
#
proc tb-set-node-plab-plcnet {node lanlink} {
if {[$node info class] != "Node"} {
perror "\[tb-set-node-plab-plcnet] $node is not a node."
return
}
if {$lanlink != "control" && $lanlink != "exp" &&
([$lanlink info class] != "Link" && [$lanlink info class] != "Lan")} {
perror "\[tb-set-node-plab-plcnet] $lanlink must be a link, lan, \"control\", or \"exp\"."
return
}
# don't do checking here, wait til we have Total Information Awareness.
$node set plab_plcnet $lanlink
}
#
# Set security level.
#
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment