17 | | This set of tests includes a Setup section to set some variables, a Creation section to create a sliver, and then additional sections to do various tests with it. |
18 | | |
19 | | You only need to do the Setup section once. |
20 | | |
21 | | You need to repeat the Creation section before doing any of the other sections, because the Creation section sets some variables that you'll need for the other sections, and each of the other sections concludes by deleting the sliver. |
| 17 | This section contains multiple tests, and includes a Setup subsection to set some variables, a Creation subsection to create a sliver, and then additional subsections to do various tests with it. |
| 18 | |
| 19 | You only need to do the Setup subsection once. |
| 20 | |
| 21 | You need to repeat the Creation subsection before doing any of the other subsections, because the Creation subsection sets some variables that you'll need for the other subsections, and each of the other subsections concludes by deleting the sliver. |
123 | | NOTE: Do the [wiki:OpenFlow/FOAM/Testing#Creation Creation] section immediately before starting this section. |
124 | | |
125 | | NOTE: This section needs to be revamped to match the new assumption that when you create a sliver, it will be automatically approved. |
126 | | |
127 | | The steps in this section look at a newly-created sliver, approve it, confirm that it shows up in the FlowVisor, delete it, and confirm that it vanishes from the FlowVisor. |
| 124 | NOTE: Do the [wiki:OpenFlow/FOAM/Testing#Creation Creation] subsection immediately before starting this subsection. |
| 125 | |
| 126 | NOTE: This subsection needs to be revamped to match the new assumption that when you create a sliver, it will be automatically approved. |
| 127 | |
| 128 | The steps in this subsection look at a newly-created sliver, approve it, confirm that it shows up in the FlowVisor, delete it, and confirm that it vanishes from the FlowVisor. |
216 | | NOTE: Do the [wiki:OpenFlow/FOAM/Testing#Creation Creation] section immediately before starting this section. |
217 | | |
218 | | The steps in this section look at a newly-created sliver, run through a sequence of approve/disable/reject actions to confirm that it can transition from any of those states to the others, and check the FlowVisor after each change; then delete the sliver, and confirm that it vanishes from the FlowVisor. |
219 | | |
220 | | NOTE: These steps are run directly on the FOAM/FlowVisor server, rather than on your Omni client system. If those aren't the same server, do the 'foamctl' commands on the FOAM server, and the 'fvctl' commands on the FV server. |
| 217 | NOTE: Do the [wiki:OpenFlow/FOAM/Testing#Creation Creation] subsection immediately before starting this subsection. |
| 218 | |
| 219 | The steps in this subsection look at a newly-created sliver, run through a sequence of approve/disable/reject actions to confirm that it can transition from any of those states to the others, and check the FlowVisor after each change; then delete the sliver, and confirm that it vanishes from the FlowVisor. |
| 220 | |
| 221 | NOTE: These steps are run directly on the FOAM/FlowVisor server, rather than on your Omni client system. If those aren't the same server, do the FOAM commands on the FOAM server, and the FlowVisor commands on the FV server. |
235 | | foamctl geni:show-sliver -u $sliver_urn --passwd-file=/opt/foam/etc/foampasswd |
236 | | fvctl --passwd-file=/etc/flowvisor/fvpasswd getSliceInfo $fv_slicename |
237 | | fvctl --passwd-file=/etc/flowvisor/fvpasswd listFlowSpace | grep $fv_slicename |
238 | | }}} |
239 | | |
240 | | (Ignore warnings saying that it can't connect to the sliver's controller, if any; and likewise every time you confirm that the sliver shows up in Flowvisor below.) |
| 236 | foam-confirm-sliver $sliver_urn status approved |
| 237 | flowvisor-confirm-fvslice-exists $fv_slicename true |
| 238 | flowvisor-confirm-flowspace-rule-count $fv_slicename 2 |
| 239 | }}} |
333 | | foamctl geni:show-sliver -u $sliver_urn --passwd-file=/opt/foam/etc/foampasswd |
334 | | fvctl --passwd-file=/etc/flowvisor/fvpasswd getSliceInfo $fv_slicename |
335 | | fvctl --passwd-file=/etc/flowvisor/fvpasswd listFlowSpace | grep $fv_slicename |
336 | | }}} |
337 | | |
338 | | That set of tests should generate six e-mail messages to the experimenter and eight to the FOAM admin: There should be a "sliver approved" message, then "sliver rejected", then "sliver disabled", then rejected, approved, and deleted. Probably in that order, although e-mail is sometimes delivered out of sequence, so don't worry too much if they're not in order. |
| 332 | foam-confirm-sliver $sliver_urn deleted true |
| 333 | flowvisor-confirm-fvslice-exists $fv_slicename false |
| 334 | flowvisor-confirm-flowspace-rule-count $fv_slicename 0 |
| 335 | }}} |
| 336 | |
| 337 | That set of tests should generate six e-mail messages to the experimenter and six to the FOAM admin: There should be a "sliver approved" message, then "sliver rejected", then "sliver disabled", then rejected, approved, and deleted. Probably in that order, although e-mail is sometimes delivered out of sequence, so don't worry too much if they're not in order. |
342 | | NOTE: Do the [wiki:OpenFlow/FOAM/Testing#Creation Creation] section immediately before starting this section. |
343 | | |
344 | | The steps in this section look at a newly-created sliver, and test expiration in FOAM, by changing its expiration date and, then running the scripts that expire slivers and notify about soon-to-expire ones. |
| 341 | NOTE: Do the [wiki:OpenFlow/FOAM/Testing#Creation Creation] subsection immediately before starting this subsection. |
| 342 | |
| 343 | The steps in this subsection look at a newly-created sliver, and test expiration in FOAM, by changing its expiration date and, then running the scripts that expire slivers and notify about soon-to-expire ones. |
349 | | ssh $foamserver foamctl geni:show-sliver -u $sliver_urn --passwd-file=/opt/foam/etc/foampasswd |
350 | | ssh $fvserver fvctl --passwd-file=/etc/flowvisor/fvpasswd getSliceInfo $fv_slicename |
351 | | ssh $fvserver fvctl --passwd-file=/etc/flowvisor/fvpasswd listFlowSpace | grep $fv_slicename |
352 | | }}} |
353 | | |
354 | | (Ignore warnings saying that it can't connect to the sliver's controller, if any; and likewise every time you confirm that the sliver shows up in Flowvisor below.) |
| 348 | foam-confirm-sliver $sliver_urn status approved |
| 349 | flowvisor-confirm-fvslice-exists $fv_slicename true |
| 350 | flowvisor-confirm-flowspace-rule-count $fv_slicename 2 |
| 351 | }}} |
473 | | Confirm that the sliver no longer shows up in FOAM: |
474 | | |
475 | | {{{ |
476 | | ssh $foamserver foamctl geni:show-sliver -u $sliver_urn --passwd-file=/opt/foam/etc/foampasswd |
477 | | ssh $foamserver foamctl geni:list-slivers --passwd-file=/opt/foam/etc/foampasswd | grep $slice_urn |
478 | | }}} |
479 | | |
480 | | (Expect 'deleted' to be "True" for the first, and no output for the second. For the first, note that 'status' will still be "Approved", which is fine, it's just tracking what the status was when it was deleted.) |
481 | | |
482 | | Confirm that the sliver no longer shows up in FlowVisor: |
483 | | |
484 | | {{{ |
485 | | ssh $fvserver fvctl --passwd-file=/etc/flowvisor/fvpasswd getSliceInfo $fv_slicename |
486 | | ssh $fvserver fvctl --passwd-file=/etc/flowvisor/fvpasswd listFlowSpace | grep $fv_slicename |
487 | | }}} |
488 | | |
489 | | (Expect a "slice does not exist" error for the first, and no output for the second.) |
| 470 | Confirm that the sliver was deleted, does not show up in FlowVisor, and has no flowspace rules:: |
| 471 | |
| 472 | {{{ |
| 473 | foam-confirm-sliver $sliver_urn deleted true |
| 474 | flowvisor-confirm-fvslice-exists $fv_slicename false |
| 475 | flowvisor-confirm-flowspace-rule-count $fv_slicename 0 |
| 476 | }}} |