|
|||||||||||||
1. Managing Removable Media (Overview) 2. Managing Removable Media (Tasks) 3. Accessing Removable Media (Tasks) 4. Writing CDs and DVDs (Tasks) 5. Managing Devices (Overview/Tasks) 6. Dynamically Configuring Devices (Tasks) 7. Using USB Devices (Overview) 9. Using InfiniBand Devices (Overview/Tasks) 11. Administering Disks (Tasks) 12. SPARC: Adding a Disk (Tasks) 13. x86: Adding a Disk (Tasks) x86: Adding a System Disk or a Secondary Disk (Task Map) x86: Adding a System Disk or a Secondary Disk x86: How to Connect a System Disk How to Change the Solaris fdisk Identifier x86: How to Connect a Secondary Disk and Boot x86: How to Create a Solaris fdisk Partition x86: How to Create Disk Slices and Label a Disk 14. Configuring Solaris iSCSI Targets and Initiators (Tasks) 15. Configuring and Managing the Solaris Internet Storage Name Service (iSNS) 16. The format Utility (Reference) 17. Managing File Systems (Overview) 18. Creating UFS, TMPFS, and LOFS File Systems (Tasks) 19. Mounting and Unmounting File Systems (Tasks) 20. Using The CacheFS File System (Tasks) 21. Configuring Additional Swap Space (Tasks) 22. Checking UFS File System Consistency (Tasks) 23. UFS File System (Reference) 24. Backing Up and Restoring File Systems (Overview) 25. Backing Up Files and File Systems (Tasks) 26. Using UFS Snapshots (Tasks) 27. Restoring Files and File Systems (Tasks) 28. UFS Backup and Restore Commands (Reference) 29. Copying UFS Files and File Systems (Tasks) |
x86: Adding a System Disk or a Secondary DiskA system disk contains the root (/) or /usr file systems, or both. If the disk that contains either of these file systems becomes damaged, you have two ways to recover:
A secondary disk doesn't contain the root (/) and /usr file systems. A secondary disk usually contains space for user files. You can add a secondary disk to a system for more disk space. Or, you can replace a damaged secondary disk. If you replace a secondary disk on a system, you can restore the old disk's data on the new disk. x86: How to Connect a System DiskThis procedure assumes that the operating system is shutdown.
|
Task |
Go To |
For More Information |
---|---|---|
Create a Solaris fdisk partition to span the entire disk. |
Step 5 |
|
Create a Solaris fdisk partition and preserve one or more existing non Solaris fdisk partitions. |
Step 6 |
|
Create a Solaris fdisk partition and one or more additional non Solaris fdisk partition. |
Step 6 |
No fdisk table exists. The default partition for the disk is: a 100% "SOLARIS System" partition Type "y" to accept the default partition, otherwise type "n" to edit the partition table. y
Type "y" to accept the default partition, otherwise type "n" to edit the partition table. n Total disk size is 3498 cylinders Cylinder size is 1199 (512 byte) blocks Cylinders Partition Status Type Start End Length % ========= ====== ======== ===== === ====== === SELECT ONE OF THE FOLLOWING: 1. Create a partition 2. Specify the active partition 3. Delete a partition 4. Change between Solaris and Solaris2 Partition IDs 5. Exit (update disk configuration and exit) 6. Cancel (exit without updating disk configuration) Enter Selection:
Enter Selection: 1
Indicate the type of partition you want to create 1=SOLARIS2 2=UNIX 3=PCIXOS 4=Other 5=DOS12 6=DOS16 7=DOSEXT 8=DOSBIG 9=DOS16LBA A=x86 Boot B=Diagnostic C=FAT32 D=FAT32LBA E=DOSEXTLBA F=EFI 0=Exit? 1
Specify the percentage of disk to use for this partition (or type "c" to specify the size in cylinders). nn
Should this to become the active partition? If yes, it will be activated each time the computer is reset or turned on. Please type "y" or "n". y
The Enter Selection prompt is displayed after the fdisk partition is activated.
See steps 8–10 for instructions on creating an fdisk partition.
Selection: 5
format> label Ready to label disk, continue? yes format>
format> quit
The following example uses the format utility's fdisk option to create a Solaris fdisk partition that spans the entire drive.
# format Searching for disks...done AVAILABLE DISK SELECTIONS: 0. c0d0 <DEFAULT cyl 2466 alt 2 hd 16 sec 63> /pci@0,0/pci-ide@7,1/ide@0/cmdk@0,0 1. c0d1 <DEFAULT cyl 522 alt 2 hd 32 sec 63> /pci@0,0/pci-ide@7,1/ide@0/cmdk@1,0 2. c1d0 <DEFAULT cyl 13102 alt 2 hd 16 sec 63> /pci@0,0/pci-ide@7,1/ide@1/cmdk@0,0 Specify disk (enter its number): 0 selecting c0d0 Controller working list found [disk formatted] format> fdisk No fdisk table exists. The default partitioning for your disk is: a 100% "SOLARIS System" partition. Type "y" to accept the default partition, otherwise type "n" to edit the partition table. y format> label Ready to label disk, continue? yes format> quitExample 13-2 x86: Creating a Solaris fdisk Partition While Preserving an Existing fdisk Partition
The following example shows how to create a Solaris fdisk partition on a disk that has an existing DOS-BIG fdisk partition.
format> fdisk Total disk size is 3498 cylinders Cylinder size is 1199 (512 byte) blocks Cylinders Partition Status Type Start End Length % ========= ====== ============ ===== === ====== === 1 Active DOS-BIG 1 699 699 20 SELECT ONE OF THE FOLLOWING: 1. Create a partition 2. Specify the active partition 3. Delete a partition 4. Change between Solaris and Solaris2 Partition IDs 5. Exit (update disk configuration and exit) 6. Cancel (exit without updating disk configuration) Enter Selection: 1 Indicate the type of partition you want to create 1=SOLARIS2 2=UNIX 3=PCIXOS 4=Other 5=DOS12 6=DOS16 7=DOSEXT 8=DOSBIG 9=DOS16LBA A=x86 Boot B=Diagnostic C=FAT32 D=FAT32LBA E=DOSEXTLBA F=EFI 0=Exit?1 Indicate the percentage of the disk you want this partition to use (or enter "c" to specify in cylinders). 80 Should this become the active partition? If yes, it will be activated each time the computer is or turned on. Please type "y" or "n". y Total disk size is 3498 cylinders Cylinder size is 1199 (512 byte) blocks Cylinders Partition Status Type Start End Length % ========= ====== ============ ===== === ====== === 1 DOS-BIG 1 699 699 20 2 Active Solaris2 700 3497 2798 80 SELECT ONE OF THE FOLLOWING: 1. Create a partition 2. Specify the active partition 3. Delete a partition 4. Change between Solaris and Solaris2 Partition IDs 5. Exit (update disk configuration and exit) 6. Cancel (exit without updating disk configuration) Enter Selection:5 Partition 2 is now the active partition format> label Ready to label disk, continue? yes format> qExample 13-3 x86: Creating a Solaris fdisk Partition and an Additional fdisk Partition
This following example shows how to create a Solaris fdisk partition and a DOSBIG fdisk partition.
format> fdisk No fdisk table exists. The default partitioning for your disk is: a 100% "SOLARIS System" partition. Type "y" to accept the default partition, otherwise type "n" to edit the partition table. n Total disk size is 3498 cylinders Cylinder size is 1199 (512 byte) blocks Cylinders Partition Status Type Start End Length % ========= ====== ============ ===== === ====== === SELECT ONE OF THE FOLLOWING: 1. Create a partition 2. Specify the active partition 3. Delete a partition 4. Change between Solaris and Solaris2 Partition IDs 5. Exit (update disk configuration and exit) 6. Cancel (exit without updating disk configuration) Enter Selection: 1 Indicate the type of partition you want to create 1=SOLARIS2 2=UNIX 3=PCIXOS 4=Other 5=DOS12 6=DOS16 7=DOSEXT 8=DOSBIG 9=DOS16LBA A=x86 Boot B=Diagnostic C=FAT32 D=FAT32LBA E=DOSEXTLBA F=EFI 0=Exit? 8 Specify the percentage of disk to use for this partition (or type "c" to specify the size in cylinders)20 Should this to become the Active partition? If yes, it will be activated each time the computer is reset or turned on. again. Please type "y" or "n". n Total disk size is 3498 cylinders Cylinder size is 1199 (512 byte) blocks Cylinders Partition Status Type Start End Length % ========= ====== ============ ===== === ====== === 1 DOS-BIG 1 699 699 20 SELECT ONE OF THE FOLLOWING: 1. Create a partition 2. Specify the active partition 3. Delete a partition 4. Change between Solaris and Solaris2 Partition IDs 5. Exit (update disk configuration and exit) 6. Cancel (exit without updating disk configuration) Enter Selection: 1 Indicate the type of partition you want to create 1=SOLARIS2 2=UNIX 3=PCIXOS 4=Other 5=DOS12 6=DOS16 7=DOSEXT 8=DOSBIG 9=DOS16LBA A=x86 Boot B=Diagnostic C=FAT32 D=FAT32LBA E=DOSEXTLBA F=EFI 0=Exit? 1 Indicate the percentage of the disk you want this partition to use (or enter "c" to specify in cylinders). 80 Should this become the active partition? If yes, it will be activated each time the computer is reset or turned on. Please type "y" or "n". y Total disk size is 3498 cylinders Cylinder size is 1199 (512 byte) blocks Cylinders Partition Status Type Start End Length % ========= ====== ============ ===== === ====== === 1 DOS-BIG 1 699 699 20 2 Active Solaris2 700 3497 2798 80 SELECT ONE OF THE FOLLOWING: 1. Create a partition 2. Specify the active partition 3. Delete a partition 4. Change between Solaris and Solaris2 Partition IDs 5. Exit (update disk configuration and exit) 6. Cancel (exit without updating disk configuration) Enter Selection: 5 Partition 2 is now the Active partition format> q
After you create a Solaris fdisk partition on the disk, you can create slices on the disk. Go to x86: How to Create Disk Slices and Label a Disk
# format
A numbered list of disks is displayed.
Specify disk (enter its number): disk-number
where disk-number is the number of the disk that you want to repartition.
format> partition
partition> print
partition> modify
Choose base (enter number) [0]? 1
For more information about the free hog slice, see Using the Free Hog Slice.
Do you wish to continue creating a new partition table based on above table[yes]? yes
When adding a system disk, you must set up slices for the following:
root (slice 0) and swap (slice 1) and/or
/usr (slice 6)
After you identify the slices, the new partition table is displayed.
Okay to make this the current partition table[yes]? yes
If you don't want the current partition table and you want to change it, answer no and go to Step 6.
Enter table name (remember quotes): "partition-name"
where partition-name is the name for the new partition table.
Ready to label disk, continue? yes
partition> quit
format> verify
format> quit
After you create disk slices and label the disk, you can create file systems on the disk. Go to x86: How to Create File Systems.
# newfs /dev/rdsk/cwtxdysz
where /dev/rdsk/cwtxdysz is the raw device for the file system to be created.
For more information about the newfs command, see Chapter 18, Creating UFS, TMPFS, and LOFS File Systems (Tasks) or newfs(1M).
# mount /dev/dsk/cwtxdysz /mnt # ls /mnt lost+found
System Disk – You need to restore the root (/) and /usr file systems on the disk.
After the root (/) and /usr file systems are restored, install the boot block. Go to x86: How to Install a Boot Block on a System Disk.
Secondary Disk – You might need to restore file systems on the new disk. Go to Chapter 27, Restoring Files and File Systems (Tasks). If you are not restoring file systems on the new disk, you are finished adding a secondary disk.
For information on making the file systems available to users, see Chapter 19, Mounting and Unmounting File Systems (Tasks).
# /sbin/installgrub /boot/grub/stage1 /boot/grub/stage2 /dev/rdsk/cwtxdysz
Is the partition boot file.
Is the boot block code.
Is the raw device name that represents the location of the GRUB menu, /boot/grub/menu.lst on the Solaris root slice.
For more information, see installgrub(1M).
# init 6
The following example shows how to install the boot blocks on an x86 system.
# /sbin/installgrub /boot/grub/stage1 /boot/grub/stage2 /dev/rdsk/c1d0s0 stage1 written to partition 0 sector 0 (abs 2016) stage2 written to to partition 0, 227 sectors starting 50 (abs 2066)
Previous | Next |