User Tools

Site Tools


cloud:recipe:networks

OPTIONALLY CREATING YOUR OWN NETWORK GEAR

Should you want to create a network of your own that your hosts will be on, not all of these options are necessary

openstack network create mynet --internal

Now create a subnet for your network. This is mandatory for launching instances in the network that you just created.

After this, we now consider you to be a Network Administrator, and that may be more than you bargained for. The meaning of this is that we hold you responsible for connectivity into and out of the subnet, and any conflicts that might arise from your usage of it.

The cloud will not restrict your choices without cause. This means you can create impossible and insane situations that have no valid solution. There's no unique danger to the cloud infrastructure, however.

You are now advised that there is no "correct" choice for subnet range and IP. Overlaps are not a concern unless you intend to perform route/tunneling among the overlapping regions.

openstack subnet create \
  --network mynet \
  --ip-version 4 \
  --subnet-range 192.168.222.0/24 \
  --allocation-pool start=192.168.222.10,end=192.168.222.240 \
  --dns-nameserver 128.135.164.141 mysubnet \
  --gateway 192.168.222.1 \
  --dhcp

After creating your own network and subnet(s), a router is also needed. However, a router is not needed if your instances only talk to each other. The router will take the gateway of your subnet automatically, and allow clients to access the internet via outbound NAT. Much more is possible, and a router is a prerequisite for the next step, which is inbound NAT (DNAT).

openstack router create --enable myrouter
openstack router add subnet myrouter mysubnet

With the router created and attached to your own subnet, develop it further. You need to obtain a free IP address on the UC Campus. We call this network campus37. The Internet-connected subnet on that network is called public37.

After this command, the router will have one leg in your subnet and one leg in the public campus network (and internet).

Only you will be able to use this address until you destroy it. DONT ever take more than you need and free this resource as soon as you project ends.

openstack router set myrouter \
  --external-gateway campus37 \
  --enable-snat

This is all that will be needed to launch instances. If you had used the network known as cloud, you can skip the steps for this custom network and subnet and router.

/var/lib/dokuwiki/data/pages/cloud/recipe/networks.txt · Last modified: 2020/11/10 14:22 by chudler