Skip to content

Long Lived Slices

Tom Mitchell edited this page Jun 11, 2015 · 1 revision

Long Lived Slices

Some slices run services for use by other slices, or otherwise have to run for many months. Running such slices involves several particular concerns. Experimenters must carefully watch for maintenance alerts and service disruptions by GENI service providers; aggregate maintenance may at any point stop reserved resources or even lose state. As a result, all such slices should be fully re-creatable using scripts, and experimenters should periodically check the health of all their resources.

Additionally, slices in GENI are typically only good for at most 6 months at a time. Aggregates impose their own local policy for how long a sliver may be reserved for. Initial expiration times may be as short as 5 days at some aggregates, and maximum reservation durations may also be limited. As a result, experimenters running so-called "long lived slices" may want to periodically renew their slice and aggregate reservations (slivers).

You can easily renew your slice and slivers from the GENI Portal. You can also easily do this using Omni. First, pick a date for the new expiration (say, 30-60 days in the future). Note that some aggregates only allow expirations at most 14 days in the future.

To renew your slice using Omni:

omni renewslice <slicename> <new expiration>

Once the slice is renewed, renew your slivers:

omni renewsliver <slicename> <new expiration> --alap --useSliceAggregates

geni-tools includes renewSliceAndSlivers.py, a sample script to perform these operations automatically. This script is suitable for running from a cron job.

A sample cron job could be set up like this:

Always renew your slice and slivers at least once after making the reservation before relying on this cron job.

Note that this sample puts all the command output in a file whose path you must specify. Check this file periodically. Alternatively, have the cron job mail the results to you. Note this sample assumes GCF/Omni is installed in /usr/local/gcf, and must be edited for the correct path to GCF, the correct slice name, and your username.

# Assumes GCF/Omni installed in /usr/local/gcf
# Assumes renewSliceAndSlivers.py installed in /usr/local/gcf/examples
# Assumes slice was created at the GENI Clearinghouse

PYTHONPATH=/usr/local/gcf/src
# Sample crontab entry:
# m h dom mon dow command
5 1 1,8,15,22   *    * /usr/bin/python /usr/local/gcf/examples/renewSliceAndSlivers.py YOURSLICENAME >> /home/YOURUSERNAME/slice-renew-logs.txt 2>&1