...
Code Block |
---|
language | bash |
---|
title | Add a user sdn |
---|
|
sudo adduser sdn --system --group |
Software packages
...
Java Versions
ONOS is a Java based platform. It’s strongly suggested to use Oracle Java 1.8 for it. The following snippet will allow you to install Java 1.8 in one step on an Ubuntu machine.
Java8 (Ubuntu 16 and Older)
Since Oracle had an license update on April 16 2019, anyone who want to download java8 has to register account, the apt methods of installing will not work.
...
Code Block |
---|
language | bash |
---|
title | Install Oracle Java 8 |
---|
|
for JavaCommand in java jar java2groovy javac javadoc javafxpackager javah javap javapackager javaws
do
sudo update-alternatives --install /usr/bin/$JavaCommand $JavaCommand /your_path_extracted_jdk/bin/$JavaCommand 1
done |
Java11 (Ubuntu 18 and Newer)
For newer versions of Ubuntu and ONOS is recommended to use Java 11 and set
Code Block |
---|
language | bash |
---|
title | Install Oracle Java 11 |
---|
|
sudo apt install openjdk-11-jdk |
Optional: you can also set java home for a better performance. For this example you will need to have super user powers, other ways to set java home are available online
Code Block |
---|
language | bash |
---|
title | Set java home |
---|
|
sudo su
cat >> /etc/environment <<EOL
JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
JRE_HOME=/usr/lib/jvm/java-11-openjdk-amd64/jre
EOL |
Curl
Code Block |
---|
language | bash |
---|
title | Install curl |
---|
|
sudo apt-get install curl |