Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
source overcloudrc
neutron net-create default
neutron subnet-create --name default --gateway default
neutron net-create nova --router:external --provider:network_type vlan --provider:physical_network datacentre --provider:segmentation_id 10
neutron subnet-create --name nova --enable_dhcp=False --allocation-pool=start=,end= --gateway= nova
neutron subnet-update --dns-nameserver nova
neutron security-group-rule-create default --ethertype IPv4 --direction ingress
neutron router-create default_router
neutron router-gateway-set default_router nova
default_subnet_id=$(neutron subnet-list | grep '| default ' | awk '{ print $2; }')
neutron router-interface-add default_router $default_subnet_id
# verify that the default_router owns the gateway IP of the default subnet
neutron router-port-list default_router | grep
glance image-create --name fedora21 --disk-format qcow2 --container-format bare --is-public True --location ''
nova flavor-create m1.notsotiny auto 512 3 1
nova keypair-add undercloud --pub-key ~/.ssh/
default_net_id=$(neutron net-list | grep '| default ' | awk '{ print $2; }')
nova boot testvm --flavor m1.notsotiny --image fedora21 --key-name undercloud --security-groups default --nic net-id=$default_net_id
neutron floatingip-create nova
floating_ip_id=$(neutron floatingip-list | grep | awk '{ print $2; }')
testvm_ip=$(nova show testvm | grep 'default network' | awk '{ print $5; }')
testvm_port_id=$(neutron port-list | grep "$testvm_ip" | awk '{ print $2; }')
neutron floatingip-associate $floating_ip_id $testvm_port_id
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.