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@ -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@ -p 8101
Password authentication
Welcome to Open Network Operating System (ONOS)!
     ____  _  ______  ____     
    / __ \/ |/ / __ \/ __/   
   / /_/ /    / /_/ /\ \     
Mailing lists:     

Come help out! Find out how at: 

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 >  

  1. javad left a comment on March 30, 2020 at 7:50 pm

    i have to cluster three onos nodes for my paper . i create three onos nodes with docker but this nodes dont cluster togather … please help me

Leave a Comment

Your email address will not be published.