using linux to install windows xp with network booting


Using Linux to install Windows XP with
Network booting
1E Technical Whitepaper
OSD and Linux
Abstract
This paper discusses how to network-install Windows XP using a Linux server.
Using Linux to install Windows XP with Network booting
Copyright © 1E LTD 2005
All rights reserved. No part of this document shall be reproduced, stored in a
retrieval system, or transmitted by any means, electronic, mechanical,
photocopying, recording, or otherwise, without permission from 1E LTD. No
patent liability is assumed with respect to the use of the information contained
herein. Although every precaution has been taken in the preparation of this
document, 1E and the authors assume no responsibility for errors or
omissions. Neither is liability assumed for damages resulting from the
information contained herein.
Trademarks
1E LTD name and device is a registered trademark of 1E LTD in the UK,
applied for in the US, EC and Australia.
Microsoft, Windows NT, Windows 2000, Windows XP are all trademarks of
Microsoft Corporation in the United States and other countries.
Contents Page i
Introduction 1
Contents
Architecture 1
Prerequisites 1
Configuring Linux 2
Installing Linux Packages 2
RIS-Linux 2
Configuring DHCP 2
Configuring TFTP 3
The Boot Files 3
Configuring Samba 4
Copying the WinPE Files 4
Copying the Package Files 4
Starting the BINL Server 4
Network Booting the Client PC 6
Selecting the Operating System Package 6
Summary 8
Acknowledgements 8
Information 9
Pricing and packaging information 9
More information 9
Using Linux to install Windows XP with Network booting
Introduction Page 1
This paper shows you how you can use a Linux based infrastructure to deploy
Introduction
Windows XP images to machines on your network. This section gives a brief
overview of the architecture that will be used to achieve the deployment and a
list of the prerequisites for following the procedure.
Architecture
To install Windows XP over the network requires the following components:
" A DHCP server that supports PXE options.
" A Trivial File Transfer Protocol (TFTP) server.
" A Boot Information Negotiation Layer (BINL) server.
" A CIFS/SMB server.
Prerequisites
" A Windows XP CD. I used Service Pack 2.
" A WinPE boot CD created using the SMS Operation System Deployment
feature pack (OSD).
" You will also need two computers: one server and one client.
Using Linux to install Windows XP with Network booting
Configuring Linux Page 2
Installing Linux Packages
Configuring Linux
In this paper, we describe using a Debian GNU/Linux box as the server. Other
variants of Linux or Unix will work as well, but you should bear in mind that
installation details will vary.
We start by taking one of our lab machines, LAB2-17, and installing a copy of
Debian on it. We will install the  sarge (testing) distribution of Debian.
First we need to install some extra packages:
# apt-get install tftpd-hpa
# apt-get install dhcp3-server
# apt-get install samba
# apt-get install cabextract
# apt-get install syslinux
# apt-get install wget
We might also want some other packages for debugging:
# apt-get install tftp-hpa
# apt-get install ethereal
# apt-get install smbclient
RIS-Linux
In order to make this work properly, you will also need the files from
http://oss.netfarm.it/guides/ris-linux.tar.gz
Most importantly, this includes a BINL server, implemented in Python.
# cd
# wget http://oss.netfarm.it/guides/ris-linux.tar.gz
# tar xvfz ris-linux.tar.gz
# cp  a ris-linux/* /usr/local/bin
This leaves the scripts in /usr/local/bin, which should be in your $PATH variable.
Configuring DHCP
On Debian, the DHCP server configuration is held in /etc/dhcp3/dhcpd.conf. Our
example looks like this:
subnet 192.168.0.0 netmask 255.255.255.0 {
range 192.168.0.100 192.168.0.200;
option broadcast-address 192.168.0.255;
option routers 192.168.0.17;
option domain-name-servers 192.168.0.17;
option domain-name "lab2.local";
option subnet-mask 255.255.255.0;
allow bootp;
host lab2-18 {
hardware ethernet 00:01:02:03:04:05;
fixed-address 192.168.0.18;
server-name  192.168.0.17 ;
next-server 192.168.0.17;
filename  startrom.0 ;
}
}
We have one server, called lab2-17, IP address 192.168.0.17; and one client,
called lab2-18, IP address 192.168.0.18.
Items of note are the  allow bootp line, the  server-name and  next-server
entries, and the  filename entry. The server-name and filename entries tell
the PXE client where to find the TFTP server, and which file to request from it.
Using Linux to install Windows XP with Network booting
Configuring Linux Page 3
Configuring TFTP
For a TFTP server, we will be using the tftpd-hpa package, which has some
useful extensions for booting PXE clients. Configuration is held in
/etc/default/tftpd-hpa:
RUN_DAEMON="yes"
OPTIONS="-l -s /tftpboot -m /etc/tftpd-hpa.rules -vvv"
The first line is necessary because we will run TFTPD as a daemon, rather than
from inetd.
The second line tells it to run in listen mode, rooted at /tftpboot, using the given
rules file, and it should be verbose in logging.
The rules file, at /etc/tftpd-hpa.rules, looks like this:
rg \\ /
This allows it to handle Windows clients, which use backslash as a path
separator, by replacing this with a forward slash.
The Boot Files
We need some files from a stock Windows XP distribution. To get hold of
these, it is simplest to mount the Windows XP CD.
# mkdir /tftpboot
# cd /tftpboot
# mount /media/cdrom
# cabextract /media/cdrom/I386/STARTROM.N1_
# ln  sf startrom.n12 startrom.0
This leaves us with a startrom.0 symlink pointing at the startrom.n12 file that we
just extracted from the XP CD.
We need the NTLDR and NTDETECT.COM files as well:
# cp /media/cdrom/I386/SETUPLDR.BIN /tftpboot/ntldr
# fixloader.py /tftpboot/ntldr
# cp /media/cdrom/I386/NTDETECT.COM /tftpboot/ntdetect.com
The fixloader.py script strips off the header from NTLDR, leaving a normal EXE
file.
Note: the destination files should be in lower-case.
We are done with the Windows XP CD now:
# umount /media/cdrom
At this point, you should be able to network-boot the workstation, but it will
fail with a  Cannot find WINNT.SIF error. Create /tftpboot/winnt.sif, containing
the following:
[SetupData]
OsLoadOptions =  /fastdetect /minint
SetupSourceDevice =
 \Device\LanmanRedirector\server\share\path
[UserData]
ComputerName = WindowsPE
In the SetupSourceDevice line, be sure to specify the server name, share name
and path name. For example:
SetupSourceDevice =  \Device\LanmanRedirector\lab2-
17\RemInst\winpe
Using Linux to install Windows XP with Network booting
Configuring Linux Page 4
Configuring Samba
The Samba configuration file is in /etc/samba/smb.conf. It will need to look
something like this:
[global]
oplocks = false
level2 oplocks = false
encrypt passwords = true
passdb backend = tdbsam guest
obey pam restrictions = yes
guest account = nobody
invalid users = root
socket options = TCP_NODELAY
null passwords = true
[RemInst]
path = /tftpboot
browsable = true
read only = Yes
guest ok = Yes
[images]
path = /images
browsable = true
read only = Yes
guest ok = Yes
Note: The  oplocks and  level2 oplocks lines fix a problem that often
occurs with Samba in Debian/sarge and Windows XP.
You will need the  null passwords line.
The configuration file then sets up two shares, RemInst and images.
We also need to add a user account, used for the images share:
# adduser osduser
# smbpasswd  a osduser
You will be prompted for a password on both occasions.
Copying the WinPE Files
Mount the Windows PE CD that you created with OSD, and copy the files from
it:
# mkdir /tftpboot/winpe
# cp  a /media/cdrom/* /tftpboot/winpe
Copying the Package Files
When you created the package using OSD, you will have ended up with a
package folder on your distribution point. Copy this to the Linux box. In this
example, it is placed in /images/LB200043.
Starting the BINL Server
This uses the BINL server found in the ris-linux.tar.gz file. First you need to fix
the case of some of the files in the OSD image. Edit the /usr/local/bin/fixup-
repository.sh and point the REP variable at /tftpboot/winpe. Then run it.
# fixup-repository.sh
Using Linux to install Windows XP with Network booting
Configuring Linux Page 5
Then we need to generate a driver database. This is equivalent to the .PNF
files that RIS uses. Unfortunately, as it stands, the script does not correctly
deal with newer, IA64-enabled drivers. We need to make a couple of changes.
There are two lines in the file that look like this:
if check[-1].startswith( nt ):
They need to read like this.
if check[-1].startswith( ntx86 ):
Then run it:
# cd /usr/local/bin
# ./infparser.py /tftpboot/winpe/i386/inf
With the OSD image we used in the example, the result of running the
command was:  Compiled 733 drivers .
Now you can run the BINL server:
# /usr/local/bin/binlsrv.py
Using Linux to install Windows XP with Network booting
Network Booting the Client PC Page 6
After the preceding steps, If you now turn on the client PC and select network
Network Booting the
booting, you should see (after a short while) the OSD installation wizard:
Client PC
Selecting the Operating System Package
If you click Next, you will be given a list of available packages. These are
taken from the RIPINFO.INI file. Our example does not have an SMS
management point, so we need to choose the  from another location option:
Using Linux to install Windows XP with Network booting
Network Booting the Client PC Page 7
At this point, we need to point the wizard at our images share:
And, once we have selected a configuration from the drop-down list, it will do
a bare metal installation of the chosen operating system.
Using Linux to install Windows XP with Network booting
Summary Page 8
This paper showed how you can deploy OSD-built XP images using a common
Summary
variety of Linux, combining the technologies of DHCP, PXE, TFTP, BINL and
SMB to provide a means of deploying Windows OS without requiring a
Windows infrastructure.
Acknowledgements
This paper would have been impossible to write without the information at
http://oss.netfarm.it/guides/pxe.php
Using Linux to install Windows XP with Network booting
Information Page 9
Pricing and packaging information
Information
For pricing and availability information on 1E software contact the 1E product
team:
Telephone +44 (0)208 326 3880
US Toll Free 1-800 516 6938
mailto:info@1e.com
More information
To download evaluation versions of 1E software or product documentation,
visit the 1E web site: http://www.1e.com/SoftwareProducts/Index.aspx
Telephone +44 (0)208 326 3880
Fax +44 (0)208 840 9578
US Toll Free 1-800 516 6938
http://www.1e.com
mailto:info@1e.com
Using Linux to install Windows XP with Network booting


Wyszukiwarka

Podobne podstrony:
Zmiana klucza instalacyjnego w Windows XP
Instalacja Windows XP i Vista(FORMATOWANIE),tworzenie kopii zapasowej
How to Crack Windows XP Service pack 1 (2)
How to Crack Windows XP Service pack 1 XP KeYS (10 20 2003, 16 46)
HP Pavilion dv6000 series i instalacja windows XP
How to optimize Windows XP for the best performance
Instalacja Windows XP na dyskach SATA
Instalacja Windows XP z USB, pendrive a lub karty pamięci flash
How to Install Windows`XP on SATA
How to Crack Windows XP Service pack 1 How to use XPkeygen
Czysta instalacja Windows XP(1)
How to Install And Run Windows XP From USB drive
linux live flash usb z wykorzystaniem windowsa xp i progamu uniwersal usb installer
1000 Keys to Windows XP PRO

więcej podobnych podstron