| 286 | == (Optional) Real Time Graphs == |
| 287 | |
| 288 | On any Linux machine (including MAC OS), you can draw real-time CPU usage graphs for both VNF1 and VNF2 nodes. A Python script is provided to produce these real-time graphs. The script periodically retrieves the CPU usage file from the Controller node and plots the graph for it. |
| 289 | |
| 290 | 1. Download the python script ''!RealTimeGraph.py'' to your laptop using the following link. |
| 291 | |
| 292 | {{{ |
| 293 | #!html |
| 294 | <span style="background:#c0c0c0; font-size: 9pt"><b> http://csr.bu.edu/rina/grw-bu2016/nfv/RealTimeGraph.py <br></b> </span> |
| 295 | |
| 296 | }}} |
| 297 | |
| 298 | 2. Run the script and direct it to the CPU usage files (''NFV1.txt'' and ''NFV2.txt'') present at the controller. To run the Python script, type the following in the folder where you saved the ''!RealTimeGraph.py'' file: |
| 299 | |
| 300 | {{{ |
| 301 | #!html |
| 302 | <span style="background:#c0c0c0; font-size: 9pt"><b> python RealTimeGraph.py -n <username>@<controller IP address> -k <Path to your ssh key> ; <br></b> </span> |
| 303 | |
| 304 | }}} |
| 305 | |
| 306 | Change '''''<username>''''' to your user name, '''''<controller IP address>''''' to the IP address of the controller and '''''<Path to your ssh key>''''' is the path to your ssh key that you use to log into GENI nodes. |
| 307 | 3. You should see real-time CPU graphs as shown below: |
| 308 | |
| 309 | {{{ |
| 310 | #!html |
| 311 | <img src="http://csr.bu.edu/rina/grw-bu2016/tutorial_files/image096.gif" hspace=40> |
| 312 | |
| 313 | }}} |
| 314 | |
| 315 | {{{ |
| 316 | #!html |
| 317 | <table id="Table_02" width = "1150" border="0" cellpadding="0" cellspacing="10" > |
| 318 | <tr> |
| 319 | <td> <img src = "http://csr.bu.edu/rina/grw-bu2016/tutorial_files/image068.gif" > </td> |
| 320 | <td> <i>To run the Python script to plot graphs, you need the python plotting library <b>matplotlib</b>. If you do not have this library on your laptop, you can use the following link to download it to your computer: <a href = "http://matplotlib.org/users/installing.html">http://matplotlib.org/users/installing.html</a> </i> |
| 321 | </td></tr></table> |
| 322 | }}} |
| 323 | |
| 324 | |
| 325 | |
| 326 | |