■
CD,FDの無いノートPC(ThinkPad X60s)にubuntuを入れようと思ったけどムリポそうなのでFC6のネットワークインストールを試みる。
syslinuxでpxeという方法で行う
参考サイト
http://syslinux.zytor.com/index.php
ブートサーバはvmwareにインストールしてあるFedoraCore
ここにtftpdとdhcpdを設定する。
※VMWareはUse Bridged networkingモード
http://www.ukkii.com/vmware/VMnet_Tips/VMnet_Tips.html
1. インストール用のisoイメージを用意
2. tftpサーバの設定
インストールしていなかったので以下のコマンドでインストール
# yum install tftp tftp-server Dependencies Resolved ============================================================================= Package Arch Version Repository Size ============================================================================= Installing: tftp i386 0.40-6 base 20 k tftp-server i386 0.40-6 base 26 k Installing for dependencies: xinetd i386 2:2.3.13-6 base 125 k Transaction Summary ============================================================================= Install 3 Package(s) Update 0 Package(s) Remove 0 Package(s) Total download size: 170 k Is this ok [y/N]: y Downloading Packages: (1/3): xinetd-2.3.13-6.i3 100% |=========================| 125 kB 00:01 (2/3): tftp-0.40-6.i386.r 100% |=========================| 20 kB 00:00 (3/3): tftp-server-0.40-6 100% |=========================| 26 kB 00:00 warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID 4f2a6fd2 public key not available for xinetd-2.3.13-6.i386.rpm Retrieving GPG key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora Importing GPG key 0x4F2A6FD2 "Fedora Project" Is this ok [y/N]: y Key imported successfully Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing: xinetd ######################### [1/3] Installing: tftp ######################### [2/3] Installing: tftp-server ######################### [3/3] Installed: tftp.i386 0:0.40-6 tftp-server.i386 0:0.40-6 Dependency Installed: xinetd.i386 2:2.3.13-6 Complete!
次に/etc/xinetd.d/tftpファイルの以下の箇所を編集
service tftp { socket_type = dgram protocol = udp wait = yes user = root server = /usr/sbin/in.tftpd server_args = -s /tftpboot disable = no ←yesをnoに変更 per_source = 11 cps = 100 2 flags = IPv4 }
修正したらxinetdの再起動
# /sbin/service xinetd restart
VMWareディスク領域確保(足りなかったので。。)
vmware上のディスク領域が足りなかったので以下のように
ディスクを追加
# mkfs -t ext3 -c /dev/sdb ※sdbを新規に追加 # mkdir /mnt/disk # mount -t ext3 /dev/sdb /mnt/disk
ブートイメージをtftpbootのpxelinux設定位置にコピー
# mkdir /tftpboot/linux-install # cp /mnt/iso/images/pxeboot/vmlinuz /tftpboot/linux-install # cp /mnt/iso/images/pxeboot/initrd.img /tftpboot/linux-install
pxelinuxの設定
/tftpboot/linux-install/pxelinux.cfg/default
ファイルを以下のように設定
default fc6 label fc6 kernel vmlinuz append load initrd=initrd.img devfs=nomount
3. dhcp設定
/etc/dhcpd.confを以下のように設定
allow booting; allow bootp; option domain-name "hoge.com"; option domain-name-servers 192.168.81.128; option subnet-mask 255.255.255.0; subnet 192.168.81.0 netmask 255.255.255.0 { range 192.168.81.1 192.168.81.100; option broadcast-address 192.168.81.255; option routers 192.168.81.128; next-server 192.168.81.128; filename "/linux-install/pxelinux.0"; }
dhcpd起動 (iscからインストールした場合)
# /usr/sbin/dhcpd & ※/sbin/service dhcpd startでは起動しない
4. isoファイル用にapache設定
Alias /fedora "/mnt/fciso"Options MultiViews Indexes FollowSymLinks Order deny,allow Allow from all
5. SELinux設定の解除
# setenforce 0
6. 以上の設定をしたらx60sのブートプライオリティをネットワーク最優先にし再起動。
以降は支持に従ってインストール
※参考URL
http://www.atmarkit.co.jp/flinux/rensai/linuxtips/710pxeserver.html