Install ONOS in Docker

If you find it to difficult to install ONOS as a Service, Installing ONOS in the docker environment is the right way.

Image result for onos docker

With Docker, you don’t mess around with the Java version related to ONOS version, etc. You just basically use docker tags as ONOS version, for example I want to install ONOS 2.2.0:

docker run -p 6653:6653 -p 6640:6640 -p 8181:8181 -p 8101:8101 -p 9876:9876 -d --name onos onosproject/onos:2.2.0

Why we have so much port? you can read the Dockerfile in here

  • 6653 – OpenFlow
  • 6640 – OVSDB
  • 8181 – GUI
  • 8101 – ONOS CLI
  • 9876 – ONOS intra-cluster communication

How to access the cluster? using ssh & port! (default user onos password rocks)

ssh onos@127.0.0.1 -p 8101

how to access the container

docker exec -it onos

How to change the default user & password?

docker exec -it onos /bin/bash
root@83db766dec99:~/onos# bin/onos-user-password onos --remove
root@83db766dec99:~/onos# bin/onos-user-password zufar zufarpass

Testing SSH again

root@zu-sona-onos:~# ssh zufar@127.0.0.1 -p 8101
Password authentication
Password: 
Welcome to Open Network Operating System (ONOS)!
     ____  _  ______  ____     
    / __ \/ |/ / __ \/ __/   
   / /_/ /    / /_/ /\ \     
   \____/_/|_/\____/___/     
                               
Documentation: wiki.onosproject.org      
Tutorials:     tutorials.onosproject.org 
Mailing lists: lists.onosproject.org     

Come help out! Find out how at: contribute.onosproject.org 

Hit '<tab>' for a list of available commands
and '[cmd] --help' for help on a specific command.
Hit '<ctrl-d>' or type 'logout' to exit ONOS session.

zufar@root >  



Leave a Comment

Your email address will not be published.