在Fedora 4.0 中,用VMware 安装和使用Windows
+++++++++++++++++++++++++++++++++++++++++++
正文:
+++++++++++++++++++++++++++++++++++++++++++
VMware 是什么 ?
VMware 是一套能虚拟安装各种操作系统的软件;能为每个操作系统虚拟出安装操作系统的硬件环境;在VMware中的每个操作系统都是相对独立的,每个虚拟的系统都相当于一台独立的并带有系统的机器;
在VMware 中,您可以同时打开多个虚拟的操作系统;并且还能在一台机器上,虚拟多个操作系统来操作虚拟网络;比如您在Windows中安装和VMware ,就可以模拟架设局域网来学习;
VMware 有Linux、Windows以及MACOS等版本;
本文介绍的是VMware的 Linux 版本的安装和使用;
安装准备:
1、VMware Linux 版本;我用的是Linux版本VMware 5.0 的源码包 ;
2、Windows安装盘;
操作环境:
系统环境:Fedora Core 4.0 ,开发工具(gcc,automake,make,perl等);kernel-devel 要都安装上;
硬件环境;Intel C 1.4 ,内存512M,显示卡集成i810x
一、安装VMware在Linux (Fedora Core 4.0)中;
[root@localhost beinan]# tar zxvf VMware-workstation-e.x.p-15576.tar.gz
[root@localhost beinan]# cd vmware-distrib/
[root@localhost vmware-distrib]#./vmware-install.pl
或
[root@localhost vmware-distrib]# perl vmware-install.pl
[/usr/bin] 注:遇到类似的,请直接回车;
Is this what you want? [yes] yes 注:遇到类似输入Yes的;
注:当 perl vmware-install.pl 到了网络配置的时候,您可以都选择为YES ,也可以根据自己的网络环境来YES或者NO ,最好都是YES吧;这是配置VMware的基础,至于虚拟的系统网络怎么配置都是根据整个网络情况而来了。可以根据我们网络情况对Windows来配置 Windows的网络;
二、添加Windows虚拟系统到VMware中;
1、添加新的虚拟机;点击[New Virtual Machine],我们来添加Windows的虚拟机;
开始创建虚拟机:
2、虚拟机配置添加过程的选择:您可以选择系统默认的,也可以自定义,其实默认配置足够;
3、选择创建虚拟系统的类型:这也是我们本文正要学习的Winodws;
虚拟机名:WinXP,自己写一个就行;如果不指定是放在当前用户的家目录中的.vmware目录中,如果您的/home目录没有那么大,最好指定一个目录。比如我指定在了/mnt/hda10这个目录中,我把一个分区挂载到了/mnt/hda10,体积有15G大小;这还不够,还要确保您要把虚拟机存放的目录是对所用的用户是可写的;只是权限的事,我是如下做的;
[root@localhost beinan]# mkdir /mnt/hda10/winxp
[root@localhost beinan]# chown -R /mnt/hda10/winxp
[root@localhost beinan]# chmod -R 777 /mnt/hda10
所有用户都是可读可写可执行;我上面配置的目录属主没有太大的意义了;因为权限都让我打开了,主要是这样做简单,安全不安全是另一回事了,本来也是实验性的;;)
4、网络配置:如果您是通过路由器或者别的机器的网关上网,就用bridged networking 就行;比如DHCP 获取IP,只在是Windows安装中或者安装完成后,配置为DHCP就行了;如果您是通过网关,并且是非DHCP的,你可以在Windows安装的过程中指定您的机器的IP和网关;
如果您只有一台机器,并且在Fedora Core 4.0 中是通过pppoe或者ppp拔号上网的,首先要让Linux有支持共享上网的能力,这在LinuxSir.Org 网络版中有解决办法;
其实网络比较好配置,和您操作几台机器的网络是相似的,或者说是一样的;把虚拟的操作系统看成是一个独立的机器就OK了。
5、虚拟机磁盘的大小的设定:
Windows XP 有近两G大小,自己根据情况来设定虚拟磁盘大小;我设置为10G;在Winows安装的过程中,我又把这10G分成两个区;
6、Windows虚拟机的各项配置;
点击[Edit Virtual Machine Setting],就可以看到所有的设置,您可以点一点,比如内存的大小的配置要调大一点,要是4的倍数;网卡也能自己来配置;根据自己的情况来吧;
这是输入VMware序列号界面;序列号是可以申请获得的,自己去找找看?不要给我要,我没有 ;:(
问你是否现在注册,写否也行, 以后注册;
三、在虚拟机上安装Windows系统:
1、安装过程:
首先我们要为刚才添加的WinXP开机;然后点出来的画面,如果您是台式机,就按一下DEL键,让CDROM 开机自动运行;我们就能插入光盘来安装Windows了;
下面是几幅图,其它安装过程就免了;
其它过程免;下面我们介绍安装VMware tools ;
2、安装VMware tools :
点击VM菜单,选择安装VMware tools install ; VMware tools 就放到了Windows系统中的光盘中,我们点击鼠标就能简单的安装上了;
后记:祝新手弟兄学有所得;
讨论:禁止叫骂,技术讨论欢迎中~;
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
附:单台机器用非路由ADSL的配置:(如果您用的是路由器或者通过网关上网,不要看以下部份;)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
首先要配置Linux的网卡,把Linux的网卡和虚拟的网卡都设置在 192.168.0.这个网段上,Linux的网卡的IP设置为192.168.1.1 ,不要设置网关;虚拟机的网卡设置为192.168.1.2;掩码都是255.255.255.0;虚拟机要指定网关和DNS;DNS的可以用 202.96.128.143 和202.96.134.133
试试再说吧,我用的是路由器上网,把路由器配成自动拔号,并且能DHCP的就行了;
一、查看是否安装了rp-pppoe
[root@localhost beinan]# rpm -qa rp-pppoe
rp-pppoe-3.5-27
如果没有安装,请找出安装盘,把rp-pppoe安装上;
[root@localhost beinan]#rpm -ivh rp-pppoe*
二、配置rp-pppoe
在终端上以root权限运行
#adsl-setup
[root@LinuxSir02 root]# adsl-setup
Welcome to the ADSL client setup. First, I will run some checks on
your system to make sure the PPPoE client is installed properly...
LOGIN NAME
Enter your Login Name (default root): ADSL提供商给的用户名,写在这里
INTERFACE
Enter the Ethernet interface connected to the ADSL modem
For Solaris, this is likely to be something like /dev/hme0.
For Linux, it will be ethX, where 'X' is a number.
(default eth0): eth0这是ADSL通过第一台机器的第一张网卡eth0提供上网
Do you want the link to come up on demand, or stay up continuously?
If you want it to come up on demand, enter the idle time in seconds
after which the link should be dropped. If you want the link to
stay up permanently, enter 'no' (two letters, lower-case.)
NOTE: Demand-activated links do not interact well with dynamic IP
addresses. You may have some problems with demand-activated links.
Enter the demand value (default no):在这里按一下回车就行了。
DNS
Please enter the IP address of your ISP's primary DNS server.
If your ISP claims that 'the server will provide dynamic DNS addresses',
enter 'server' (all lower-case) here.
If you just press enter, I will assume you know what you are
doing and not modify your DNS setup.
Enter the DNS information here: 202.96.134.133 这是DSN,最好用你本地电信给的
Please enter the IP address of your ISP's secondary DNS server.
If you just press enter, I will assume there is only one DNS server.
Enter the secondary DNS server address here: 202.96.168.68这是第二个DNS,也是电信给的。
PASSWORD
Please enter your Password:在这里把 ADSL提供商给的密码写上
Please re-enter your Password:确认密码
USERCTRL
Please enter 'yes' (two letters, lower-case.) if you want to allow
normal user to start or stop DSL connection (default yes): yes
FIREWALLING
Please choose the firewall rules to use. Note that these rules are
very basic. You are strongly encouraged to use a more sophisticated
firewall setup; however, these will provide basic security. If you
are running any servers on your machine, you must choose 'NONE' and
set up firewalling yourself. Otherwise, the firewall rules will deny
access to all standard servers like Web, e-mail, ftp, etc. If you
are using SSH, the rules will block outgoing SSH connections which
allocate a privileged source port.
The firewall choices are:
0 - NONE: This script will not set any firewall rules. You are responsible
for ensuring the security of your machine. You are STRONGLY
recommended to use some kind of firewall rules.
1 - STANDALONE: Appropriate for a basic stand-alone web-surfing workstation
2 - MASQUERADE: Appropriate for a machine acting as an Internet gateway
for a LAN
Choose a type of firewall (0-2): 2
Start this connection at boot time
Do you want to start this connection at boot time?
Please enter no or yes (default no):yes
** Summary of what you entered **
Ethernet Interface: eth0
User name: ADSL用户名
Activate-on-demand: No
Primary DNS: 202.96.134.133
Secondary DNS: 202.96.168.68
Firewalling: MASQUERADE
User Control: yes
Accept these settings and adjust configuration files (y/n)?y
三、在/etc/rc.d/rc.local中加入如下:
echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -s 192.168.0.0/24 -o ppp0 -j MASQUERADE
阅读(1703) | 评论(0) | 转发(0) |