Ask Your Question
0

Problem starting the odl controller

asked 2014-08-22 06:44:46 -0700

skywalker gravatar image

updated 2014-08-23 10:56:55 -0700

I am following the Brent's guide from http://networkstatic.net/importing-opendaylight-into-eclipse/

My OS is OS X 10.9.4.

git clone http://git.opendaylight.org/gerrit/p/controller.git
cd controller/opendaylight/distribution/opendaylight/
mvn clean install

but I get a lot of warnings like

[WARNING] Failed to write tracking file /Users/daniel/.m2/repository/org/codehaus/plexus/plexus-interpolation/1.1/_remote.repositories
java.io.FileNotFoundException: /Users/daniel/.m2/repository/org/codehaus/plexus/plexus-interpolation/1.1/_remote.repositories (Permission denied)

so I run:

 sudo mvn clean install
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building distribution.opendaylight 0.1.2-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ distribution.opendaylight ---
[INFO] Deleting /Users/daniel/controller/opendaylight/distribution/opendaylight/target
[INFO] 
[INFO] --- maven-enforcer-plugin:1.3.1:enforce (enforce-java) @ distribution.opendaylight ---
[INFO] 
[INFO] --- buildnumber-maven-plugin:1.2:create (default) @ distribution.opendaylight ---
[INFO] Checking for local modifications: skipped.
[INFO] Updating project files from SCM: skipped.
[INFO] Executing: /bin/sh -c cd /Users/daniel/controller/opendaylight/distribution/opendaylight && git rev-parse --verify HEAD
[INFO] Working directory: /Users/daniel/controller/opendaylight/distribution/opendaylight
[INFO] Storing buildNumber: a3ebcb3c36804de1e4c0177f3462e33958b0c216 at timestamp: 1408708531966
[INFO] Executing: /bin/sh -c cd /Users/daniel/controller/opendaylight/distribution/opendaylight && git rev-parse --verify HEAD
[INFO] Working directory: /Users/daniel/controller/opendaylight/distribution/opendaylight
[INFO] Storing buildScmBranch: UNKNOWN
[INFO] 
[INFO] --- build-helper-maven-plugin:1.8:add-source (add-source) @ distribution.opendaylight ---
[INFO] Source directory: /Users/daniel/controller/opendaylight/distribution/opendaylight/src/main/yang added.
[INFO] Source directory: /Users/daniel/controller/opendaylight/distribution/opendaylight/src/main/yang-gen-config added.
[INFO] Source directory: /Users/daniel/controller/opendaylight/distribution/opendaylight/src/main/yang-gen-sal added.
[INFO] Source directory: /Users/daniel/controller/opendaylight/distribution/opendaylight/src/main/xtend-gen added.
[INFO] 
[INFO] --- maven-checkstyle-plugin:2.12:check (default) @ distribution.opendaylight ---
[INFO] Starting audit...
Audit done.

[INFO] 
[INFO] --- maven-dependency-plugin:2.8:unpack-dependencies (unpack-provided-configs) @ distribution.opendaylight ---
[INFO] Unpacking /var/root/.m2/repository/org/opendaylight/controller/netconf-config/0.2.5-SNAPSHOT/netconf-config-0.2.5-SNAPSHOT.jar to /Users/daniel/controller/opendaylight/distribution/opendaylight/target/configuration with includes "**\/*.xml,**/*.conf" and excludes ""
[INFO] Unpacking /var/root/.m2/repository/org/opendaylight/controller/sal-rest-connector-config/1.1-SNAPSHOT/sal-rest-connector-config-1.1-SNAPSHOT.jar to /Users/daniel/controller/opendaylight/distribution/opendaylight/target/configuration with includes "**\/*.xml,**/*.conf" and excludes ""
[INFO] Unpacking /var/root/.m2/repository/org/opendaylight/controller/config-netty-config/0.2.5-SNAPSHOT/config-netty-config-0.2.5-SNAPSHOT.jar to /Users/daniel/controller/opendaylight/distribution/opendaylight/target/configuration with includes "**\/*.xml,**/*.conf" and excludes ""
[INFO] Unpacking /var/root/.m2/repository/org/opendaylight/controller/md-sal-config/1.1-SNAPSHOT/md-sal-config-1.1-SNAPSHOT.jar to /Users/daniel/controller/opendaylight/distribution/opendaylight/target/configuration with includes "**\/*.xml,**/*.conf" and excludes ""
[INFO] Unpacking /var/root/.m2/repository/org/opendaylight/controller/samples/toaster-config/1.1-SNAPSHOT/toaster-config-1.1-SNAPSHOT.jar to /Users/daniel/controller/opendaylight/distribution/opendaylight/target/configuration with includes "**\/*.xml,**/*.conf" and excludes ""
[INFO] Unpacking /var/root/.m2/repository/org/opendaylight/controller/sal-clustering-config/1.1-SNAPSHOT/sal-clustering-config-1.1-SNAPSHOT.jar to /Users/daniel/controller/opendaylight/distribution/opendaylight/target/configuration with includes "**\/*.xml,**/*.conf" and excludes ""
[INFO] Unpacking /var/root/.m2/repository/org/opendaylight/controller/netconf-connector-config/0.2.5-SNAPSHOT/netconf-connector-config-0.2.5-SNAPSHOT.jar to ...
(more)
edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2014-08-23 22:05:00 -0700

Madhu gravatar image

All the steps are correct and you should expect the controller to work on ./run.sh. But since during the build step you had to execute with sudo privilege, i expect the same or even worse requirements to run the controller with sudo privileges. That is because, the controller writes to a few files, opens TCP ports, and perform few other operations that may be privileged in your system depending on the security features enabled on your development/deployment machine.

Can you please try running it also with sudo and lets see if that helps.

edit flag offensive delete publish link more

Comments

Thank you, Madhu. It works. I am a bit concerned about security. Could you tell me what is the best way to run the controller on the host OS? I've decided this due to both memory and easier development/testing.

skywalker ( 2014-08-24 01:21:21 -0700 )edit

I suspect the Firewall settings in your Host OS. Please take a look at this :https://wiki.opendaylight.org/view/Release/Hydrogen/Virtualization/Installation_Guide#Ports and selectively open up these ports so that the controller is able to perform its basic operations. This guide may need improvement to address a few more development work that is going on. But worth the try.

Madhu ( 2014-08-24 05:10:59 -0700 )edit

I am trying to run the controller on my os x host. In this stage I do not use any virtual machine. The controller starts with no problem when I run it with sudo. You are right there is a firewall but it does not influence the start phase. It seems all ok. If I disable it I still have to use sudo.

skywalker ( 2014-08-24 05:38:43 -0700 )edit

Thank you. The ports will be handy for the use with OpenStack.

skywalker ( 2014-08-24 05:41:08 -0700 )edit

I do have an explanation on why the run.sh is stuck when not using sudo even when you turn off firewall. Since you are executing the "sudo mvn clean install", all the files that are created under the target/ directory are with root privilege. But when executing the ./run.sh, it is not. That is causing some access issues. Can you disable firewall and run "mvn clean install" (without sudo) and then execute ODL without sudo ?

Madhu ( 2014-08-24 06:09:00 -0700 )edit
Login/Signup to Answer

Stats

Asked: 2014-08-22 06:44:46 -0700

Seen: 737 times

Last updated: Aug 23 '14