[Update 11/2020] Omada SDN Controller 4.2.4 for Devuan, Debian and other Linux systems

This thread has been locked for further replies. You can start a new thread to share your ideas or ask questions.
1234...

[Update 11/2020] Omada SDN Controller 4.2.4 for Devuan, Debian and other Linux systems

This thread has been locked for further replies. You can start a new thread to share your ideas or ask questions.
139 Reply
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 08:35:05

Hi guys

 

Sorry for the newbie questions, but I'm attempting to install this on my RPi3

I've checked the java version...which is:

 

openjdk version "1.8.0_212"

OpenJDK Runtime Environment (build 1.8.0_212-8u212-b01-1+rpi1-b01)

OpenJDK Client VM (build 25.212-b01, mixed mode)

 

I assume that's correct?

 

But running dpkg I get:

(Reading database ... 65474 files and directories currently installed.)

Preparing to unpack omada-sdn-controller_4.1.5-1_all.deb ...

[info] Omada SDN Controller is not running.

Unpacking omada-sdn-controller (4.1.5-1) over (4.1.5-1) ...

Setting up omada-sdn-controller (4.1.5-1) ...

[....] Starting Omada SDN Controller:Invalid JVM name specified server

. ok

Processing triggers for man-db (2.8.5-2) ...

 

What am I doing wrong?

Thanks!

  0  
  0  
#22
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 08:43:11

@MiloWiles Problem is jsvc doesn't like you openjdk runtime probably. Could also be you need to do a export JAVA_HOME first.

But unlike the requirements says I have it running in my docker container but not using jsvc tho.

 

So if you start it manually with:
export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-armhf/jre
/usr/lib/jvm/java-8-openjdk-armhf/jre/bin/java -server -Xms128m -Xmx512m -XX:MaxHeapFreeRatio=60 -XX:MinHeapFreeRatio=30 -XX:+HeapDumpOnOutOfMemoryError -XX:-UsePerfData -Deap.home=/opt/tplink/OmadaController -cp /opt/tplink/OmadaController/lib/*:  com.tplink.omada.start.OmadaLinuxMain

 

it probably will run. (you need the adjust the java home directory maybe)

 

  0  
  0  
#23
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 08:47:38

@MiloWiles 

One thing I also noticed. When you start it first time. The mongodb takes  some time to create the databases.  Too long for the Omada SDN controller.  

I fixed that by just let it run until you see in the mongodb.log is has finished creating the databases and journals. Then stop and start it again.

  0  
  0  
#24
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 08:57:43

@Milo just found /etc/default/omadad 

you might wanna check that file and correct it and try it again.

 

  0  
  0  
#25
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 10:20:58 - last edited 2020-07-19 10:30:06

 

Ronald1965 wrote

But unlike the requirements says I have it running in my docker container but not using jsvc tho.

 

Please note that running Omada Controller without Privilege Separation done by jsvc bears a high risk of root exploits due to possible bugs in the Java JRE.

 

Don't expose a controller running w/o Privilege Separation to the Internet, run it only in an isolated, fully trusted network!

 

As for jsvc issues: they are probably caused by dependencies with Oracle JRE8. When I have more spare time, I will take a look to other methods for Privilege Separation in order to get rid of jsvc and its dependencies. But if this would require modifications of TP-Link's Java classes, we're unfortunately out of luck.

 

Also note that /etc/default/omadad was used only by old controller versions, while in V3.2.10-2 and V4.1.5-1 this file has been merged with file CONFIG in Omada Controller's home directory /opt/tplink/OmadaController.

༺ 0100 1101 0010 10ཏ1 0010 0110 1010 1110 ༻
  1  
  1  
#26
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 10:48:45

@Ronald1965 Thanks for that.

 

It does indeed start...however, the mongoldb never seems to fully initialise.

I don't get a mongodb.log file generated either...so I suspect a problem with that.

 

2020-07-19 11:38:57 [log4j-thread] [INFO]-[SourceFile:29] - success to load configuration omada.properties
2020-07-19 11:38:58 [main] [INFO]-[SourceFile:75] - going to start local mongod.
2020-07-19 11:40:38 [main] [WARN]-[SourceFile:142] - Fail to start mongo DB server
2020-07-19 11:40:38 [main] [WARN]-[SourceFile:78] - com.tplink.omada.start.a.a: Fail to start mongo DB server
com.tplink.omada.start.a.a: Fail to start mongo DB server
    at com.tplink.omada.start.b.d.a(SourceFile:143) ~[omada-start.jar:?]
    at com.tplink.omada.start.b.b.e(SourceFile:75) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.d(SourceFile:209) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.q(SourceFile:273) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.a(SourceFile:86) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.e(SourceFile:231) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaLinuxMain.b(SourceFile:80) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaLinuxMain.main(SourceFile:25) [omada-start.jar:?]
2020-07-19 11:42:20 [main] [WARN]-[SourceFile:142] - Fail to start mongo DB server
2020-07-19 11:42:20 [main] [WARN]-[SourceFile:78] - com.tplink.omada.start.a.a: Fail to start mongo DB server
com.tplink.omada.start.a.a: Fail to start mongo DB server
    at com.tplink.omada.start.b.d.a(SourceFile:143) ~[omada-start.jar:?]
    at com.tplink.omada.start.b.b.e(SourceFile:75) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.d(SourceFile:209) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.n(SourceFile:202) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.q(SourceFile:276) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.a(SourceFile:86) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaBootstrap.e(SourceFile:231) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaLinuxMain.b(SourceFile:80) [omada-start.jar:?]
    at com.tplink.omada.start.OmadaLinuxMain.main(SourceFile:25) [omada-start.jar:?]
2020-07-19 11:42:22 [mongo-check-thread] [INFO]-[SourceFile:298] - mongod was shutdown, restarting it
2020-07-19 11:43:23 [main] [WARN]-[SourceFile:342] - Mongo Client connect error while init Jetty.com.mongodb.MongoTimeoutException: Timed out after 30000 ms while waiting to connect. Client view of cluster state is {type=UNKNOWN, servers=[{address=127.0.0.1:27217, type=UNKNOWN, state=CONNECTING, exception={com.mongodb.MongoSocketOpenException: Exception opening socket}, caused by {java.net.ConnectException: Connection refused (Connection refused)}}]
2020-07-19 11:43:23 [main] [ERROR]-[SourceFile:306] - warApps are not exist
2020-07-19 11:43:23 [main] [WARN]-[SourceFile:20] - WebApplicationContext has not been initialed, failed to get bean dataInitService
2020-07-19 11:43:23 [main] [ERROR]-[SourceFile:51] - Failed to get WebApplicationContext, MetaDataInitTask execute failed!
2020-07-19 11:43:23 [main] [ERROR]-[SourceFile:18] - Failed to start omada controller, going to exit
2020-07-19 11:43:24 [device-discovery-server] [INFO]-[SourceFile:54] - Start device discovery server
2020-07-19 11:43:24 [device-manage-server] [INFO]-[SourceFile:111] - Start device manage server
2020-07-19 11:43:24 [device-adopt-server] [INFO]-[SourceFile:82] - Start device adopt server
2020-07-19 11:43:27 [Thread-1] [INFO]-[SourceFile:166] - success to shutdown mongodb database
2020-07-19 11:43:27 [Thread-1] [INFO]-[SourceFile:171] - Omada Controller exited

 

Ronald1965 wrote

@MiloWiles Problem is jsvc doesn't like you openjdk runtime probably. Could also be you need to do a export JAVA_HOME first.

But unlike the requirements says I have it running in my docker container but not using jsvc tho.

 

So if you start it manually with:
export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-armhf/jre
/usr/lib/jvm/java-8-openjdk-armhf/jre/bin/java -server -Xms128m -Xmx512m -XX:MaxHeapFreeRatio=60 -XX:MinHeapFreeRatio=30 -XX:+HeapDumpOnOutOfMemoryError -XX:-UsePerfData -Deap.home=/opt/tplink/OmadaController -cp /opt/tplink/OmadaController/lib/*:  com.tplink.omada.start.OmadaLinuxMain

 

it probably will run. (you need the adjust the java home directory maybe)

 

 

I might just give up at this point and try and get the new build working on my QNAP NAS instead! :)

Over in the QNAP forums a user had the previous version built as a QPKG for it.

  0  
  0  
#27
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 10:54:45

@MiloWiles Did you check directory permissions? And if its running as omadad user or root.

In docker I use gosu omadad "java....."

  0  
  0  
#28
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 13:02:06 - last edited 2020-07-19 13:21:53

@Ronald1965 - thanks again.

I su'd to root to run it (after I found the permissions were set for "omadad" on the directories in /opt/tplink/OmadaController

 

 

EDIT: maybe I was too quick to assume errors earlier.

It's now starting the mongodb.

 

However, I suspect we're now in to the versioning issue of MongoDB as reported earlier in the thread.

The default for Buster is v2.4.14 and obviously not compatible.

 

I don't want to rebuild the Pi given that I'm using it for other stuff.

Back to the QNAP!

  0  
  0  
#29
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-19 13:31:08 - last edited 2020-07-19 13:32:01

 

MiloWiles wrote

The default for Buster is v2.4.14 and obviously not compatible.

 

Sure, as I wrote in post #1: SDN Controller needs at least V2.6 of mongodb, while Raspbian Jessie, Stretch and Buster stick with V2.4.
That's why Ronald did build a docker image for Raspbian which uses a modern
mongodb package.

༺ 0100 1101 0010 10ཏ1 0010 0110 1010 1110 ༻
  0  
  0  
#30
Options
Re:Omada SDN Controller 4.1.5 for Devuan, Debian and other Linux systems
2020-07-27 09:37:33
Yesterday I have updated Mongodb to 3.1.12 version on a RPi. I'm used this guide: http://koenaerts.ca/compile-and-install-mongodb-on-raspberry-pi/ The process need some hours but now I have Omada 4.1.5 on Raspbian Buster!! Roby
  1  
  1  
#31
Options