次の手順に従って、現時点で実行レベル 0 になっているシステムを実行レベル 3 でブートします。
システムを再起動します。
# reboot |
Press any key to reboot プロンプトが表示されている場合は、任意のキーを押してシステムをリブートします。
あるいは、リセットボタンを使用することもできます。システムが停止している場合は、電源スイッチを押してシステムを起動します。
ブートシーケンスが始まると、GRUB メニューが表示されます。
GRUB メニューが表示されたら、Enter キーを押してデフォルトの OS インスタンスをブートします。
エントリを 10 秒以内に選択しない場合、システムは自動的に実行レベル 3 でブートします。
ブートプロセスが正常に終了すると、ログイン画面かログインプロンプトが表示されます。
システムにログインします。
hostname console login: |
システムが実行レベル 3 になっていることを確認します。
# who -r system% who -r . run-level 3 Mar 2 09:44 3 0 S |
# reboot Jul 24 11:29:52 bearskin reboot: rebooted by root syncing file systems... done rebooting... Adaptec AIC-7899 SCSI BIOS v2.57S4 (c) 2000 Adaptec, Inc. All Rights Reserved. Press <Ctrl><A> for SCSISelect(TM) Utility! Ch B, SCSI ID: 0 SEAGATE ST336607LSUN36G 160 GNU GRUB version 0.95 (637K lower / 2096064K upper memory) ============================================================== Solaris 10 10/08 s10x_u6wos_03 X86 Solaris failsafe ============================================================== Use the and keys to select which entry is highlighted. Press enter to boot the selected OS, 'e' to edit the commands before booting, or 'c' for a command-line. SunOS Release 5.10 Version Generic_137138-04 32-bit Copyright 1983-2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Hostname: pups NIS domain name is ....sfbay.sun.com Reading ZFS config: done. Mounting ZFS filesystems: (5/5) pups console login: # who -r . run-level 3 Jul 24 11:31 3 0 S |
次の手順に従って、実行レベル 0 になっているシステムを実行レベル S でブートします。シングルユーザーレベルは、システムを保守する場合に使用します。
この手順は、すべての GRUB 実装で使用できます。ただし、GRUB メインメニューに表示されるブートエントリは、実行している Oracle Solaris リリースに応じて異なります。
ブート時に指定できるすべてのカーネルオプションについては、「x86: ブート時に GRUB メニューを編集してブート動作を変更する」を参照してください。
システムを再起動します。
# reboot |
Press any key to reboot プロンプトが表示されている場合は、任意のキーを押してシステムをリブートします。
あるいは、リセットボタンを使用することもできます。システムが停止している場合は、電源スイッチを押してシステムを起動します。
ブートシーケンスが始まると、GRUB メニューが表示されます。
GRUB メインメニューが表示されたら、e と入力して GRUB メニューを編集します。
実行しているリリースによっては、矢印キーを使用して kernel または kernel$ 行を選択します。
矢印キーを使用できない場合は、キャレットキー (^) を使って上方へスクロールしたり、英字キー v を使って下方へスクロールしたりします。
e と再度入力してブートエントリを編集します。
ここから、kernel 行または kernel$ 行にオプションと引数を追加できます。
システムをシングルユーザーモードでブートするには、ブートエントリ行の末尾に -s を入力してから、Return キーを押して前の画面に戻ります。
他のブート動作を指定するには、-s オプションを適切なブートオプションに置き換えます。
この方法で、次の代替ブート動作を指定できます。
再構成用ブートを実行する
64 ビット対応のシステムを 32 ビットモードでブートする
カーネルデバッガを使ってシステムをブートする
コンソールをリダイレクトする
詳細は、boot(1M) のマニュアルページを参照してください。
システムをシングルユーザーモードでブートするには、b と入力します。
プロンプトが表示されたら、ルートパスワードを入力します。
システムが実行レベル S になっていることを確認します。
# who -r . run-level S Jun 13 11:07 S 0 0 |
実行レベルを S に移行して行う必要があるシステム保守作業を行います。
システムの保守作業が完了したら、システムをリブートします。
# reboot
Jul 2 14:30:01 pups reboot: initiated by root on /dev/console
syncing files...
Press <Ctrl><A> forPSCSISelect(TM) Utility!
GNU GRUB version 0.95 (637K lower / 2096064K upper memory)
===================================================
Solaris 10 10/08 s10x_u6wos_03 X86
Solaris failsafe
=====================================================
Use the and keys to select which entry is highlighted.
Press enter to boot the selected OS, 'e' to edit the
commands before booting, or 'c' for a command-line.
=====================================================
GNU GRUB version 0.95 (637K lower / 2096064K upper memory)
=====================================================
findroot (pool_rpool,0,a)
kernel$ /platform/i86pc/multiboot -B $ZFS-BOOTFS
module /platform/i86pc/boot_archive
================================================
Use the and keys to select which entry is highlighted.
Press 'b' to boot, 'e' to edit the selected command in the
boot sequence, 'c' for a command-line, 'o' to open a new line
after ('O' for before) the selected line, 'd' to remove the
selected line, or escape to go back to the main menu.
[ Minimal BASH-like line editing is supported. For the first word, TAB
lists possible command completions. Anywhere else TAB lists the possible
completions of a device/filename. ESC at any time exits. ]
grub edit> kernel$ /platform/i86pc/multiboot -B $ZFS-BOOTFS -s
GNU GRUB version 0.95 (637K lower / 2096064K upper memory)
=======================================================
findroot (pool_rpool,0,a)
kernel$ /platform/i86pc/multiboot -B $ZFS-BOOTFS -s
module /platform/i86pc/boot_archive
======================================
Use the and keys to select which entry is highlighted.
Press 'b' to boot, 'e' to edit the selected command in the
boot sequence, 'c' for a command-line, 'o' to open a new line
after ('O' for before) the selected line, 'd' to remove the
selected line, or escape to go back to the main menu.
.
.
.
SunOS Release 5.10
Copyright 1983-2008 Sun Microsystems, Inc. All rights reserved.
Use is subject to license terms.
Booting to milestone "milestone/single-user:default".
Hostname: pups Requesting System Maintenance Mode SINGLE USER MODE
Root password for system maintenance (control-d to bypass):
single-user privilege assigned to /dev/console.
Entering System Maintenance Mode
Jul 2 14:41:48 su: 'su root' succeeded for root on /dev/console Sun Microsystems Inc.
# who -r
who -r . run-level S Jul 2 14:39 S 0 0 #
|
代替のカーネルまたは代替の /etc/system ファイルを指定する必要がある場合は、次の手順に従ってシステムをブートします。
boot a コマンドを使用して x86 システムを対話式でブートするときに、代替の -/etc/system ファイルを指定するには、次の手順を実行します。
1. /etc/system ファイルと boot/solaris/filelist.ramdisk ファイルのバックアップコピーを作成します。
# cp /etc/system /etc/system.bak # cp /boot/solaris/filelist.ramdisk /boot/solaris/filelist.ramdisk.orig |
2. /etc/system.bak ファイル名を /boot/solaris/filelist.ramdisk ファイルに追加します。
# echo "etc/system.bak" >> /boot/solaris/filelist.ramdisk |
ブートアーカイブを更新します。
# bootadm update-archive -v |
システムを再起動します。
# reboot |
Press any key to reboot プロンプトが表示されている場合は、任意のキーを押してシステムをリブートします。
あるいは、リセットボタンを使用することもできます。システムが停止している場合は、電源スイッチを押してシステムを起動します。
ブートシーケンスが始まると、GRUB メインメニューが表示されます。
GRUB 編集メニューにアクセスするには、e と入力します。
矢印キーを使用して、kernel 行または kernel$ 行を選択します。
e と入力してブートエントリ行を編集します。
-a と入力して、システムを対話式でブートします。次に、Enter キーを押して前のメニューに戻ります。
システムを対話式でブートするために、b と入力します。
モジュールのデフォルトディレクトリを入力するか、Enter キーを押してデフォルトを受け入れます。
Enter default directory for modules [/platform/i86pc/kernel /kernel /usr/kernel]: |
代替システムファイル名 alternate-file を入力します。
Name of system file [etc/system]: /etc/system.bak |
代替ファイルを入力しないで Enter キーを押すと、デフォルトが受け入れられます。
破損した /etc/system ファイルを修復します。
システムを実行レベル 3 でリブートします。
# reboot
syncing file systems... done
rebooting...
GNU GRUB version 0.95 (637K lower / 2096064K upper memory)
===================================================
Solaris 10 10/08 s10x_u6wos_03 X86
Solaris failsafe
=====================================================
Use the and keys to select which entry is highlighted.
Press enter to boot the selected OS, 'e' to edit the
commands before booting, or 'c' for a command-line.
=====================================================
GNU GRUB version 0.95 (637K lower / 2096064K upper memory)
=====================================================
findroot (pool_rpool,0,a)
kernel$ /platform/i86pc/multiboot -B $ZFS-BOOTFS
module /platform/i86pc/boot_archive
======================================================
Use the and keys to select which entry is highlighted.
Press 'b' to boot, 'e' to edit the selected command in the
boot sequence, 'c' for a command-line, 'o' to open a new line
after ('O' for before) the selected line, 'd' to remove the
selected line, or escape to go back to the main menu.
[ Minimal BASH-like line editing is supported. For the first word, TAB
lists possible command completions. Anywhere else TAB lists the possible
completions of a device/filename. ESC at any time exits. ]
grub edit> kernel$ /platform/i86pc/multiboot -B $ZFS-BOOTFS -a
GNU GRUB version 0.95 (637K lower / 2096064K upper memory)
===================================================
findroot (pool_rpool,0,a)
kernel$ /platform/i86pc/multiboot -B $ZFS-BOOTFS -a
module /platform/i86pc/boot_archive
====================================================
.
.
.
Enter default directory for modules [/platform/i86pc/kernel /kernel /usr/kernel]:
Name of system file [/etc/system]: /etc/system.bak
SunOS Release 5.10 Version Generic_137138-04 32-bit
Copyright 1983-2008 Sun Microsystems, Inc. All rights reserved.
Use is subject to license terms.
Hostname: pups
NIS domain name is ....sfbay.sun.com
Reading ZFS config: done.
Mounting ZFS filesystems: (5/5)
pups console login:
|