PXE Server for New Tube (Open)
[
Front page
] [
New
|
Page list
|
Search
|
Recent changes
|
Help
|
Log in
]
Start:
Current status: We have successfully configured PXE serve...
[[PXE Server/Client Configuration:http://flex.phys.tohoku...
----
* Our previous trial [#kbd67efd]
We have changed some configuration, please see the "Statu...
-Using rsync command system files were copied into sys1. ...
-we successfully created diskless environmet for client c...
-We mounted /nfsboot/common directory where common direct...
Current problem: How can we manage main directories nicel...
----
We want to make a diskless computing system so that we ne...
#contents
* Small subnet for testing DHCP [#f0142583]
**What we need [#pe839496]
- A computer with linux operating system to be configured...
- Computer that acts as a client. For a checking purpose ...
- Network hub and cables.
**Checking [#r1faf503]
***Network setting [#j7b294ed]
- Turn on the hub, connect a network cable from Fedora Li...
-Note: From now we will address this Fedora Linux machine...
- Connect again a network cable from the client computer ...
- Open Network configuration on PXE server using root pri...
- Assuming the network card is eth8, select this card the...
-- IP Address: 192.168.2.30
-- Subnet Mask: 255.255.255.0
--After that activate this NIC if it is not activated yet.
- PXE server has a local IP address eth9 by DHCP (to flex)
- On the client computer, set the IP Address by staticall...
-- IP Address: 192.168.2.100
-- Subnet Mask: 255.255.255.0
-- gateway 192.168.2.30 (specified by dhcpd.conf and ipfo...
- We adopt the PXE server which will be used as the OS of...
***SSH check [#tad4148a]
- Open SSH software on client computer, for example, Putt...
ssh username@192.168.2.30
- If username is "nugraha" and hostname of server is "rsa...
nugraha@rsaito-necPC:~$
it means that we can access the server from the client.
* Setting for the PXE server machine [#fea55b57]
** SElinux should be in permissive mode. [#e2317643]
- edit /etc/sysconfig/selinux
SELINUX=permissive
!SELINUXTYP=targeted
** Install DHCP and TFTP Server etc [#s9d399d8]
- Install dhcp, syslinux, tftp-server, nfs-utils, system-...
# yum install dhcp syslinux tftp-server nfs-utils syste...
- Check if the software is nicely installed
# rpm -qa | grep syslinux
syslinux-2.2.2.2.2
-- If we can see name + version, then ok. If not, yum ins...
** DHCP Configuration [#b4fdd07c]
- Edit /etc/dhcpd.conf. The following is a configuration ...
-- 192.168.2.0/255.255.255.0 addressing
-- Dynamic address will be provided between 192.168.2.100...
-- DHCP server (next server) at IP address 192.168.2.30
allow booting;
allow bootp;
ddns-update-style interim;
ignore client-updates;
subnet 192.168.2.0 netmask 255.255.255.0 {
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.2.255;
range dynamic-bootp 192.168.2.200 192.168.2.240;
next-server 192.168.2.30;
}
host tube31 { # hostname
hardware ethernet 00:30:48:d4:a9:7c; # MAC...
fixed-address 192.168.2.31; # correspondin...
filename "/linux-install/pxelinux.0";
host tube32 { # hostname
hardware ethernet 00:30:48:d4:a9:44; # MAC...
fixed-address 192.168.2.32; # correspondin...
filename "/linux-install/pxelinux.0";
} #We can add more hosts
class "pxeclients" {
match if substring(option vendor-class-identifier,...
next-server 192.168.2.30;
filename "/linux-install/pxelinux.0";
}
Warning: Do not use the IP address of PXE-Client within t...
-- Turn on dhcpd
# /sbin/service dhcpd restart
# chkconfig dhcpd on
(the last line is for activating dhcp on booting process)
-- Check if the dhcp server can work.
--- Open a client computer which is connected to server
--- Set the TCP/IP to dynamically set for IP address.
--- Connect by ssh
% putty username@192.168.2.30
---If we can connect, it means DHCP has successfully been...
% ipconfig -a
--- Please keep Mac Address of the client PC, in this cas...
** TFTP Configuration [#nfd5db55]
- Edit /etc/xinetd.d/tftp of the PXE server machine
# default: off
# description: The tftp server serves files using the tr...
# protocol. The tftp protocol is often used to bo...
# workstations, download configuration files to ne...
# and to start the installation process for some o...
service tftp
{
disable = no
socket_type = dgram
protocol = udp
wait = yes
user = root
server = /usr/sbin/in.tftpd
server_args = -s /tftpboot
per_source = 11
cps = 100 2
flags = IPv4
}
- (1) disable = no, and (2) server_args = -s /tftpboot sh...
- Possible problems: (1) tftp does not work, (2) tftp doe...
- tftpd is running under the xinetd. We restart xinetd
# service xinetd restart
** NFS configuration [#r08426e2]
*** Copy system data for booting [#v32daf81]
- We will make file systems /nfsboot
# mkdir /nfsboot/sys1
# mkdir /nfsboot/sys2
- rsync will be used for copying the files.
# rsync -v -a \
--exclude='/proc/*' --exclude='/sys/*' --exclude='/dev/*'\
--exclude='/media/*' --exclude='/tmp/*' --exclude='/mi...
--exclude='/nfsboot/*' / /nfsboot/sys1/root
- Do the same thing for other machine.
- 10GB files (10min) are needed. The file system will be ...
*** Firewall and starting NFS [#u8bca647]
- NFS hosts is PXE server (192.168.2.30).
- Edit /etc/exports
/nfsboot 192.168.2.0/255.255.255.0(rw,no_root_squash,asy...
- Edit /etc/sysconfig/nfs
-- uncomment MOUNTD_PORT
# Port rpc.mountd should listen on.
#MOUNTD_PORT=892
MOUNTD_PORT=892
- Change firewall for NFS, run system-config-firewall
# system-config-firewall
-- add 111 tcp
-- add 111 udp
-- add 892 tcp
-- add 892 udp
--- for 892 port, we set by hand.
- Start nfs
# service nfs restart
# cd /etc/rc5.d/
# mv K20nfs S20nfs
# ./S20nfs restart
Shutting down NFS mountd: ...
Shutting down NFS daemon: ...
Shutting down NFS quotas: ...
Shutting down NFS services: ...
Starting NFS services: ...
Starting NFS quotas: ...
Starting NFS daemon: ...
Starting NFS mountd: ...
# ./S20nfs status
rpc.mountd (pid 12153) is running...
nfsd (pid 12150 12149 12148 12147 12146 12145 12144 1214...
rpc.rquotad (pid 12138) is running...
- 'K' in 'K20nfs' means that file does not run by default...
** Netboot [#nd1b2b49]
- Files directory is made automatically by
# system-config-netboot
- or we can use: GNOME System - Administration - Server S...
-- push Diskless button for the first time
-- then Diskless identifier windows starts
Name: fedora64bit
Description: fedora bla... bla... bla...
-- NFS information:
server 192.168.2.30
directory /nfsboot
-- Select a newer Kernel.
-- Automatically it will generate /tftpboot/linux-install...
--- /tftpboot/linux-install/fedora64bit/initrd.img
--- /tftpboot/linux-install/fedora64bit/vmliuz
-- New windows appears
IP address/subnet: 255.255.255.0 <- we use subnet infor...
operating system: fedora64bit
Other part should be as it is.
-- /nfsboot/snapshot/255.255.255.0/ will be generated aut...
--- FFFFFF00 (255.255.255.0) file is generated as above.
# cd /tftpboot/linux-install/pxelinux.cfg
# mv default default.org
# ln -s FFFFFF00 01-00-21-70-c9-e7-de
--- when default exists, PXE client first try to read this.
--- 00-21-70-c9-e7-de is the MAC address of the PXE clien...
--- Mac address appears PXE client and Pause key can be u...
--- PXE try to read 01-00-21-70-c9-e7-de the file first.
-- An important thing is to put "01-" at the beginning of...
--- If you want to see what kind files the PXE client try...
--- please delete this symbolic link and default then you...
* Set PXE client [#j2d1c71b]
- Start BIOS and select BOOT.
- Select Network boot (no submenu exist).
- Start PC, if we have PAUSE button the session can be st...
* Mount /nfsboot/sys1/opt [#taa17fd7]
# mkdir /mnt/common
# mkdir /nfsboot/common
# mv /nfsboot/sys1/root/opt /nfsboot/common
# mount -t nfs 192.168.2.30:/nfsboot/common /mnt/common
- as opt directory is moved so make a symbolic link with ...
# ln -s /nfsboot/common/opt /nfsboot/sys1/root
# cd /mnt/test
* MAC addresses of PXE Server and Clients [#a12c788a]
- 00:30:48:67:08:e2 (tube21 standalone)
- 00:30:48:d4:27:98 (tube22 client)
- 00:30:48:d4:27:94 (tube23 client)
- 00:30:48:67:07:7e (tube24 client)
- 00:30:48:d4:a9:44 (tube31 client)
- 00:30:48:d4:a9:7c (tube32 client)
- 00:30:48:d4:a9:2c (tube33 client)
- 00:30:48:d4:a9:0a (tube30, PXE Server)
- 00:21:70:c9:e7:de (Dell machine, for testing, English OS)
----
* Status of Regular Works [#r5a1a8a2]
-Date: 2009.6.12 (evening)
-- Finally we have configured tube21 as PXE server. But w...
- Date: 2009.6.12 (morning)
-- Today we have connected tube22-24 as PXE clients. We k...
-- Steps for adding these newtube(s):
--- check MAC address
--- shutdown the computers (tube22-24, tube31-33)
--- configure PXE server: DHCPD, tftp (system-config-netb...
--- restart DHCPD, nfs
--- remove 172.17.4.0 network
--- remove unnecessary harddisks
--- turn on client computers, set the BIOS (PCI configura...
--- restart the computers
--- check ssh
- Date: 2009.6.3
-- Today we run all PXE server/clients computer in comput...
- Date: 2009.5.29
-- Today we have moved root and snapshot directories from...
-- Finally we have deleted both the directories i.e sys1 ...
--We have edited /etc/exportfs file, the content of expor...
---/nfsboot/root(ro, ..,...) "ro" argumnetis used to keep...
---/nfsboot/snapshopt (rw, .., ..) "rw" argument is used ...
-- then we restarted nfs server (enter /etc/rc5.d/ then ....
-- After that we configured /tftpboot/linux-install/pxeli...
- Date: 2009.5.28
--Two new directories i.e. sys1 and sys2 created.
-location: /nfstpboot/sys1 and /nfstpboot/sys2
----
* Problem and Solution [#g4d63e01]
- P: Today we were failed to run ether-wake command on ne...
-- S: We manually turn those on and off. After that ether...
- P: extracting initrd.img
--S: gunzip < initrd.img | cpio -i --make-directories
End:
Current status: We have successfully configured PXE serve...
[[PXE Server/Client Configuration:http://flex.phys.tohoku...
----
* Our previous trial [#kbd67efd]
We have changed some configuration, please see the "Statu...
-Using rsync command system files were copied into sys1. ...
-we successfully created diskless environmet for client c...
-We mounted /nfsboot/common directory where common direct...
Current problem: How can we manage main directories nicel...
----
We want to make a diskless computing system so that we ne...
#contents
* Small subnet for testing DHCP [#f0142583]
**What we need [#pe839496]
- A computer with linux operating system to be configured...
- Computer that acts as a client. For a checking purpose ...
- Network hub and cables.
**Checking [#r1faf503]
***Network setting [#j7b294ed]
- Turn on the hub, connect a network cable from Fedora Li...
-Note: From now we will address this Fedora Linux machine...
- Connect again a network cable from the client computer ...
- Open Network configuration on PXE server using root pri...
- Assuming the network card is eth8, select this card the...
-- IP Address: 192.168.2.30
-- Subnet Mask: 255.255.255.0
--After that activate this NIC if it is not activated yet.
- PXE server has a local IP address eth9 by DHCP (to flex)
- On the client computer, set the IP Address by staticall...
-- IP Address: 192.168.2.100
-- Subnet Mask: 255.255.255.0
-- gateway 192.168.2.30 (specified by dhcpd.conf and ipfo...
- We adopt the PXE server which will be used as the OS of...
***SSH check [#tad4148a]
- Open SSH software on client computer, for example, Putt...
ssh username@192.168.2.30
- If username is "nugraha" and hostname of server is "rsa...
nugraha@rsaito-necPC:~$
it means that we can access the server from the client.
* Setting for the PXE server machine [#fea55b57]
** SElinux should be in permissive mode. [#e2317643]
- edit /etc/sysconfig/selinux
SELINUX=permissive
!SELINUXTYP=targeted
** Install DHCP and TFTP Server etc [#s9d399d8]
- Install dhcp, syslinux, tftp-server, nfs-utils, system-...
# yum install dhcp syslinux tftp-server nfs-utils syste...
- Check if the software is nicely installed
# rpm -qa | grep syslinux
syslinux-2.2.2.2.2
-- If we can see name + version, then ok. If not, yum ins...
** DHCP Configuration [#b4fdd07c]
- Edit /etc/dhcpd.conf. The following is a configuration ...
-- 192.168.2.0/255.255.255.0 addressing
-- Dynamic address will be provided between 192.168.2.100...
-- DHCP server (next server) at IP address 192.168.2.30
allow booting;
allow bootp;
ddns-update-style interim;
ignore client-updates;
subnet 192.168.2.0 netmask 255.255.255.0 {
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.2.255;
range dynamic-bootp 192.168.2.200 192.168.2.240;
next-server 192.168.2.30;
}
host tube31 { # hostname
hardware ethernet 00:30:48:d4:a9:7c; # MAC...
fixed-address 192.168.2.31; # correspondin...
filename "/linux-install/pxelinux.0";
host tube32 { # hostname
hardware ethernet 00:30:48:d4:a9:44; # MAC...
fixed-address 192.168.2.32; # correspondin...
filename "/linux-install/pxelinux.0";
} #We can add more hosts
class "pxeclients" {
match if substring(option vendor-class-identifier,...
next-server 192.168.2.30;
filename "/linux-install/pxelinux.0";
}
Warning: Do not use the IP address of PXE-Client within t...
-- Turn on dhcpd
# /sbin/service dhcpd restart
# chkconfig dhcpd on
(the last line is for activating dhcp on booting process)
-- Check if the dhcp server can work.
--- Open a client computer which is connected to server
--- Set the TCP/IP to dynamically set for IP address.
--- Connect by ssh
% putty username@192.168.2.30
---If we can connect, it means DHCP has successfully been...
% ipconfig -a
--- Please keep Mac Address of the client PC, in this cas...
** TFTP Configuration [#nfd5db55]
- Edit /etc/xinetd.d/tftp of the PXE server machine
# default: off
# description: The tftp server serves files using the tr...
# protocol. The tftp protocol is often used to bo...
# workstations, download configuration files to ne...
# and to start the installation process for some o...
service tftp
{
disable = no
socket_type = dgram
protocol = udp
wait = yes
user = root
server = /usr/sbin/in.tftpd
server_args = -s /tftpboot
per_source = 11
cps = 100 2
flags = IPv4
}
- (1) disable = no, and (2) server_args = -s /tftpboot sh...
- Possible problems: (1) tftp does not work, (2) tftp doe...
- tftpd is running under the xinetd. We restart xinetd
# service xinetd restart
** NFS configuration [#r08426e2]
*** Copy system data for booting [#v32daf81]
- We will make file systems /nfsboot
# mkdir /nfsboot/sys1
# mkdir /nfsboot/sys2
- rsync will be used for copying the files.
# rsync -v -a \
--exclude='/proc/*' --exclude='/sys/*' --exclude='/dev/*'\
--exclude='/media/*' --exclude='/tmp/*' --exclude='/mi...
--exclude='/nfsboot/*' / /nfsboot/sys1/root
- Do the same thing for other machine.
- 10GB files (10min) are needed. The file system will be ...
*** Firewall and starting NFS [#u8bca647]
- NFS hosts is PXE server (192.168.2.30).
- Edit /etc/exports
/nfsboot 192.168.2.0/255.255.255.0(rw,no_root_squash,asy...
- Edit /etc/sysconfig/nfs
-- uncomment MOUNTD_PORT
# Port rpc.mountd should listen on.
#MOUNTD_PORT=892
MOUNTD_PORT=892
- Change firewall for NFS, run system-config-firewall
# system-config-firewall
-- add 111 tcp
-- add 111 udp
-- add 892 tcp
-- add 892 udp
--- for 892 port, we set by hand.
- Start nfs
# service nfs restart
# cd /etc/rc5.d/
# mv K20nfs S20nfs
# ./S20nfs restart
Shutting down NFS mountd: ...
Shutting down NFS daemon: ...
Shutting down NFS quotas: ...
Shutting down NFS services: ...
Starting NFS services: ...
Starting NFS quotas: ...
Starting NFS daemon: ...
Starting NFS mountd: ...
# ./S20nfs status
rpc.mountd (pid 12153) is running...
nfsd (pid 12150 12149 12148 12147 12146 12145 12144 1214...
rpc.rquotad (pid 12138) is running...
- 'K' in 'K20nfs' means that file does not run by default...
** Netboot [#nd1b2b49]
- Files directory is made automatically by
# system-config-netboot
- or we can use: GNOME System - Administration - Server S...
-- push Diskless button for the first time
-- then Diskless identifier windows starts
Name: fedora64bit
Description: fedora bla... bla... bla...
-- NFS information:
server 192.168.2.30
directory /nfsboot
-- Select a newer Kernel.
-- Automatically it will generate /tftpboot/linux-install...
--- /tftpboot/linux-install/fedora64bit/initrd.img
--- /tftpboot/linux-install/fedora64bit/vmliuz
-- New windows appears
IP address/subnet: 255.255.255.0 <- we use subnet infor...
operating system: fedora64bit
Other part should be as it is.
-- /nfsboot/snapshot/255.255.255.0/ will be generated aut...
--- FFFFFF00 (255.255.255.0) file is generated as above.
# cd /tftpboot/linux-install/pxelinux.cfg
# mv default default.org
# ln -s FFFFFF00 01-00-21-70-c9-e7-de
--- when default exists, PXE client first try to read this.
--- 00-21-70-c9-e7-de is the MAC address of the PXE clien...
--- Mac address appears PXE client and Pause key can be u...
--- PXE try to read 01-00-21-70-c9-e7-de the file first.
-- An important thing is to put "01-" at the beginning of...
--- If you want to see what kind files the PXE client try...
--- please delete this symbolic link and default then you...
* Set PXE client [#j2d1c71b]
- Start BIOS and select BOOT.
- Select Network boot (no submenu exist).
- Start PC, if we have PAUSE button the session can be st...
* Mount /nfsboot/sys1/opt [#taa17fd7]
# mkdir /mnt/common
# mkdir /nfsboot/common
# mv /nfsboot/sys1/root/opt /nfsboot/common
# mount -t nfs 192.168.2.30:/nfsboot/common /mnt/common
- as opt directory is moved so make a symbolic link with ...
# ln -s /nfsboot/common/opt /nfsboot/sys1/root
# cd /mnt/test
* MAC addresses of PXE Server and Clients [#a12c788a]
- 00:30:48:67:08:e2 (tube21 standalone)
- 00:30:48:d4:27:98 (tube22 client)
- 00:30:48:d4:27:94 (tube23 client)
- 00:30:48:67:07:7e (tube24 client)
- 00:30:48:d4:a9:44 (tube31 client)
- 00:30:48:d4:a9:7c (tube32 client)
- 00:30:48:d4:a9:2c (tube33 client)
- 00:30:48:d4:a9:0a (tube30, PXE Server)
- 00:21:70:c9:e7:de (Dell machine, for testing, English OS)
----
* Status of Regular Works [#r5a1a8a2]
-Date: 2009.6.12 (evening)
-- Finally we have configured tube21 as PXE server. But w...
- Date: 2009.6.12 (morning)
-- Today we have connected tube22-24 as PXE clients. We k...
-- Steps for adding these newtube(s):
--- check MAC address
--- shutdown the computers (tube22-24, tube31-33)
--- configure PXE server: DHCPD, tftp (system-config-netb...
--- restart DHCPD, nfs
--- remove 172.17.4.0 network
--- remove unnecessary harddisks
--- turn on client computers, set the BIOS (PCI configura...
--- restart the computers
--- check ssh
- Date: 2009.6.3
-- Today we run all PXE server/clients computer in comput...
- Date: 2009.5.29
-- Today we have moved root and snapshot directories from...
-- Finally we have deleted both the directories i.e sys1 ...
--We have edited /etc/exportfs file, the content of expor...
---/nfsboot/root(ro, ..,...) "ro" argumnetis used to keep...
---/nfsboot/snapshopt (rw, .., ..) "rw" argument is used ...
-- then we restarted nfs server (enter /etc/rc5.d/ then ....
-- After that we configured /tftpboot/linux-install/pxeli...
- Date: 2009.5.28
--Two new directories i.e. sys1 and sys2 created.
-location: /nfstpboot/sys1 and /nfstpboot/sys2
----
* Problem and Solution [#g4d63e01]
- P: Today we were failed to run ether-wake command on ne...
-- S: We manually turn those on and off. After that ether...
- P: extracting initrd.img
--S: gunzip < initrd.img | cpio -i --make-directories
Page: