Red Hat Training

A Red Hat training course is available for Red Hat Enterprise Linux

章 12. 在​​​​​​​網​​​​​​​路​​​​​​​上​​​​​​​的​​​​​​​使​​​​​​​用​​​​​​​設​​​​​​​定​​​​​​​

將​​​​​​​ Red Hat 虛​​​​​​​擬​​​​​​​化​​​​​​​整​​​​​​​合​​​​​​​入​​​​​​​您​​​​​​​的​​​​​​​網​​​​​​​路​​​​​​​架​​​​​​​構​​​​​​​是​​​​​​​項​​​​​​​很​​​​​​​複​​​​​​​雜​​​​​​​的​​​​​​​程​​​​​​​序​​​​​​​,並​​​​​​​且​​​​​​​這​​​​​​​也​​​​​​​依​​​​​​​照​​​​​​​您​​​​​​​的​​​​​​​基​​​​​​​礎​​​​​​​架​​​​​​​構​​​​​​​,這​​​​​​​可​​​​​​​能​​​​​​​會​​​​​​​需​​​​​​​要​​​​​​​自​​​​​​​定​​​​​​​的​​​​​​​設​​​​​​​定​​​​​​​來​​​​​​​展​​​​​​​開​​​​​​​多​​​​​​​重​​​​​​​乙​​​​​​​太​​​​​​​網​​​​​​​路​​​​​​​介​​​​​​​面​​​​​​​以​​​​​​​及​​​​​​​橋​​​​​​​接​​​​​​​設​​​​​​​定​​​​​​​的​​​​​​​部​​​​​​​署​​​​​​​。​​​​​​​
Each domain network interface is connected to a virtual network interface in dom0 by a point to point link. These devices are vif <domid> and <vifid>. vif1.0 for the first interface in domain 1; vif3.1 for the second interface in domain 3.
為​​​​​​​了​​​​​​​要​​​​​​​能​​​​​​​處​​​​​​​理​​​​​​​這​​​​​​​些​​​​​​​虛​​​​​​​擬​​​​​​​介​​​​​​​面​​​​​​​的​​​​​​​流​​​​​​​量​​​​​​​, domain0 使​​​​​​​用​​​​​​​標​​​​​​​準​​​​​​​的​​​​​​​ Linux 常​​​​​​​規​​​​​​​來​​​​​​​橋​​​​​​​接​​​​​​​、​​​​​​​路​​​​​​​徑​​​​​​​選​​​​​​​擇​​​​​​​、​​​​​​​速​​​​​​​率​​​​​​​限​​​​​​​制​​​​​​​等​​​​​​​等​​​​​​​。​​​​​​​xend daemon 使​​​​​​​用​​​​​​​了​​​​​​​兩​​​​​​​個​​​​​​​ shell script 來​​​​​​​執​​​​​​​行​​​​​​​您​​​​​​​的​​​​​​​網​​​​​​​路​​​​​​​以​​​​​​​及​​​​​​​新​​​​​​​的​​​​​​​虛​​​​​​​擬​​​​​​​介​​​​​​​面​​​​​​​最​​​​​​​初​​​​​​​的​​​​​​​設​​​​​​​定​​​​​​​。​​​​​​​這​​​​​​​些​​​​​​​ script 會​​​​​​​為​​​​​​​所​​​​​​​有​​​​​​​的​​​​​​​虛​​​​​​​擬​​​​​​​介​​​​​​​面​​​​​​​設​​​​​​​定​​​​​​​一​​​​​​​個​​​​​​​單​​​​​​​獨​​​​​​​的​​​​​​​橋​​​​​​​接​​​​​​​。​​​​​​​您​​​​​​​能​​​​​​​夠​​​​​​​自​​​​​​​定​​​​​​​這​​​​​​​些​​​​​​​ script 來​​​​​​​設​​​​​​​定​​​​​​​其​​​​​​​他​​​​​​​的​​​​​​​選​​​​​​​路​​​​​​​與​​​​​​​橋​​​​​​​接​​​​​​​。​​​​​​​
Red Hat Virtualization's virtual networking is controlled by the two shell scripts, network-bridge and vif-bridge. xend calls these scripts when certain events occur. Arguments can be passed to the scripts to provide additional contextual information. These scripts are located in the /etc/xen/scripts directory. You can change script properties by modifying the xend-config.sxp configuration file located in the /etc/xen directory.
network-bridge — 當​​​​​​​ xend 啟​​​​​​​動​​​​​​​或​​​​​​​者​​​​​​​是​​​​​​​停​​​​​​​止​​​​​​​後​​​​​​​,這​​​​​​​個​​​​​​​ script 便​​​​​​​會​​​​​​​隨​​​​​​​著​​​​​​​它​​​​​​​開​​​​​​​啟​​​​​​​或​​​​​​​者​​​​​​​是​​​​​​​關​​​​​​​閉​​​​​​​虛​​​​​​​擬​​​​​​​網​​​​​​​路​​​​​​​。​​​​​​​之​​​​​​​後​​​​​​​設​​​​​​​定​​​​​​​的​​​​​​​初​​​​​​​始​​​​​​​化​​​​​​​便​​​​​​​會​​​​​​​建​​​​​​​立​​​​​​​ xen—br0 這​​​​​​​個​​​​​​​橋​​​​​​​接​​​​​​​器​​​​​​​然​​​​​​​後​​​​​​​將​​​​​​​ eth0 移​​​​​​​動​​​​​​​至​​​​​​​這​​​​​​​個​​​​​​​橋​​​​​​​接​​​​​​​器​​​​​​​上​​​​​​​並​​​​​​​隨​​​​​​​著​​​​​​​更​​​​​​​改​​​​​​​路​​​​​​​由​​​​​​​的​​​​​​​選​​​​​​​擇​​​​​​​。​​​​​​​當​​​​​​​ xend 最​​​​​​​後​​​​​​​終​​​​​​​於​​​​​​​跳​​​​​​​出​​​​​​​之​​​​​​​後​​​​​​​,它​​​​​​​就​​​​​​​會​​​​​​​將​​​​​​​這​​​​​​​個​​​​​​​橋​​​​​​​接​​​​​​​器​​​​​​​刪​​​​​​​除​​​​​​​掉​​​​​​​然​​​​​​​後​​​​​​​移​​​​​​​除​​​​​​​ eth0,並​​​​​​​由​​​​​​​此​​​​​​​來​​​​​​​復​​​​​​​原​​​​​​​至​​​​​​​原​​​​​​​本​​​​​​​的​​​​​​​ IP 以​​​​​​​及​​​​​​​選​​​​​​​路​​​​​​​設​​​​​​​定​​​​​​​。​​​​​​​
網​​​​​​​域​​​​​​​上​​​​​​​的​​​​​​​所​​​​​​​有​​​​​​​虛​​​​​​​擬​​​​​​​介​​​​​​​面​​​​​​​都​​​​​​​引​​​​​​​用​​​​​​​了​​​​​​​ vif-bridge 這​​​​​​​個​​​​​​​ script。​​​​​​​它​​​​​​​能​​​​​​​設​​​​​​​定​​​​​​​防​​​​​​​火​​​​​​​牆​​​​​​​的​​​​​​​規​​​​​​​則​​​​​​​,並​​​​​​​且​​​​​​​也​​​​​​​能​​​​​​​將​​​​​​​ vif 附​​​​​​​加​​​​​​​至​​​​​​​適​​​​​​​當​​​​​​​的​​​​​​​橋​​​​​​​接​​​​​​​器​​​​​​​上​​​​​​​。​​​​​​​
您​​​​​​​還​​​​​​​有​​​​​​​一​​​​​​​些​​​​​​​其​​​​​​​他​​​​​​​能​​​​​​​夠​​​​​​​用​​​​​​​來​​​​​​​幫​​​​​​​助​​​​​​​將​​​​​​​ Red Hat 虛​​​​​​​擬​​​​​​​化​​​​​​​設​​​​​​​定​​​​​​​在​​​​​​​您​​​​​​​系​​​​​​​統​​​​​​​上​​​​​​​的​​​​​​​ script,就​​​​​​​像​​​​​​​是​​​​​​​ network-route、​​​​​​​network-nat、​​​​​​​vif-route,、​​​​​​​以​​​​​​​及​​​​​​​ vif-nat。​​​​​​​或​​​​​​​是​​​​​​​這​​​​​​​些​​​​​​​ script 也​​​​​​​能​​​​​​​以​​​​​​​自​​​​​​​定​​​​​​​的​​​​​​​變​​​​​​​體​​​​​​​來​​​​​​​替​​​​​​​代​​​​​​​。​​​​​​​