Suche senden
Hochladen
Virtualbox networking
•
1 gefällt mir
•
3,368 views
Chatchai Jantaraprim
Folgen
Melden
Teilen
Melden
Teilen
1 von 35
Jetzt herunterladen
Downloaden Sie, um offline zu lesen
Empfohlen
Android Control Hardware and Arduino IoT ( 22 Aug 15 )
Android Control Hardware and Arduino IoT ( 22 Aug 15 )
Adun Nanthakaew
Ch15 elastic hosts-svradmin
Ch15 elastic hosts-svradmin
Chatchai Jantaraprim
VBoxManage tutorial
VBoxManage tutorial
Bhuridech Sudsee
Ch06 bind9
Ch06 bind9
Chatchai Jantaraprim
virtualization (Hyper-V)
virtualization (Hyper-V)
Mohamed Hesham
Introduction to Hyper-V
Introduction to Hyper-V
Mark Wilson
Hyper V in Windows Server 2012
Hyper V in Windows Server 2012
Lai Yoong Seng
Ch10 web servers
Ch10 web servers
Chatchai Jantaraprim
Empfohlen
Android Control Hardware and Arduino IoT ( 22 Aug 15 )
Android Control Hardware and Arduino IoT ( 22 Aug 15 )
Adun Nanthakaew
Ch15 elastic hosts-svradmin
Ch15 elastic hosts-svradmin
Chatchai Jantaraprim
VBoxManage tutorial
VBoxManage tutorial
Bhuridech Sudsee
Ch06 bind9
Ch06 bind9
Chatchai Jantaraprim
virtualization (Hyper-V)
virtualization (Hyper-V)
Mohamed Hesham
Introduction to Hyper-V
Introduction to Hyper-V
Mark Wilson
Hyper V in Windows Server 2012
Hyper V in Windows Server 2012
Lai Yoong Seng
Ch10 web servers
Ch10 web servers
Chatchai Jantaraprim
Ch07 bind9-part2
Ch07 bind9-part2
Chatchai Jantaraprim
Ch11 web-app
Ch11 web-app
Chatchai Jantaraprim
Ch02 administrators-tasks
Ch02 administrators-tasks
Chatchai Jantaraprim
Ch12 web-app-part2
Ch12 web-app-part2
Chatchai Jantaraprim
Basic configuration fortigate v4.0 mr2
Basic configuration fortigate v4.0 mr2
Gol D Roger
CMNET Virtual Desktop Soulution
CMNET Virtual Desktop Soulution
Prasong Pansri
009 crma sensor-network-wip
009 crma sensor-network-wip
Mevenwen Singollo
Editors for-linux
Editors for-linux
Chatchai Jantaraprim
Ch17 secure-password
Ch17 secure-password
Chatchai Jantaraprim
Ch09 mail-systems-part2
Ch09 mail-systems-part2
Chatchai Jantaraprim
Ch08 mail-systems
Ch08 mail-systems
Chatchai Jantaraprim
Ch04 linux-hosting-vps
Ch04 linux-hosting-vps
Chatchai Jantaraprim
Ch05 name-services
Ch05 name-services
Chatchai Jantaraprim
Ch03 domain-registration
Ch03 domain-registration
Chatchai Jantaraprim
Ch01 administrators-tasks
Ch01 administrators-tasks
Chatchai Jantaraprim
Weitere ähnliche Inhalte
Ähnlich wie Virtualbox networking
Ch07 bind9-part2
Ch07 bind9-part2
Chatchai Jantaraprim
Ch11 web-app
Ch11 web-app
Chatchai Jantaraprim
Ch02 administrators-tasks
Ch02 administrators-tasks
Chatchai Jantaraprim
Ch12 web-app-part2
Ch12 web-app-part2
Chatchai Jantaraprim
Basic configuration fortigate v4.0 mr2
Basic configuration fortigate v4.0 mr2
Gol D Roger
CMNET Virtual Desktop Soulution
CMNET Virtual Desktop Soulution
Prasong Pansri
009 crma sensor-network-wip
009 crma sensor-network-wip
Mevenwen Singollo
Ähnlich wie Virtualbox networking
(7)
Ch07 bind9-part2
Ch07 bind9-part2
Ch11 web-app
Ch11 web-app
Ch02 administrators-tasks
Ch02 administrators-tasks
Ch12 web-app-part2
Ch12 web-app-part2
Basic configuration fortigate v4.0 mr2
Basic configuration fortigate v4.0 mr2
CMNET Virtual Desktop Soulution
CMNET Virtual Desktop Soulution
009 crma sensor-network-wip
009 crma sensor-network-wip
Mehr von Chatchai Jantaraprim
Editors for-linux
Editors for-linux
Chatchai Jantaraprim
Ch17 secure-password
Ch17 secure-password
Chatchai Jantaraprim
Ch09 mail-systems-part2
Ch09 mail-systems-part2
Chatchai Jantaraprim
Ch08 mail-systems
Ch08 mail-systems
Chatchai Jantaraprim
Ch04 linux-hosting-vps
Ch04 linux-hosting-vps
Chatchai Jantaraprim
Ch05 name-services
Ch05 name-services
Chatchai Jantaraprim
Ch03 domain-registration
Ch03 domain-registration
Chatchai Jantaraprim
Ch01 administrators-tasks
Ch01 administrators-tasks
Chatchai Jantaraprim
Mehr von Chatchai Jantaraprim
(8)
Editors for-linux
Editors for-linux
Ch17 secure-password
Ch17 secure-password
Ch09 mail-systems-part2
Ch09 mail-systems-part2
Ch08 mail-systems
Ch08 mail-systems
Ch04 linux-hosting-vps
Ch04 linux-hosting-vps
Ch05 name-services
Ch05 name-services
Ch03 domain-registration
Ch03 domain-registration
Ch01 administrators-tasks
Ch01 administrators-tasks
Virtualbox networking
1.
PSU-LUG/Sysadmin VirtualBox Networking
Chatchai J 2013-02-28
2.
VirtualBox Networking ●
เนื้อหาทั้งหมด เรียบเรียงจาก http://www.virtualbox.org/manual/ch06.html Chapter 6: Virtual Networking VirtualBox Manual
3.
Virtual Networking Hardware ●
อุปกรณ์ เลียนแบบการทำางานของ hardware – AMD PCNet PCI II (Am79C970A) – AMD PCNet FAST III (Am79C973, the default) – Intel PRO/1000 MT Desktop (82540EM) – Intel PRO/1000 T Server (82543GC) – Intel PRO/1000 MT Server (82545EM) ● ใช้งานได้กับ OS ที่มี driver สำาหรับ hardware จริงๆ เหล่านี้ (แทบทุก OS) – DOS?, Mac OSX?
4.
Virtual Networking Hardware
(cont) ● และ – Paravirtualized network adapter (virtio-net). ● สำาหรับ OS ที่รองรับการทำางานเป็ นแบบ Virtualized – รองรับทั้ง Linux, Windows รุ่นใหม่ (ใช้งานในปั จจุบัน) – Win2K ,XP ,Vista มี driver ให้ Download ● http://www.linux-kvm.org/page/WindowsGuestDrivers
5.
Virtual Networking Hardware
(cont) ● ข้อดี – ไม่ตอง emulate การทำางานของ hardware ที่ไม่จำาเป็ น ้ ● แนะนำาให้ใช้ virtio สำาหรับ Virtual Network Device ถ้า Guest OS support – ไม่จำากัดว่าจะต้องเป็ น VirtualBox ● ถ้าต้องเลือก – virtio > Intel Pro > AMD PCI
6.
Networking Mode ●
Not attached ● Network Address Translation (NAT) ● Bridged networking ● Internal networking ● Host-only networking ● Generic networking
7.
Networking Mode (cont)
8.
Networking Mode (cont) ●
Not attached – มี NIC แต่ไม่ต่อกับเครือข่ายใดๆ
9.
Networking Mode (cont) ●
Network Address Translation (NAT) – default (ใช้ VirtualBox NAT engine) – NIC1 => 10.0.2.0/24, NIC2 => 10.0.3.0/24 ● guest IP 10.0.X.15 ● host IP 10.0.X.2 – Gateway – DHCP Server – using host's DNS (/etc/resolv.conf)
10.
Networking Mode (cont) ●
Network Address Translation (NAT) – Network ของแต่ละ VM แยกเป็ นอิสระจากกัน
11.
Networking Mode (cont) ●
Network Address Translation (NAT) – การให้บริการโดย guest กับ host ภายนอก จะ ต้องใช้ port forwarding $ VBoxManage modifyvm "VM name" natpf1 "guestssh,tcp,,2222,,22" – สำาหรับ ssh connection เข้าไปที่ guest $ ssh p 2222 host
12.
Networking Mode (cont) ●
Network Address Translation (NAT) – SomeLimitation ● ICMP packet ● UDP Broadcast ● Support mainly TCP & UDP ● Forward port on host < 1024
13.
Networking Mode ●
Bridged networking – ใช้ host interface driver สำาหรับ filter data ส่งให้ กับ VM interface – การ config จะต้องเลือกว่า จะ bridge กับ interface ใหนของ host
14.
Networking Mode (cont) ●
Bridged networking
15.
Networking Mode (cont)
16.
Bridge Networking (cont)
17.
Bridge Networking (cont)
18.
Bridge Networking (cont) ●
bridge กับ wired interface บน Virtualbox จะใช้วิธีการ ต่างกับ wireless interface – ถ้ามีปัญหา ลองเปลี่ยนจาก wireless → wired ● สำาหรับ Linux – Bridge บน wireless support เฉพาะ IPv4 – Bridge อาจจะมีปัญหากับ VLAN (ขึ้ นอย่่กับ hardware ที่ใช้)
19.
Networking Mode (cont) ●
Internal networking – implement แบบเดียวกับ bridge – แต่ไม่เชื่อมต่อกับ network ภายนอก – ใช้เป็ น “internal network” ระหว่าง guest VM ด้วยกัน (Virtual Switch) – ถ้าต้องการต่อออกภายนอก อาจใช้ VM ที่ตออย่กับ internal ่ ่ network นี้ เพื่อทำาหน้าที่เป็ น router/gateway – ระบุ network ด้วยชื่อ
20.
Internal networking
21.
Internal networking (cont)
22.
Internal networking (cont)
23.
Internal networking (cont)
24.
Internal networking (cont) ●
โดยทั่วไปจะใช้ network config แบบ static สำาหรับ guest ● หรือ setup guest ตัวนึง ให้เป็ น DHCP Server ● ถ้าจะใช้ internal dhcp server จะต้องใช้ VboxManage $ VBoxManage dhcpserver add netname <network_name>
25.
Networking Mode (cont) ●
Host-only networking – คล้าย internal network – สำาหรับ guest VM ที่ตอ host-only network เดียวกันสื่อสารด้วยกัน ่ – เพิ่ม virtual interface ที่ตว host ซึ่งต่อกับ host-only network ั – จะต้องสร้าง host-only network interface ขึ้นมาก่อน
26.
Host-only networking ●
สร้าง host-only network interface ● VirtualBox Manager → Preference → Network → Add host-only network (INS) ● vboxnet0 (สร้างโดย default) ● vboxnet1 ● บน host $ /sbin/ifconfig a
27.
Host-only networking (cont)
28.
Host-only networking (cont)
29.
Host-only networking (cont) cj@nilanont64:~$ ifconfig a ... vboxnet0 Link encap:Ethernet HWaddr 0a:00:27:00:00:00 BROADCAST MULTICAST MTU:1500 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:1000 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
30.
Host-only networking (cont)
31.
Host-only networking (cont)
32.
Host-only networking (cont) ●
host-only สามารถ กำาหนด ip address (สำาหรับ vboxnetX interface) หรือ enable DHCP Server (สำาหรับ vboxnetX virtual network) ได้ โดยใช้ Edit host-only network (space)
33.
host-only networking (cont)
34.
Networking Mode (cont) ●
Generic networking – สำาหรับ Advanced Networking ● ผมก็ยังไม่เคยใช้ – เลยไม่รจะแนะนำายังไง (ฮา) ้่
35.
VirtualBox Networking
คำาถาม?
Jetzt herunterladen