<环境:Windows7 VMware Station 11.0.0>
CentOS7官网下载:http://www.centos.org
CentOS7 360云盘:http://yunpan.cn/lk/cyeWkz5ISqhcN 提取码 ff9b(注:以后可能用到的软件我都会放到这里。百度网盘?容量不够了!)
输入命令
yum install net-tools -y
查看ip地址并记下。
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
输入如下命令,进入对应目录,编辑文件:
vi /etc/sysconfig/grub
然后,往这个文件中添加“net.ifnames=0 biosdevname=0”内容,如下图所示:
上图中,红框部分是我所添加的内容(注意它的位置)。紧接着,执行如下命令:
grub2-mkconfig -o /boot/grub2/grub.cfg
然后重启虚拟机,网卡名就正常了。开机还是有错误不管。Enter后ROOT登入。
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
原因:硬件,一般是raid卡不支持WRITE SAME特性
解决方法:规避WRITE SAME
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
0、打开putty登入系统
1、创建disable-write-same脚本(可放在/usr/local/sbin),内容(来自:http://ewen.mcneill.gen.nz/blog/media/disable-write-same):
#! /bin/sh
# Disable SCSI WRITE_SAME, which is not supported by underlying disk
# emulation. Run on boot from, eg, /etc/rc.local
#
# See http://www.it3.be/2013/10/16/write-same-failed/
#
# Written by Ewen McNeill , 2014-07-17
#---------------------------------------------------------------------------
find /sys/devices -name max_write_same_blocks |
while read DISK; do
echo 0 >"${DISK}"
done
2、修改脚本为可执行权限
chmod a+x disable-write-same
3、将脚本放入/etc/rc.local在开机时运行:<以后有什么开机就运行的就可以直接写到这里的尼!>
vi /etc/rc.local
sudo /usr/local/sbin/disable-write-same
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
(1)挂载VMware tools光盘
mount -t iso9660 -o loop /dev/cdrom /media
cp /media/* ~
tar zxf VMwareTools-9.9.0-2304977.tar.gz
cd vmware-tools-distrib/
./vmware-install.pl
提示没有安装perl编译器 那就安装perl:
yum install perl -y
./vmware-install.pl
一路Enter键。。。
(2)然后你就会发现你以前设置的虚拟机与主机的分享目录就会出现在/mnt/hgfs/目录下,为了方便访问你也可
以再你root/目录下创建一个到你的共享目录的软连接
ln -s /mnt/hgfs/shared_file/ ~/shared
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------