Hi,
I am trying to find Stratum pre-built docker image for Linux 4.4.0-173-generic x86_64 , however couldn't find it. Can you please tell me whether Stratum is not supported on Generic and only runs on ONL version?
I tried stratumproject/stratum-bf:8.9.1-4.14.49-OpenNetworkLinux , but it failed with error:
cat: /etc/onl/platform: No such file or directory
Use default flag file
Cannot find /usr/local/share/stratum/.json
Maybe because the Linux doesn't support ONL? What may be the solution? Please let me know.
Thanks,
Deval
--
You received this message because you are subscribed to the Google Groups "P4 brigade" group.
To unsubscribe from this group and stop receiving emails from it, send an email to brigade-p4+...@onosproject.org.
To view this discussion on the web visit https://groups.google.com/a/onosproject.org/d/msgid/brigade-p4/3219e60081e54a23950b45fb513ca36e%40kau.se.
Thanks Carmelo.
Regards,
Deval.
Sub: ONOS Pipeconf App
Dear Carmelo,
Sending a gentle reminder for this issue.
I have been able to made a little progress. Now I have related txt, bin and json files under the folder resources. When I try to compile my modified pipeconf code, it given error:
package org.onosproject.p4runtime.api does not exist
Thank you for your help.
Deval.
Hello Davide,
So what I ma trying is to modify pipeconf code for my specific P4 app. I have been referring to the tutorial here:
https://github.com/opencord/fabric-tofino
I have the modified pipeconf code as well as the needed files such as tofino.bin, context.json, and p4info.txt in place under the folder /onos/apps/p4-tutorial/pipeconf/src/main/resources (it means I don\t have to perform the P4 compilation step like in the tutorial)
Now I am trying to create OAR file for my modified code using MVN with command mvn clean install. My modified code includes
import org.onosproject.p4runtime.api.P4RuntimeClient;
import org.onosproject.p4runtime.api.P4RuntimeController;
However while installing with mvn it gives me error
package org.onosproject.p4runtime.api does not exist
package org.onosproject.driver.pipeline
...
I have also complied the onos code with bazel before this step.
Thanks,
Deval.
Hello Davide,
SO just for a quick results, I adapted the Dirty (first) approach and created an myapp folder in onos/apps. I created all the required files there. I did bazel build onos from Onos_root directory.
Bazel executed fine, with build successful, but strangely there is no OAR file created for my app.
Il giorno 28 feb 2020, alle ore 16:44, Davide Scano <0ice...@gmail.com> ha scritto:
Hi Deval,
You can work in two way:
1) the dirty one, i.e modifing directly the onos apps. This means that you have to rebuild onos every times etc2) the clean one, creating an external application (https://wiki.onosproject.org/display/ONOS/Template+Application+Tutorial), that you can install and activate into onos. In other word you can start onos and than thanks to the command onos-app install you can install your application.
BestDs
Il giorno 28 feb 2020, alle ore 16:33, Deval Bhamare <Deval....@kau.se> ha scritto:
Okay, thanks. Never used bazel before.
Also it creates OAR file in target which can be pushed to ONOS then, right?
~DB
From: Davide Scano <0ice...@gmail.com>
Sent: Friday, February 28, 2020 5:27:40 PM
To: Deval Bhamare
Subject: Re: [brigade-p4] ONOS Pipeconf AppHi,
Yes, because you have to rebuild the code. Basically is the same concept of maven.
DsIl giorno 28 feb 2020, alle ore 16:22, Deval Bhamare <Deval....@kau.se> ha scritto:
OKay, so just bazel build onos will build all of my apps as well?
Thanks,
Deval.
From: Davide Scano <0ice...@gmail.com>
Sent: Friday, February 28, 2020 5:04:28 PM
To: Deval Bhamare
Subject: Re: [brigade-p4] ONOS Pipeconf AppHi,
1) If you use Intellij with the Bazel plugin ( see the attachment)2) otherwise I thin that you can use bazel build onos
ThanksDs
<Schermata 2020-02-28 alle 16.03.21.png>
Il giorno 28 feb 2020, alle ore 15:50, Deval Bhamare <Deval....@kau.se> ha scritto:
Hi again,
So I can see some BUILD files in each apps folder, for example in :
/onos/apps/p4-tutorial/mytunnel
SO can you please tell me how can I build the app with Bazel and this BUILD file?
ThanksDB
From: Davide Scano <0ice...@gmail.com>
Sent: Friday, February 28, 2020 4:01:28 PM
To: Deval Bhamare
Subject: Re: [brigade-p4] ONOS Pipeconf AppHi Deval,
1) Have you tried to comment/remove package org.onosproject.p4runtime.api? Because seems that you using a package that isn’t defined in the folder where you have defined your java files/classes.2) If you haven’t create a new onos application you have to check the dependencies in the .BUILD file utilized by BazelIf you have create a new onos application you have inserted this dependencies?
<dependency> <groupId>org.onosproject</groupId> <artifactId>onos-protocols-p4runtime-model</artifactId> <version>${onos.version}</version> </dependency> <dependency> <groupId>org.onosproject</groupId> <artifactId>onos-protocols-p4runtime-api</artifactId> <version>${onos.version}</version> </dependency>
Sorry if I bother you with all these emails/questions
Best,Ds
Il giorno 28 feb 2020, alle ore 14:53, Deval Bhamare <Deval....@kau.se> ha scritto:
Hi,
as far as P4 code is considered, we have written completely new P4 code. We have been able to build it and produce txt, json files to be included in the OAR package, as it is done in the current tutorial at https://github.com/opencord/fabric-tofino
Now we want to control that P4 code through ONOS (such as populating the tables etc.). For that the only way is writing customized pipeconf java app.
For this, I am trying to modify existing pipconf code in onos/apps/p4-tutorial/pipeconf
After modifying it, I have created a pom file for it and trying to compile it with MVN to create OAR file. It gives me the mentioned errors.
From: Davide Scano <0ice...@gmail.com>
Sent: Friday, February 28, 2020 3:41:00 PM
To: Deval Bhamare
Subject: Re: [brigade-p4] ONOS Pipeconf AppHi Deval.
I have a question, you have created a new Onos application or you have modified the onos applications p4-tutorial?
ThanksDs
--
You received this message because you are subscribed to the Google Groups "P4 brigade" group.
To unsubscribe from this group and stop receiving emails from it, send an email to brigade-p4+...@onosproject.org.
To view this discussion on the web visit https://groups.google.com/a/onosproject.org/d/msgid/brigade-p4/063cd565ea0248e48f2b83ae49d6207d%40kau.se.
Thanks.
The solution is you need to update modules.bzl to add your app in it so that Bazel knows.
Now I am stuck I next one, which is a known issue in JAVA 11. Error is:
error: package javax.xml.bind
does not exist
As suggested on forums I degraded to JAVA 8, but it is still there. Some forums suggest to update dependencies with Maven in Pom. That is to add below:
<dependency>
<groupId>javax.xml.bind</groupId>
<artifactId>jaxb-api</artifactId>
<version>2.3.0</version>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-core</artifactId>
<version>2.3.0</version>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-impl</artifactId>
<version>2.3.0</version>
</dependency>
What is the equivalent of the same for Bazel? How do I modify the Build file exactly?
Thanks,
Deval.
On 28 Feb 2020, at 5:17 PM, Deval Bhamare <Deval....@kau.se> wrote: