Git Product home page Git Product logo

python-vnfm-sdk's Introduction

Copyright © 2015-2016 Open Baton. Licensed under Apache v2 License.

Python version of the vnfm-sdk

This project contains a vnfm sdk for python projects.

Technical Requirements

This section covers the requirements that must be met by the python-vnfm-sdk in order to satisfy the demands for such a component:

  • python 2.7 or 3.5
  • pika

How to install python-vfnm-sdk

The safer way to start is to use a virtal environment. Once activated, just run

pip install python-vnfm-sdk

How to configure your vnfm

The sdk runs a certain number of instances of the vnfm by invoking the method:

def start_vnfm_instances(vnfm_klass, config_file_path, instances=1, **kwargs):
    # ....
    pass

where the parameters are the Vnfm class that implements AbstractVnfm, the config file path for the vnfm, the number of instances and the instantiation arguments for the vnfm class.

The ini config file looks like

[vnfm]

endpoint_type=RABBIT
type=python
endpoint=python-endpoint
log_path=/var/log/openbaton/
broker_ip=127.0.0.1
autodelete=true
heartbeat=60
exchange=openbaton-exchange

where:

name description
type The type of the vnfm
endpoint_type must be RABBIT
broker_ip Ip of the rabbitmq broker used by the nfvo
username username for the rabbitmq broker used to connect to the manager queue of the nfvo
password password for the rabbitmq broker used to connect to the manager queue of the nfvo
exchange exchange name used in the rabbitmq broker by the nfvo
autodelete true or false in case you want the endpoint queue to have the autodelete property (usually true)
heartbeat heartbeat for the rabbitmq connection
log_path path where the logfile will be written

see the python dummy vnfm as example

Issue tracker

Issues and bug reports should be posted to the GitHub Issue Tracker of this project

What is Open Baton?

OpenBaton is an open source project providing a comprehensive implementation of the ETSI Management and Orchestration (MANO) specification.

Open Baton is a ETSI NFV MANO compliant framework. Open Baton was part of the OpenSDNCore (www.opensdncore.org) project started almost three years ago by Fraunhofer FOKUS with the objective of providing a compliant implementation of the ETSI NFV specification.

Open Baton is easily extensible. It integrates with OpenStack, and provides a plugin mechanism for supporting additional VIM types. It supports Network Service management either using a generic VNFM or interoperating with VNF-specific VNFM. It uses different mechanisms (REST or PUB/SUB) for interoperating with the VNFMs. It integrates with additional components for the runtime management of a Network Service. For instance, it provides autoscaling and fault management based on monitoring information coming from the the monitoring system available at the NFVI level.

Source Code and documentation

The Source Code of the other Open Baton projects can be found here and the documentation can be found here .

News and Website

Check the Open Baton Website Follow us on Twitter @openbaton.

Licensing and distribution

Copyright [2015-2016] Open Baton project

Licensed under the Apache License, Version 2.0 (the "License");

you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Support

The Open Baton project provides community support through the Open Baton Public Mailing List and through StackOverflow using the tags openbaton.

Supported by

python-vnfm-sdk's People

Contributors

ananyajh avatar flaviomu avatar gc4rella avatar lorenzotomasini avatar mcilloni avatar mpauls avatar thomasbri avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar

python-vnfm-sdk's Issues

Not able to run as non-root. /var/log/openbaton Permission Denied!

The error

When running a VNFM implemented with the SDK, the following error occurs if you run as a regular user:

Traceback (most recent call last):
File "/vagrant/openiotfog-vnfm/oif_vnfm/main.py", line 41, in
main()
File "/usr/local/lib/python3.5/dist-packages/click/core.py", line 764, in call
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.5/dist-packages/click/core.py", line 717, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.5/dist-packages/click/core.py", line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.5/dist-packages/click/core.py", line 555, in invoke
return callback(*args, **kwargs)
File "/vagrant/openiotfog-vnfm/oif_vnfm/main.py", line 37, in main
start_vnfm_instances(OIFVNFManager, config_file, 5)
File "/usr/local/lib/python3.5/dist-packages/openbaton/vnfm.py", line 673, in start_vnfm_instances
l = VnfmListener(vnfm_klass, config_file_path, kwargs)
File "/usr/local/lib/python3.5/dist-packages/openbaton/vnfm.py", line 83, in init
os.makedirs(logging_dir)
File "/usr/lib/python3.5/os.py", line 241, in makedirs
mkdir(name, mode)
PermissionError: [Errno 13] Permission denied: '/var/log/openbaton/'

Process finished with exit code 1

Workaraound

If we create the following directory and give the user permissions to write, the error is gone.

Expected behaviour

If the user have no permission to setup the log in /var/log, the log should be created locally, in the users Home and a warning log message shown to let him know that the log is not in the default location.

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.