Skip to content

Instantly share code, notes, and snippets.

@hogepodge
Created October 8, 2014 06:06
Show Gist options
  • Save hogepodge/429ab5ad586be1f75508 to your computer and use it in GitHub Desktop.
Save hogepodge/429ab5ad586be1f75508 to your computer and use it in GitHub Desktop.
Bridge Creation Works CentOS 7 (old dhcp)
[root@allinone modules]# ifconfig
eno16777736: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.2.205 netmask 255.255.255.0 broadcast 192.168.2.255
inet6 fe80::20c:29ff:fe8f:d66f prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:6f txqueuelen 1000 (Ethernet)
RX packets 1413 bytes 200538 (195.8 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 821 bytes 127838 (124.8 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno33554984: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 172.16.33.173 netmask 255.255.255.0 broadcast 172.16.33.255
inet6 fe80::20c:29ff:fe8f:d679 prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:79 txqueuelen 1000 (Ethernet)
RX packets 98 bytes 15100 (14.7 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 29 bytes 4877 (4.7 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno50332208: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.11.165 netmask 255.255.255.0 broadcast 192.168.11.255
inet6 fe80::20c:29ff:fe8f:d683 prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:83 txqueuelen 1000 (Ethernet)
RX packets 326 bytes 109892 (107.3 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 227 bytes 22070 (21.5 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno67109432: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.22.169 netmask 255.255.255.0 broadcast 192.168.22.255
inet6 fe80::20c:29ff:fe8f:d68d prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:8d txqueuelen 1000 (Ethernet)
RX packets 103 bytes 15402 (15.0 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 36 bytes 5882 (5.7 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno83886656: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 172.16.44.169 netmask 255.255.255.0 broadcast 172.16.44.255
inet6 fe80::20c:29ff:fe8f:d697 prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:97 txqueuelen 1000 (Ethernet)
RX packets 98 bytes 15100 (14.7 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 23 bytes 4445 (4.3 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 0 (Local Loopback)
RX packets 4 bytes 420 (420.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 4 bytes 420 (420.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
[root@allinone ~]# cd /etc/puppet/modules/
[root@allinone modules]# git clone https://github.com/duritong/puppet-sysctl
Cloning into 'puppet-sysctl'...
remote: Counting objects: 351, done.
remote: Total 351 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (351/351), 41.66 KiB | 0 bytes/s, done.
Resolving deltas: 100% (95/95), done.
[root@allinone modules]# mv puppet-sysctl/ sysctl
[root@allinone modules]# git clone https://github.com/stackforge/puppet-vswitch
Cloning into 'puppet-vswitch'...
remote: Counting objects: 580, done.
remote: Total 580 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (580/580), 66.00 KiB | 0 bytes/s, done.
Resolving deltas: 100% (197/197), done.
[root@allinone modules]# mv puppet-vswitch vswitch
[root@allinone modules]# cd
[root@allinone ~]# sudo yum install https://repos.fedorapeople.org/repos/openstack/openstack-juno/rdo-release-juno-1.noarch.rpm
Loaded plugins: fastestmirror
rdo-release-juno-1.noarch.rpm | 12 kB 00:00:00
Examining /var/tmp/yum-root-ExLyve/rdo-release-juno-1.noarch.rpm: rdo-release-juno-1.noarch
Marking /var/tmp/yum-root-ExLyve/rdo-release-juno-1.noarch.rpm to be installed
Resolving Dependencies
--> Running transaction check
---> Package rdo-release.noarch 0:juno-1 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
============================================================================================================================================================================================================
Package Arch Version Repository Size
============================================================================================================================================================================================================
Installing:
rdo-release noarch juno-1 /rdo-release-juno-1.noarch 3.2 k
Transaction Summary
============================================================================================================================================================================================================
Install 1 Package
Total size: 3.2 k
Installed size: 3.2 k
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : rdo-release-juno-1.noarch 1/1
Verifying : rdo-release-juno-1.noarch 1/1
Installed:
rdo-release.noarch 0:juno-1
Complete!
[root@allinone ~]# yum install openvswitch
Loaded plugins: fastestmirror
base | 3.6 kB 00:00:00
extras | 3.4 kB 00:00:00
openstack-juno | 2.9 kB 00:00:00
puppetlabs-deps | 2.5 kB 00:00:00
puppetlabs-products | 2.5 kB 00:00:00
updates | 3.4 kB 00:00:00
(1/7): extras/7/x86_64/primary_db | 26 kB 00:00:00
(2/7): puppetlabs-deps/x86_64/primary_db | 5.2 kB 00:00:00
(3/7): base/7/x86_64/group_gz | 157 kB 00:00:00
(4/7): puppetlabs-products/x86_64/primary_db | 25 kB 00:00:00
(5/7): openstack-juno/primary_db | 128 kB 00:00:01
(6/7): base/7/x86_64/primary_db | 4.9 MB 00:00:03
(7/7): updates/7/x86_64/primary_db | 3.6 MB 00:00:24
Determining fastest mirrors
* base: centos.mbni.med.umich.edu
* extras: mirror.supremebytes.com
* updates: mirror.steadfast.net
Resolving Dependencies
--> Running transaction check
---> Package openvswitch.x86_64 0:2.0.0-6.el7 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
============================================================================================================================================================================================================
Package Arch Version Repository Size
============================================================================================================================================================================================================
Installing:
openvswitch x86_64 2.0.0-6.el7 openstack-juno 1.4 M
Transaction Summary
============================================================================================================================================================================================================
Install 1 Package
Total download size: 1.4 M
Installed size: 6.2 M
Is this ok [y/d/N]: y
Downloading packages:
warning: /var/cache/yum/x86_64/7/openstack-juno/packages/openvswitch-2.0.0-6.el7.x86_64.rpm: Header V4 RSA/SHA1 Signature, key ID df6674e3: NOKEY===- ] 381 kB/s | 1.0 MB 00:00:01 ETA
Public key for openvswitch-2.0.0-6.el7.x86_64.rpm is not installed
openvswitch-2.0.0-6.el7.x86_64.rpm | 1.4 MB 00:00:03
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-RDO-Juno
Importing GPG key 0xDF6674E3:
Userid : "rdo-juno-sign <rdo-info@redhat.com>"
Fingerprint: b643 39ca eebf d1ec 3ebf aeda eeca c5d5 df66 74e3
Package : rdo-release-juno-1.noarch (@/rdo-release-juno-1.noarch)
From : /etc/pki/rpm-gpg/RPM-GPG-KEY-RDO-Juno
Is this ok [y/N]: y
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : openvswitch-2.0.0-6.el7.x86_64 1/1
Verifying : openvswitch-2.0.0-6.el7.x86_64 1/1
Installed:
openvswitch.x86_64 0:2.0.0-6.el7
Complete!
[root@allinone ~]# service openvswitch start
Redirecting to /bin/systemctl start openvswitch.service
[root@allinone ~]# puppet apply ovs_test.pp
Notice: Compiled catalog for allinone.localdomain in environment production in 0.16 seconds
Notice: /Stage[main]/Test_ovs/Vs_bridge[brex]/ensure: created
Notice: /Stage[main]/Test_ovs/Vs_port[eno67109432]/ensure: created
Notice: Finished catalog run in 4.80 seconds
[root@allinone ~]# ifconfig
brex: flags=67<UP,BROADCAST,RUNNING> mtu 1500
inet 192.168.22.169 netmask 255.255.255.0 broadcast 192.168.22.255
inet6 fe80::a44e:60ff:fe65:868c prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:8d txqueuelen 0 (Ethernet)
RX packets 12 bytes 1348 (1.3 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 15 bytes 1602 (1.5 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno16777736: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.2.205 netmask 255.255.255.0 broadcast 192.168.2.255
inet6 fe80::20c:29ff:fe8f:d66f prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:6f txqueuelen 1000 (Ethernet)
RX packets 2162 bytes 260740 (254.6 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1294 bytes 182288 (178.0 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno33554984: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 172.16.33.173 netmask 255.255.255.0 broadcast 172.16.33.255
inet6 fe80::20c:29ff:fe8f:d679 prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:79 txqueuelen 1000 (Ethernet)
RX packets 110 bytes 16912 (16.5 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 29 bytes 4877 (4.7 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno50332208: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.11.165 netmask 255.255.255.0 broadcast 192.168.11.255
inet6 fe80::20c:29ff:fe8f:d683 prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:83 txqueuelen 1000 (Ethernet)
RX packets 8213 bytes 11378779 (10.8 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 3106 bytes 203583 (198.8 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno67109432: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet6 fe80::20c:29ff:fe8f:d68d prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:8d txqueuelen 1000 (Ethernet)
RX packets 127 bytes 18562 (18.1 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 55 bytes 7884 (7.6 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eno83886656: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 172.16.44.169 netmask 255.255.255.0 broadcast 172.16.44.255
inet6 fe80::20c:29ff:fe8f:d697 prefixlen 64 scopeid 0x20<link>
ether 00:0c:29:8f:d6:97 txqueuelen 1000 (Ethernet)
RX packets 112 bytes 17314 (16.9 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 25 bytes 4847 (4.7 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 0 (Local Loopback)
RX packets 4 bytes 420 (420.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 4 bytes 420 (420.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
[root@allinone ~]# ping google.com
PING google.com (173.194.33.103) 56(84) bytes of data.
64 bytes from sea09s16-in-f7.1e100.net (173.194.33.103): icmp_seq=1 ttl=128 time=16.9 ms
64 bytes from sea09s16-in-f7.1e100.net (173.194.33.103): icmp_seq=2 ttl=128 time=15.0 ms
^C
--- google.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 15.084/16.004/16.925/0.929 ms
[root@allinone ~]#
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment