現状の確認をしておこう まず ”fdisk -l”
# fdisk -l Disk /dev/hda: 255 heads, 63 sectors, 524 cylinders Units = cylinders of 16065 * 512 bytes Device Boot Start End Blocks Id System /dev/hda1 * 1 103 827316 6 FAT16 /dev/hda2 104 524 3381682+ b Win95 FAT32 Partition 2 has different physical/logical endings: phys=(522, 254, 63) logical=(523, 254, 63) Disk /dev/hdb: 255 heads, 63 sectors, 1216 cylinders Units = cylinders of 16065 * 512 bytes Device Boot Start End Blocks Id System /dev/hdb1 1 111 891576 b Win95 FAT32 /dev/hdb2 112 237 1012095 82 Linux swap /dev/hdb3 238 1216 7863817+ 83 Linux
次に ”fdisk -lu”です。
# fdisk -lu Disk /dev/hda: 255 heads, 63 sectors, 524 cylinders Units = sectors of 1 * 512 bytes Device Boot Start End Blocks Id System /dev/hda1 * 63 1654694 827316 6 FAT16 /dev/hda2 1654695 8418059 3381682+ b Win95 FAT32 Partition 2 has different physical/logical endings: phys=(522, 254, 63) logical=(523, 254, 63) Disk /dev/hdb: 255 heads, 63 sectors, 1216 cylinders Units = sectors of 1 * 512 bytes Device Boot Start End Blocks Id System /dev/hdb1 63 1783214 891576 b Win95 FAT32 /dev/hdb2 1783215 3807404 1012095 82 Linux swap /dev/hdb3 3807405 19535039 7863817+ 83 Linux
今回の 計算機の構成は 購入したものに IDE ? 内蔵 ハードディスクを 1 個 追加した物である。
/dev/hda1 に windows98 を インストールします。 その他の領域は今回は dos 関連とは関係の 無いように 他の 物に 変えておきます。今回は 83 です これは ”83 Linux”にしておきましょうということです。
# fdisk /dev/hdb /* まず /dev/hdb の 方を 変更します */ The number of cylinders for this disk is set to 1216. 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): t Partition number (1-4): 1 /* t change a partition's system id */ Hex code (type L to list codes): 83 /* l list known partition types */ Changed system type of partition 1 to 83 (Linux) Command (m for help): w /* w write table to disk and exit */ The partition table has been altered! Calling ioctl() to re-read partition table. Re-read table failed with error 16: Device or resource busy. Reboot your system to ensure the partition table is updated. WARNING: If you have created or modified any DOS 6.x partitions, please see the fdisk manual page for additional information. Syncing disks. # fdisk /dev/hda /* 今度は /dev/hda の 方です */ Command (m for help): t Partition number (1-4): 2 Hex code (type L to list codes): 83 Changed system type of partition 2 to 83 (Linux) Command (m for help): t Partition number (1-4): 1 Hex code (type L to list codes): c Changed system type of partition 1 to c (Win95 FAT32 (LBA)) Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. WARNING: If you have created or modified any DOS 6.x partitions, please see the fdisk manual page for additional information. Syncing disks.
確認しておきましょう
# fdisk -l Disk /dev/hda: 255 heads, 63 sectors, 524 cylinders Units = cylinders of 16065 * 512 bytes Device Boot Start End Blocks Id System /dev/hda1 * 1 103 827316 c Win95 FAT32 (LBA) /dev/hda2 104 524 3381682+ 83 Linux Partition 2 has different physical/logical endings: phys=(522, 254, 63) logical=(523, 254, 63) Disk /dev/hdb: 255 heads, 63 sectors, 1216 cylinders Units = cylinders of 16065 * 512 bytes Device Boot Start End Blocks Id System /dev/hdb1 1 111 891576 83 Linux /dev/hdb2 112 237 1012095 82 Linux swap /dev/hdb3 238 1216 7863817+ 83 Linux
”t change a partition's system id”としただけで 容量については、今回 変更 をしていません。
にゃんたろう 拝!
2007年 6月29日 (金) 21:21:46 JST 作成