Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mininet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Olaf Bergmann
mininet
Commits
57fd19ef
Commit
57fd19ef
authored
14 years ago
by
Bob Lantz
Browse files
Options
Downloads
Patches
Plain Diff
Rename Controller.controller to .command
parent
e30f2c99
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
mininet/node.py
+7
-7
7 additions, 7 deletions
mininet/node.py
with
7 additions
and
7 deletions
mininet/node.py
+
7
−
7
View file @
57fd19ef
...
...
@@ -464,7 +464,7 @@ def __init__( self, name, **kwargs ):
"""
Init.
name: name for the switch
"""
Switch
.
__init__
(
self
,
name
,
**
kwargs
)
pathCheck
(
'
ofdatapath
'
,
'
ofprotocol
'
,
pathCheck
(
'
ofdatapath
'
,
'
ofprotocol
'
,
moduleName
=
'
the OpenFlow reference user switch (openflow.org)
'
)
@staticmethod
...
...
@@ -621,10 +621,10 @@ class Controller( Node ):
"""
A Controller is a Node that is running (or has execed?) an
OpenFlow controller.
"""
def
__init__
(
self
,
name
,
inNamespace
=
False
,
co
ntroller
=
'
controller
'
,
def
__init__
(
self
,
name
,
inNamespace
=
False
,
co
mmand
=
'
controller
'
,
cargs
=
'
-v ptcp:%d
'
,
cdir
=
None
,
defaultIP
=
"
127.0.0.1
"
,
port
=
6633
):
self
.
co
ntroller
=
controller
self
.
co
mmand
=
command
self
.
cargs
=
cargs
self
.
cdir
=
cdir
self
.
port
=
port
...
...
@@ -634,17 +634,17 @@ def __init__( self, name, inNamespace=False, controller='controller',
def
start
(
self
):
"""
Start <controller> <args> on controller.
Log to /tmp/cN.log
"""
pathCheck
(
self
.
co
ntroller
)
pathCheck
(
self
.
co
mmand
)
cout
=
'
/tmp/
'
+
self
.
name
+
'
.log
'
if
self
.
cdir
is
not
None
:
self
.
cmd
(
'
cd
'
+
self
.
cdir
)
self
.
cmd
(
self
.
co
ntroller
+
'
'
+
self
.
cargs
%
self
.
port
+
self
.
cmd
(
self
.
co
mmand
+
'
'
+
self
.
cargs
%
self
.
port
+
'
1>
'
+
cout
+
'
2>
'
+
cout
+
'
&
'
)
self
.
execed
=
False
def
stop
(
self
):
"
Stop controller.
"
self
.
cmd
(
'
kill %
'
+
self
.
co
ntroller
)
self
.
cmd
(
'
kill %
'
+
self
.
co
mmand
)
self
.
terminate
()
def
IP
(
self
,
intf
=
None
):
...
...
@@ -682,7 +682,7 @@ def __init__( self, name, noxArgs=None, **kwargs ):
noxCoreDir
=
os
.
environ
[
'
NOX_CORE_DIR
'
]
Controller
.
__init__
(
self
,
name
,
co
ntroller
=
noxCoreDir
+
'
/nox_core
'
,
co
mmand
=
noxCoreDir
+
'
/nox_core
'
,
cargs
=
'
--libdir=/usr/local/lib -v -i ptcp:%s
'
%
self
.
port
+
'
'
.
join
(
noxArgs
),
cdir
=
noxCoreDir
,
**
kwargs
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment