Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

Introduction

The Flowvisor service is responsible for slicing the network, therefore, guaranteeing the isolation of the experimentation.

Installation

Setting up a Virtual Machine

1. Generate a new Xen VM and access its console. (TEST)

Note
Login with the root user

To create the virtual machine which will host the flowvisor, run in your terminal the commands below. Pay attention to substitute the "XXX" for your Island ID and the "YYYY" for your Institution acronym.

Code Block
themeMidnight
languagebash
xen-create-image --install-method=debootstrap --size 10G --memory 4098Mb --fs=ext3 --dist wheezy --pygrub --passwd --ip 10.XXX.0.101 --netmask=255.255.0.0 --gateway=10.XXX.0.30 --bridge=br_control --hostname=flowvisor.YYYY.org.br

 
xm create -c flowvisor.cfg

The first command will create the virtual machine and the second one will start up the VM and login in console mode.

Note
We will use the Flowvisor version 0.8 for this tutorial.

Installing the Flowvisor

Code Block
themeMidnight
languagebash
wget -q http://updates.onlab.us/GPG-KEY-ONLAB -O- | apt-key add -
sh -c "echo 'deb http://updates.onlab.us/debian stable/' > /etc/apt/sources.list.d/flowvisor.list"
apt-get update
apt-get install flowvisor=0.8.17-3 sudo

Run the flowvisor configuration tool to set the password and create your certificate by changing the following parameters:

Code Block
themeMidnight
languagebash
sudo -u flowvisor fvconfig generate /etc/flowvisor/config.json <hostname> <admin_passwd> [<of_port> <api_port>]
Note
As an example: in our case we used the following parameters (the hostname refers to the ip that will be used in the OCF and the password used to access it):
Code Block
themeMidnight
languagebash
sudo -u flowvisor fvconfig generate /etc/flowvisor/config.json 10.XXX.0.101 ofelia

 

Enable the topology_server option in the  flowvisor  configuration file and then reload the configuration.

Code Block
themeMidnight
languagebash
sudo -u flowvisor sed -i 's/"run_topology_server": false/"run_topology_server": true/' /etc/flowvisor/config.json
sudo -u flowvisor fvconfig load /etc/flowvisor/config.json

 

To correct the flowvisor log behavior, edit the /etc/init.d/flowvisor startup script and add the -l parameter in the call to run the flowvisor:

Code Block
themeMidnight
languagebash
sed -i -e "s/\/sbin\/flowvisor /\/sbin\/flowvisor -l /ig" /etc/init.d/flowvisor

 

Start the Flowvisor service upon boot:

Code Block
themeMidnight
languagebash
update-rc.d flowvisor defaults
 
/etc/init.d/flowvisor start
Note
In case of errors when stating the service, try the following solution.
Code Block
themeMidnight
languagebash
rm /usr/local/share/db/flowvisor/FlowVisorDB/*.lck
 
/etc/init.d/flowvisor start

  Check the Flowvisor service status. 

Code Block
themeMidnight
languagebash
# service flowvisor status
FlowVisor is running as PID 4263

Log Configuration

After installing the Flowvisor service, configure the log level using this command:

Code Block
themeMidnight
languagebash
sudo sed -i -e 's/log4j.rootCategory=[A-Z]*,/log4j.rootCategory=WARN,/' /etc/flowvisor/fvlog.config

The expected effect is to reduce the verbose of the log.

After this step, it will be necessary to configure the logrotate and the crontab:

Access the following directory:

Code Block
themeMidnight
languagebash
cd /etc/logrotate.d

Create the following archive: flowvisor

And fill it with the following content:

Code Block
themeMidnight
languagebash
/var/log/flowvisor/flowvisor-stderr.log {
daily
rotate 0
compress
copytruncate
}

After this step it will be necessary to configure the crontab:

Code Block
themeMidnight
languagebash
crontab -e

Append the following line at the final:

Code Block
themeMidnight
languagebash
0 12 * * * /usr/sbin/logrotate --force /etc/logrotate.d/flowvisor >/dev/null 2>$