Apr 11, 2005
onlsbc1, Scientific Linux CERN3 (SLC3) のインストール
--- SLC3 インストール #2
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
(http://www-online.kek.jp/~inoue/para-CAMAC/
Work/SBC-Linux56.html)
高エネルギー加速器研究機構
素粒子原子核研究所
物理、オンライングループ
井上 栄二
目的
onlsbc1 にローカルにつないである 2.5" IDE ハードディスク上に、
Scientific Linux CERN 3 (SLC3) をインストールする。
項目
(1). 2.5" IDEハードディスクのパーティショニング
(1-1). /dev/hda3 にファイルシステムを作成
(2). SLC 3 のインストール
(3). インストール後の初期設定
(3-1). インストールしたパッケージ
--------------------------------------------------------------------
(1). 2.5" IDEハードディスクのパーティショニング
現在の onlsbc1 マシンのハードディスクのパーティションの状況を確認する。
onlsbc1:/home/inoue# cat /etc/issue
Debian GNU/Linux 3.1 \n \l
onlsbc1:/home/inoue#
onlsbc1:/home/inoue# fdisk -l /dev/hda /dev/hdc /dev/sda
Disk /dev/hda: 100.0 GB, 100030242816 bytes
255 heads, 63 sectors/track, 12161 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 382 3068383+ 83 Linux
/dev/hda2 383 1599 9775552+ 83 Linux
Disk /dev/hdc: 512 MB, 512483328 bytes
16 heads, 63 sectors/track, 993 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Device Boot Start End Blocks Id System
/dev/hdc1 * 1 993 500440+ 83 Linux
Disk /dev/sda: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 1 2433 19543041 83 Linux
/dev/sda2 2434 4866 19543072+ 83 Linux
/dev/sda3 4867 7299 19543072+ 83 Linux
/dev/sda4 7300 30401 185566815 5 Extended
/dev/sda5 7300 9732 19543041 83 Linux
/dev/sda6 9733 12165 19543041 83 Linux
/dev/sda7 12166 14598 19543041 83 Linux
/dev/sda8 14599 17031 19543041 83 Linux
/dev/sda9 17032 19464 19543041 83 Linux
/dev/sda10 19465 21897 19543041 83 Linux
/dev/sda11 21898 24330 19543041 83 Linux
/dev/sda12 24331 25547 9775521 83 Linux
/dev/sda13 25548 26764 9775521 83 Linux
/dev/sda14 26765 27981 9775521 83 Linux
/dev/sda15 27982 29198 9775521 83 Linux
/dev/sda16 29199 30401 9663066 83 Linux
onlsbc1:/home/inoue#
/dev/hda に新しくパーティションを作る。
onlsbc1:/home/inoue# fdisk /dev/hda
The number of cylinders for this disk is set to 12161.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): m
Command action
a toggle a bootable flag
b edit bsd disklabel
c toggle the dos compatibility flag
d delete a partition
l list known partition types
m print this menu
n add a new partition
o create a new empty DOS partition table
p print the partition table
q quit without saving changes
s create a new empty Sun disklabel
t change a partition's system id
u change display/entry units
v verify the partition table
w write table to disk and exit
x extra functionality (experts only)
Command (m for help): p
Disk /dev/hda: 100.0 GB, 100030242816 bytes
255 heads, 63 sectors/track, 12161 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 382 3068383+ 83 Linux
/dev/hda2 383 1599 9775552+ 83 Linux
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 3
First cylinder (1600-12161, default 1600):
Using default value 1600
Last cylinder or +size or +sizeM or +sizeK (1600-12161, default 12161): +3000M
Command (m for help): p
Disk /dev/hda: 100.0 GB, 100030242816 bytes
255 heads, 63 sectors/track, 12161 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 382 3068383+ 83 Linux
/dev/hda2 383 1599 9775552+ 83 Linux
/dev/hda3 1600 1965 2939895 83 Linux
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: Re-reading the partition table failed with error 16: デバイスもしくはリ
ソースがビジー状態です.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.
onlsbc1:/home/inoue#
onlsbc1 のマシンのディスクパーティションは以下のように使用されている。
デバイス 内訳
/dev/hda1 Linux用、Fedora Core 3、/
/dev/hda2 Linux用、Debian GNU/Linux 3.1 (Sarge)、/
/dev/hda3 空、<--- ここにScientific Linux CERN 3 をインストールする。
/dev/hdc1 Linux用、Debian GNU/Linux 3.0、/
/dev/sda1 空
/dev/sda2 空
/dev/sda3 空
/dev/sda4 ここから拡張領域
/dev/sda5 + 空
/dev/sda6 + 空
/dev/sda7 + 空
/dev/sda8 + 空
/dev/sda9 + 空
/dev/sda10 + 空
/dev/sda11 + 空
/dev/sda12 + 空
/dev/sda13 + 空
/dev/sda14 + 空
/dev/sda15 + 空
/dev/sda16 + 空
Scientfic Linux CERN 3 システムはディスクスペース /dev/hda3 の 3GB領域
にインストールすることにしよう。
(1-1). /dev/hda3 にファイルシステムを作成
/devhda3 にScientfic Linux CERN 3 システム用のインストールを配置したいの
で、ファイルシステムを作成する。
onlsbc1:/home/inoue# mke2fs -j /dev/hda3
mke2fs 1.35 (28-Feb-2004)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
368000 inodes, 734973 blocks
36748 blocks (5.00%) reserved for the super user
First data block=0
23 block groups
32768 blocks per group, 32768 fragments per group
16000 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912
Writing inode tables: done
Creating journal (8192 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 34 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
onlsbc1:/home/inoue#
nlsbc1:/home/inoue# mount -t ext3 /dev/hda3 /mnt
onlsbc1:/home/inoue#
onlsbc1:/home/inoue# df -k
Filesystem 1K-ブロック 使用 使用可 使用% マウント位置
/dev/hda2 9621880 1432928 7700176 16% /
tmpfs 152832 0 152832 0% /dev/shm
/dev/hda3 2893660 32828 2713840 2% /mnt
onlsbc1:/home/inoue#
(2). SLC 3 のインストール
Scientific Linux CERN 3 (SLC 3) installer を起動する。
ここでインストーラは起動する。
注:
使用言語の問い合わせは無かった。
Keyboard Type
What type of keyboard do you have ?
<=== "jp106" を選択し "ok" を選択して enter を押す。
Installation Method
What type of media contains the packages to be installed ?
<=== "HTTP" を選択し "ok" を選択して enter を押す。
Configure TCP/IP
Please enter the IP configuration for this machine. Each item should be
entered as an IP address in dotted-decimal notation ( for example,
1.2.3.4).
<=== 以下の情報をセットし "ok" を選択して enter を押す。
IP address: 130.87.***.*
Netmask: 255.255.***.*
Default gateway (IP): 130.87.***.*
Primary nameserver: 130.87.***.*
HTTP Setup
Please enter the following information:
o the name or IP number of your server
o the directory on that server containing Scientific Linux CERN for
your architecture
<=== 以下の情報をセットし "ok" を選択して enter を押す。
Web site name: linuxsoft.cern.ch
SL directory: /cern/slc304/i386/
Scientific Linux CERN
Welcome to Scientific Linux CERN !
<=== "ok" を選択して enter を押す。
Mouse Selection
Which model mouse is attached to this computer ?
<=== 以下の情報をセットし "ok" を選択して enter を押す。
Logitech - MouseMan Wheel (USB)
[*] Emulate 3 Buttons ?
Installation Type
What type of system would you like to install ?
<=== "Server" を選択し "ok" を選択して enter を押す。
Disk Partitioning Setup
Automatic Partitioning sets partitions based on the selected
installation type. You also can customize the partitions once they have
been created.
The manual disk partitioning tool, Disk Durid, allows you to create
partitions in an interactive environment. You can set the file system
types, mount points, partition size, and more.
<=== "Disk Druid" を選択して Enter を押す。
Partitioning
<=== "Device /dev/hda3" を選択し "Edit" を選択して Enter を押す。
Add Partition
<=== "ファイルシステムオプション" を選択して Enter を押す。
File System Options
Please choose how you would like to prepare the file system on this
partition.
<=== "Format as ext3" を選択し "OK" を選択して
Enter を押す。
<=== "マウントポイント: /" を選択し "OK" を選択して Enter を押す。
参考: この時点で以下のように設定したことになる。
Mount Point: /
Type: ext3
Device: /dev/hda3
Size: 964 MB
<=== "OK" を選択して Enter を押す。
Format Warning
The following warning exist with your requested partition scheme.
You have not specified a swap partition. Although not strictly required
in all cases, it will significantly improve performance for most
installations.
Would you like to continue with your requested partitioning scheme?
<=== "Yes" を選択して Enter を押す。
Format Warning
The following pre-existing partitions have been selected to be formated,
destroying all data.
Select 'Yes' to continue and format these partitions, or 'No' to go back
and change these settings.
/dev/hda3 ext3 /
<=== "Yes" を選択して Enter を押す。
Boot Loader Configuration
Which boot loader would you like to use ?
<=== "Use GRUB Boot Loader" を選択し、"OK"を選択して Enter を押す。
Boot Loader Configuration
A few system will need to pass special options to the kernel at boot
time for the system to function properly. If you need to pass boot
options to the kernel, enter them now. If you don't need any or aren't
sure, leave this blank.
[*] Force use of LBA32 (not normally required)
<=== ブランクのままにして "OK" を選択して Enter を押す。
Warning
Forcing the use of LBA32 for your bootloader when not supported by the
BIOS can cause your machine to be unable to boot. We highly recommended
you create a boot disk asked later in install process.
Would you like to continue and force LBA32 mode ?
<=== "Yes" を選択して Enter を押す。
A boot loader password prevents users from passing arbitrary options to
the kernel. For highest security, we recommended setting a password, but
this is not nesessary for more casual users.
<=== GRUBパスワードを使用しないにして "OK" を選択して Enter を押す。
The boot manager Red Hat uses can boot other operating systems as well.
You need to tell me what partitions you would like to be able to boot
and what label you want to use for each of them.
<=== "Scientific Linux CERN /dev/hda3" を指定し "OK" を選択して Enter を
押す。
Where do you want to install the boot loader ?
<=== "/dev/hda3 First sector of boot partition" を指定し "OK" を選択して
Enter を押す。
Network Configuration for eth0
<=== 以下の設定をし、"OK" を選択し Enter を押す。
Network Device: eth0
[*] Activate on boot
IP Address 130.87.***.*
Netmask 255.255.***.*
Miscellaneous Network Settings
<=== 以下の設定をし、"OK" を選択し Enter を押す。
Gateway: 130.87.***.*
Primary DNS: 130.87.***.*
Secondary DNS: 130.87.***.*
Tertiary DNS: 130.87.***.*
Hostname Configuration
If your system is part of a larger network where hostnames are assigned
by DHCP, select automatically via DHCP. Otherwisw, select manually and
enter in a hostname for your system. If you do not, your system will be
known as 'localhost.'
<=== "(*) manually onlsbc1.kek.jp" を設定をし、"OK" を選択し Enter を押す。
Firewall
A firewall can help prevent unauthorized access to your computer from
the outside world. Would you like to enable a firewall ?
<=== "(*) enable firewall" を選択し、"OK" を選択し Enter を押す。
Language Support
Choose additional languages that you would like to use on this system:
<=== 以下のように設定し、"OK" を選択し Enter を押す。
[*] English (USA)
[*] Japanese
Default Language
Choose the default language for this system:
<=== "Japanese"を選択して "OK" を選択して Enter を押す。
Time Zone Selection
What time zone are you located in ?
<=== "Asia/Tokyo"を選択して "OK" を選択して Enter を押す。
Root Password
Pick a root password. You must type it twice to ensure you know what it
is and didn't make a mistake in typing. Remember that the root password
is a critical part of system security !
Password: ********
Password (confirm): ********
ここでパッケージ情報の読み込みが始まる。
Package Group Selection
Total install size: 793M
<=== 以下パッケージを選択して "OK" を選択して Enter を押す。
[*] Web Server
Installation to begin
A complete log of your installation will be in /root/install.log after
rebooting your system. You may want to keep this file for later
reference.
<=== "OK" を選択して Enter を押す。
インストールが開始する。
Complete
Congratulations, your Scientific Linux CERN installation is complete.
Remove any installation media (diskettes or CD-ROMs) used during the
installation process and press (Enter) to reboot your system.
For information on Errata (updates and bug fixes), and on automatic
system updates visit:
http://cern.ch/linux/updates/
For infomation on using and configuring the system, visit:
http://cern.ch/linux/scientific/docs/
For support information, visit:
http://cern.ch/linux/support/
<=== "OK" を選択して Enter を押す。
インストールは正常に終了した。
注.
Scientific Linux CERN のインストーラは、起動用フロッピーディスク
作成を行わないので、必要ならば後で自分で作成すること。
"OK" を押すとインストーラは再起動する。
Scientific Linux CERN のシステムが立ち上がった。 root のアカウントでログ
インする。 ok. 正常にログインできた。
(3). インストール後の初期設定
省略。
(3-1). インストールしたパッケージ
onlsbc1 のマシンにインストールしたパッケージのリスト。
[root@onlsbc1 inoue]# yum list installed > onlsbc1-yum-list-Apr112005.html
[root@onlsbc1 inoue]#
[root@onlsbc1 inoue]# ls -l
合計 280
-rw-r--r-- 1 root root 28216 4月 11 09:41 onlsbc1-yum-list-Apr112
005.html
-rw-r--r-- 1 root root 105011 4月 11 09:30 onlsbc1-yum-list-Apr112
005.html-bak
-rw-r--r-- 1 root root 104748 4月 11 09:39 out
-rw-r--r-- 1 root root 180 4月 8 17:05 out1
-rw-r--r-- 1 root root 28216 4月 11 09:38 out2
-rw-rw-r-- 1 inoue inoue 16 4月 11 08:53 t1
[root@onlsbc1 inoue]#
[root@onlsbc1 inoue]# which javac
/usr/bin/javac
[root@onlsbc1 inoue]#
[root@onlsbc1 inoue]# ls -l /usr/src
合計 0
[root@onlsbc1 inoue]#
[root@onlsbc1 inoue]# df -k
Filesystem 1K-ブロック 使用 使用可 使用% マウント位置
/dev/hda3 2893660 811736 1934932 30% /
none 150856 0 150856 0% /dev/shm
[root@onlsbc1 inoue]#
Java はディフォルトでインストールされている。 カーネルソースはインス
トールされていない。 この状態で約812MBを使用している。 1GBのコンパクト
フラッシュに、カーネルソースまで含めてインストールすることはできそうに
ない。 カーネルソースは NFSマウントして利用するかな。
参考:
onlpc03 にインストールした Scientific Linux CERN のカーネルソースの
サイズは 約220MBである。
注:
後日、よく調べたらJava はディフォルトでインストールされていないこと
がわかった。 /usr/bin/javac は Java の実体ではないので、ユーザが
インストールする必要がある。
[root@onlpc03 mnt]# cd usr/src
[root@onlpc03 src]# ls -l
合計 16
drwxr-xr-x 3 root root 4096 3月 15 19:00 debug
lrwxr-xr-x 1 root root 27 3月 15 17:55 linux-2.4 -> linux-2.4.21-27.0.2.EL.
cern
drwxr-xr-x 18 root root 4096 3月 15 17:55 linux-2.4.21-27.0.2.EL.cern
drwxr-xr-x 3 root root 4096 3月 15 19:04 openafs-kernel-1.2.11
drwxr-xr-x 7 root root 4096 3月 15 17:15 redhat
[root@onlpc03 src]# cd linux-2.4.21-27.0.2.EL.cern
[root@onlpc03 linux-2.4.21-27.0.2.EL.cern]# ls
COPYING Makefile configs init mm
COPYING.modules README crypto ipc net
CREDITS REPORTING-BUGS drivers kdb save
Documentation Rules.make fs kernel scripts
MAINTAINERS arch include lib tmp_include_depends
[root@onlpc03 linux-2.4.21-27.0.2.EL.cern]# du -k
:
8 ./scripts/ksymoops
108 ./scripts/lxdialog
460 ./scripts
219472 .
[root@onlpc03 linux-2.4.21-27.0.2.EL.cern]#
---xxxx