Docker Linux Container - Open vSwitch Containers - Múltiplos Servidores
Neste tutorial, vou abordar de uma forma um pouco mais complexa a configuração do Docker Container. Pensando no conceito de Cloud Computing e também no conceito de múltiplas zonas, resolvi então implementar o Open vSwitch (OVS) no ambiente em que estou estudando.
[ Hits: 19.112 ]
Por: evandro matos couto em 27/05/2015
#!/bin/bash # Iniciando o Container. # Não ativando nenhum tipo de rede pelo docker. # Ativando privilégios do root. # Aqui o legal da brincadeira. Criando uma interface Bridge, passando um IP, MAC, GW e por fim o hostname do Container. # -d o Container rodará em background -t -i para usar o /bin/bash. docker run \ --net="none" \ -v /opt/ubuntu:/map-dir-ubuntu \ --privileged \ --lxc-conf="lxc.network.type = veth" \ --lxc-conf="lxc.network.link = docker0" \ --lxc-conf="lxc.network.flags = up" \ --lxc-conf="lxc.network.hwaddr=5e:1e:bf:52:7c:ac" \ --lxc-conf="lxc.network.ipv4 = 172.16.42.10/24" \ --lxc-conf="lxc.network.ipv4.gateway = 172.16.42.1" \ --lxc-conf="lxc.utsname=docker-ubuntu-1" \ -d -t -i ubuntu /bin/bash
eth0 Link encap:Ethernet HWaddr 5e:1e:bf:52:7c:ac inet addr:172.16.42.10 Bcast:172.16.42.255 Mask:255.255.255.0 inet6 addr: fe80::5c1e:bfff:fe52:7cac/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:6 errors:0 dropped:0 overruns:0 frame:0 TX packets:6 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:468 (468.0 B) TX bytes:468 (468.0 B) lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
#!/bin/bash # Iniciando o Container. # Não ativando nenhum tipo de rede pelo docker. # Ativando privilégios do root. # Aqui o legal da brincadeira. Criando uma interface Bridge, passando um IP, MAC, GW e por fim o hostname do Container. # -d o Container rodará em background -t -i para usar o /bin/bash. docker run \ --net="none" \ -v /opt/ubuntu:/map-dir-ubuntu \ --privileged \ --lxc-conf="lxc.network.type = veth" \ --lxc-conf="lxc.network.link = docker0" \ --lxc-conf="lxc.network.flags = up" \ --lxc-conf="lxc.network.hwaddr=5e:1e:bf:52:7c:bb" \ --lxc-conf="lxc.network.ipv4 = 172.16.42.20/24" \ --lxc-conf="lxc.network.ipv4.gateway = 172.16.42.2" \ --lxc-conf="lxc.utsname=docker-ubuntu-2" \ -d -t -i ubuntu /bin/bash
eth0 Link encap:Ethernet HWaddr 5e:1e:bf:52:7c:ac inet addr:172.16.42.20 Bcast:172.16.42.255 Mask:255.255.255.0 inet6 addr: fe80::5c1e:bfff:fe52:7cac/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:6 errors:0 dropped:0 overruns:0 frame:0 TX packets:6 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:468 (468.0 B) TX bytes:468 (468.0 B) lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Quota - Criando e administrando no CentOS
Instalação do Nagios Core no CentOS 5.5
Clonagem de HDs com o PHANTOM & UDPCAST no CentOS
HAproxy + Stunnel (https) + CentOS 6
Alta disponibilidade: CentOS 6 - configurando os pacotes DRBD com gfs2 - parte 1
Free Animation e Game Developer com Linux
Kernel 3.0-0 já disponível no aptosid e operando de forma estável
Internet Explorer no Linux 100% funcional
Fscrypt: protegendo arquivos do seu usuário sem a lentidão padrão de criptograr o disco
Faça suas próprias atualizações de pacotes/programas no Void Linux e torne-se um Contribuidor
Como rodar o Folding@home no Linux
Criando um painel de controle (Dashboard) para seu servidor com o Homepage
O Abismo entre o Código e o Chão: Saltos Tecnológicos e a Exclusão Estrutural no Brasil
Utilizando a Ferramenta xcheckrestart no Void Linux
Pisando no acelerador do Linux Mint: Kernel XanMod, zRAM e Ajustes de Swap
Como compilar kernel no Linux Mint
Abrir um arquivo URL pelo Clipper (8)
Seno, Coseno, Tangente em CLIPPER (1)
Inserir uma URL num arquvo pelo Ubuntu (CLIPPER) (0)
VMWare Player não conecta na rede nem consigo intercambiar arquivos (1)









