VirtualBox 安装CentOS6.5
2015-02-15 00:00
435 查看
1)在“命令行模式下”以root身份进入系统
(2)用Vi编辑器对相关文件进行编辑:#vi /etc/inittab
(3)将其中的:init:3修改为:init:5
(4)保存并退出::wq
(5)重新启动系统:#reboot
————————————————设置图形界面的方式————————————————————————
1.设置虚拟机使用桥联方式连接宿主机
2.修改虚拟机centos上的网卡配置/etc/sysconfig/network-scripts/ifcfg-eth0
[root@localhost tomener]# vim /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
HWADDR=00:0C:29:45:97:65
TYPE=Ethernet
UUID=18d76aa8-6142-45fa-98dd-4e0d391fc90c
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=static
NETMASK=255.255.255.0
IPADDR=192.168.1.200
GATEWAY=192.168.1.1
DNS1=8.8.8.8
提示:BOOTPROTO的设置,可以设置为static 或者 dhcp
三、禁止掉SELINUX
[root@localhost tomener]# vim /etc/selinux/config
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
#SELINUX=enforcing
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
这里是把SELINUX=enforcing 改为 SELINUX=disabled
第四步:重启network
service network restart
第五步:ping www.baidu.com
[root@localhost tomener]# ping www.baidu.com
PING www.a.shifen.com (115.239.210.26) 56(84) bytes of data.
64 bytes from 115.239.210.26: icmp_seq=1 ttl=55 time=204 ms
64 bytes from 115.239.210.26: icmp_seq=2 ttl=55 time=119 ms
到此,让在vmware虚拟机上的centos上网,并起和本机通信就完成了。
如果重启了network还是连接不上,那么先关闭服务器,再启动,不要用重启试试。
(2)用Vi编辑器对相关文件进行编辑:#vi /etc/inittab
(3)将其中的:init:3修改为:init:5
(4)保存并退出::wq
(5)重新启动系统:#reboot
————————————————设置图形界面的方式————————————————————————
1.设置虚拟机使用桥联方式连接宿主机
2.修改虚拟机centos上的网卡配置/etc/sysconfig/network-scripts/ifcfg-eth0
[root@localhost tomener]# vim /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
HWADDR=00:0C:29:45:97:65
TYPE=Ethernet
UUID=18d76aa8-6142-45fa-98dd-4e0d391fc90c
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=static
NETMASK=255.255.255.0
IPADDR=192.168.1.200
GATEWAY=192.168.1.1
DNS1=8.8.8.8
提示:BOOTPROTO的设置,可以设置为static 或者 dhcp
三、禁止掉SELINUX
[root@localhost tomener]# vim /etc/selinux/config
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
#SELINUX=enforcing
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
这里是把SELINUX=enforcing 改为 SELINUX=disabled
第四步:重启network
service network restart
第五步:ping www.baidu.com
[root@localhost tomener]# ping www.baidu.com
PING www.a.shifen.com (115.239.210.26) 56(84) bytes of data.
64 bytes from 115.239.210.26: icmp_seq=1 ttl=55 time=204 ms
64 bytes from 115.239.210.26: icmp_seq=2 ttl=55 time=119 ms
到此,让在vmware虚拟机上的centos上网,并起和本机通信就完成了。
如果重启了network还是连接不上,那么先关闭服务器,再启动,不要用重启试试。
相关文章推荐
- VirtualBox 下安装CentOS6.5增强功能遇到的问题与解决方案
- 不想作死系列---virtualbox最小化安装centos6.5
- VirtualBox安装CentOS6.5
- VirtualBox安装CentOS-6.5
- 宿主系统为Ubuntu 14,CentOS 6.5 安装VirtualBox增强工具失败:Building the OpenGL support module[FAILED]
- VirtualBox 上安装CentOS 6.5
- centos6.5在VMware和Oracle VM VirtualBox下安装的区别
- 虚拟机oracle virtualbox 上安装centos6.5
- CentOS6.5菜鸟之旅:安装VirtualBox4.3
- CentOS6.5安装VirtualBox-5.1
- VirtualBox 安装 CentOS6.5 教程
- virtualbox安装centos6.5碰到的问题
- VirtualBox 安装 CentOS6.5 教程
- 虚拟机oracle virtualbox 上安装centos6.5 网络设置
- centos6.5 安装virtualbox4.3
- CentOS6.5桌面版安装VirtualBox提示错误/etc/init.d/vboxdrv setup
- VirtualBox安装增强功能(CentOS 6.5)
- VirtualBox 4.3.6上安装CentOS 6.5
- virtualbox中centos6.5安装samba实现win10中访问共享文件夹
- virtualbox上安装centos6.5以及安装Java,redis,hadoop等等常用开发工具