Code Monkey home page Code Monkey logo

Comments (4)

rmiguelc avatar rmiguelc commented on August 27, 2024

For anyone else having the same problem.

So because the logs indicated lack of primitives that obviously do exist in simple_switch, I checked the target being used. I edited the following line in p4apprunner.py:

switch_args.append('--behavioral-exe "%s"' % 'simple_switch')

to

switch_args.append('--behavioral-exe "%s"' % '~/behavioral-model/targets/simple_switch/simple_switch')

Meaning, I made it point to my local copy of bmv2. The first line appears at several places and you'll have to change it everywhere if you plan to use all Mininet topologies. The same has to be done for the compiler, obviously. Line 118 becomes:

rv = run_command('~/p4c/build/p4c-bm2-ss %s' % ' '.join(compiler_args))

I had already updated the compiler directory, but I forgot about this (now fairly obvious) issue.

from tutorials.

jafingerhut avatar jafingerhut commented on August 27, 2024

from tutorials.

rmiguelc avatar rmiguelc commented on August 27, 2024

@jafingerhut I usually keep non-essential executables in my workspace and I was unaware I had placed a simple_switch binary elsewhere on my Ubuntu folders, hence the problem. Anyway, thanks for the tip! :)

from tutorials.

antoninbas avatar antoninbas commented on August 27, 2024

The VM image came with a pre-installed version of simple_switch, installed under /usr/local/bin. If you want to use the image with the latest version of bmv2, the correct solution is indeed to build it and re-install it, as @jafingerhut suggested. You can also install it to a local directory and update your PATH accordingly, but I don't think that's worth the trouble.

All the software that was shipped inside the VM image should be compatible. The only case where you would experience an issue IMO is if you try to update one component (e.g. p4c), without updating the rest (e.g. bmv2). That's probably what you did here.

from tutorials.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.