VirtualBox network / study environment setup for RHEL

I re-visited the RHEL study material and setup the environment again, noted down the procedure.

1, copied the *.vdi (rhel6std.vdi and RHEL6-Student.vdi) file from Lenovo ThinkPad T400 to my new Lenovo ThinkPad X1, created the new machine by importing the *.vdi, no need to install the system again.

2, setup the network at Linux Instructor and Linux Student

In VirtualBox Manager, File->Preferences...->Network, to create "VirtualBox Host-Only Ethernet Adapter #2" and "VirtualBox Host-Only Ethernet #3".

The Adapter #2 leave it as default,

The Adapter #3 set as below, server address allocated as 192.168.18.100, server mask as 255.255.255.0, address range as 192.168.18.101 ~ 192.168.18.254:

In Linux-student->Machine->Settings, set as below,

In Linux-Instructor->Machine->Settings, set as below,

In Windows, the network configuration as below,

Network configuration on Linux-Instructor, as I cloned the machine, I didn‘t change anything and tried to test the network connection, but failed, the configuration as below,

/etc/sysconfig/network-scripts/glsorig-ifcfg-eth0

DEVICE="eth0"

BOOTPROTO="static"

DNS1="192.168.0.254"

HOSTNAME="instructor.example.com"

HWADDR="00:0C:29:65:C0:CE"

IPADDR="192.168.0.254"

MTU="1500"

NETMASK="255.255.255.0"

NM_CONTROLLED="yes"

ONBOOT="yes"

/etc/sysconfig/network-scripts/ifcfg-br0

DEVICE=br0

BOOTPROTO=none

IPADDR=192.168.0.254

NETMASK=255.255.255.0

DNS1=192.168.0.254

HOSTNAME="instructor.example.com"

IPV6INIT=no

NAME="Bridge eth0"

NM_CONTROLLED=no

ONBOOT=yes

PEERNTP="no"

DELAY=0

TYPE=Bridge

USERCTL=no

/etc/sysconfig/network-scripts/ifcfg-br0:0

# gls remote.test interface

DEVICE=br0:0

IPADDR=192.168.1.254

NETMASK=255.255.255.0

TYPE=Ethernet

BOOTPROTO=none

IPV6INIT=no

USERCTL=no

/etc/sysconfig/network-scripts/ifcfg-eth0

DEVICE=eth0

BOOTPROTO=none

DNS1=192.168.0.254

HOSTNAME="instructor.example.com"

IPADDR=192.168.0.254

MTU=1500

NETMASK=255.255.255.0

NM_CONTROLLED=yes

ONBOOT=yes

BRIDGE=br0

TYPE=Ethernet

HWADDR=08:00:27:04:C7:4B

IPV6INIT=no

USERCTL=no

/etc/sysconfig/network-scripts/ifcfg-eth1

DEVICE=eth1

BOOTPROTO=dhcp

ONBOOT=yes

TYPE=Ethernet

IPV6INIT=no

USERCTL=no

/etc/sysconfig/network-scripts/ifcfg-lo

DEVICE=lo

IPADDR=127.0.0.1

NETMASK=255.0.0.0

NETWORK=127.0.0.0

# If you‘re having problems with gated making 127.0.0.0/8 a martian,

# you can change this to something else (255.255.255.255, for example)

BROADCAST=127.255.255.255

ONBOOT=yes

NAME=loopback

Bringing up interface eth0: Device eth0 does not seem to be present, delaying initialization.

Bringing up interface eth1: Device eth0 does not seem to be present, delaying initialization.

As below,

Delete the file /etc/udev/rules.d/70-persistent-net.rules, by commands:

mv 70-persistent-net.rules 70-persistent-net.rules.bak

reboot

encountered below problems,

change the MAC_address in the ethernet configuration file as required, by commands,

ifconfig -a                                    #this is to get the MAC address of the etho0

vim /etc/sysconfig/network-scripts/ifcfg-eth0   #modify the MAC address in the configuration file

service network restart

For Linux-Instructors network configuration, I configured all and I am not sure which file makes it work.

Network configuration on Linux-Student, as below,

[[email protected] Desktop]$ cat /etc/sysconfig/network-scripts/ifcfg-eth0

DEVICE=eth0

BOOTPROTO=none

IPADDR=192.168.0.101

NETMASK=255.255.255.0

ONBOOT=yes

GATEWAY=192.168.0.254

TYPE=Ethernet

DNS1=192.168.0.254

IPV6INIT=no

USERCTL=no

PEERDNS=no

and by command

setup

In "Device configuration" -> "eth0 (eth0) - Intel Corporation 82540EM Gigabit Ethernet Controller"

/etc/init.d/NetworkManager stop

chkconfig NetworkManager off

service network restart

3, testing the result from Linux-student and Linux-Instructor

the connection from Linux-student as Linux-student -> Linux-Instructor->Window Host-> Internet, testing ping 8.8.8.8, ping instructor.example.com, ping 192.168.0.254, all successful,

the connection from Linux -Instructor as, Linux-student -> Linux-Instructor->Window host-> Internet, testing ping 8.8.8.8, ping 192.168.0.101, all successful,

4, installation of VirtualBox Additions( VBOXADDITIONS_4.3.12_93733 ), and configure the share the folder between the Windows and Linux

Please refer to this link, http://xionghuilin.com/?p=7

5, reference links,

https://www.centos.org/forums/viewtopic.php?t=26971

https://www.centos.org/forums/viewtopic.php?t=7684

时间: 2024-12-23 02:26:45

VirtualBox network / study environment setup for RHEL的相关文章

ubuntu14.04 android develop environment setup for android and linux driver

//For android and linux driver// 1,install ubuntu14.04 usb boot, CD boot, vmware workstation install, etc take usb boot for an example, download Universal-USB-Installer-1.9.5.6.exe and ubuntu-14.04.2-desktop-amd64.iso at windows xp platform. i take m

virtualbox network

https://www.virtualbox.org/manual/ch06.html [nat]VBoxManage modifyvm "VM name" --natpf1 "guestssh,tcp,127.0.0.1,2222,,22"VBoxManage modifyvm "VM name" --natpf1 delete "guestssh" VBoxManage natnetwork add --netname n

[React Fundamentals] Development Environment Setup

In this lesson we'll setup a simple build process for converting our ES6 React components into ES5 using Babel and Webpack Install: npm i --save react react-dom npm i -D babel-loader babel-core babel-preset-es2015 babel-preset-react npm i -g babel we

debian network manager vpn setup

sudo apt-get install pptp-linux network-manager-pptp network-manager-openvpn network-manager-vpnc network-manager-openvpn-gnome network-manager-pptp-gnome sudo /etc/init.d/network-manager restart

ruby on rails environment setup

firstly ,we can install the latest version of ruby through ruby`s official site,  $./configure  $make   $sudo make install ,this is three cmd to install the ruby source code,as well as other c source code. secondly, we can install rails through cmd $

Azure Sphere Development Environment Setup

1. Visual Studio 目前,Visual Studio 2017/2019支持Azure Sphere开发,后续,微软会加入Visual Studio Code的支持.以Visual Studio 2019 Community为例(Pro版和Enterprise版也当然支持),用户需要先从官网下载.安装的时候,需要勾选Linux development with C++这个Workload,注意,还需要勾选C++ CMake tools for Linux和Embedded and

【Linux】VirtualBox网络配置桥接模式

VirtualBox网络配置桥接模式 CentOS/RHEL (虚拟机)配置 # 基于桥接模式设置固定 ip cat >> /etc/sysconfig/network-scripts/ifcfg-enp0s3 << EOF # network setting BOOTPROTO=static # 固定ip IPADDR=192.168.1.84 # 网关 GATEWAY=192.168.1.1 # DNS DNS1=8.8.8.8 DNS2=114.114.114.114 EOF

VirtualBox 下 CentOS6.5 网络配置(NAT) (公司内部用)

一. VirtualBox network 设定.其中Port Forward Rules 是为puty 连ssh做的隐射,这样就可以通过putty来连接centos了 2.先共享本地连接给virtual box 3.注意Host IP是这样得到的

[it-ebooks]电子书列表

#### it-ebooks电子书质量不错,但搜索功能不是很好 #### 格式说明  [ ]中为年份      ||  前后是标题和副标题  #### [2014]: Learning Objective-C by Developing iPhone Games || Leverage Xcode and Objective-C to develop iPhone games http://it-ebooks.info/book/3544/ Learning Web App Developmen