In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
How to understand SVM in Solaris10, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain in detail for you, people with this need can come to learn, I hope you can gain something.
SolarisVolumeManager uses virtual disks to manage physical disks and their associated data. In SolarisVolumeManager
Virtual disks are called volumes, and for historical reasons, some command-line utilities also refer to volumes as meta devices (meta).
From an application or file system point of view, a volume is functionally identical to a physical disk.
SolarisVolumeManager volumes are built from disk or other SolarisVolumeManager volumes. A simple way to create a volume
Is to use a graphical user interface (graphicaluserinterface,GUI) built into SolarisManagementConsole.
For example, if you need more storage capacity as a single volume, you can use SolarisVolumeManager to make the system treat the slice collection as
A larger volume. After using these slices to create a volume, you can immediately start using the volume, just like using any "real" film or device
.
SolarisVolumeManager can improve the reliability and availability of data by using RAID-1 (mirrored) volumes and RAID-5 volumes.
SolarisVolumeManager hot spares can further improve the data availability of mirror and RAID-5 volumes.
You can use most file system commands on volumes, including mkfs, mount, umount, ufsdump, ufsrestore, and so on. But
You cannot use the format command As long as the volume contains a mounted file system, you can read, write, and copy files to the volume.
Show
Example-A volume with two slices. The following figure shows a volume with two slices, one from disk An and the other from disk B. Should
Using a program or UFS will treat volumes as if they were a physical disk. By adding more slices to the volume, you can increase its storage capacity.
1.2 supported extended volume mode
You can expand disk space in a volume in the following ways:
Add one or more slices to a RAID-0 volume
Add one or more slices to all child images of a RAID-1 volume
Add one or more slices to a RAID-5 volume
Extend soft partitions by adding space in the underlying component
Just like a physical film, the logical name of the volume appears in the file system. The logical volume name is in the / dev/md/dsk directory of the block device and
There is a corresponding entry in the / dev/md/rdsk directory of the original device. In any meta* command, you usually use an abbreviated volume name (such as D1)
Instead of specifying the full volume name (such as / dev/md/dsk/volume-name). In general, as long as the volume is not currently in use
The volume can be renamed if the new name is not used by other volumes.
1.3 Volume name command rules
Initially, the volume name must start with the letter "d" followed by a number (for example, d0). This format is still available today. The following is to make
Example of a volume name constructed with a "d*" name:
/ dev/md/dsk/d0 block volume d0
/ dev/md/dsk/d1 block volume D1
/ dev/md/rdsk/d126 raw volume d126
/ dev/md/rdsk/d127 raw volume d127
Principles for naming volume names:
Using a uniform standard when naming volume names simplifies management and allows you to quickly identify volume types. Here are a few suggestions:
● specifies a range for each type of volume. For example, specify the numbers 0-20 for RAID-1 volumes, 21-40 for RAID-0 volumes, and so on
Wait.
● determines the relationship between mirrors by naming. For example, use a number that ends with zero (0) to name the mirror, and use one (1), two (2).
The numeric naming sub-image at the end of, etc. For example, you can name a mirror as follows: mirror D10, sub-image D11 and D12; mirror D20, sub-image
Mirror
Like D21, D22, D23 and D24.
● uses a naming method that maps slice and disk numbers to volume numbers.
Figure 1 illustrates the mirror d20. The mirror consists of two volumes (sub-images) d21 and d22.
SolarisVolumeManager generates the same copy of data on multiple physical disks and displays a virtual disk to the application
(d20 in this example). What is written on all disks is the same. Disk reads come from one of the underlying sub-images. Mirror image
D20
The total capacity is the size of the smallest mirror image (for example, the size of the fruit image is not equal).
1.4 Management of volumes
1) solaris divides a hard disk into 8 0-7slice. The IA architecture consists of 10 partitions.
2) commonly used zones:
Slice
0 /
1 swap
2 entiredisk
5 opt
6 / export
3) there are two kinds of SVM management ideas:
Create a disk partition as a logical volume, and then create a raid. Like raid1.
B. create raid directly from disk partitions, such as raid5,raid0.
SVM needs to have a stat db hold volume, raid information. So you generally need to create a stat db on multiple disks.
# metadb-f-a-c 2 c0d0s3 c0d1s3 c1d0s3 c1d1s3
Chapter 2 commonly used orders
2.1 Common commands and functions
1) metadb creates stat db.
2) metainit creates logical volumes and creates raid commands.
3) metastat views volume and raid information.
4) metaclear deletes the volume and deletes raid.
5) metareplace:
Replace the partition in the volume. It means to replace the components in the volume. But I understand that it is generally to change the partition of the volume. There is another function.
Is to enable the partition in the volume so that the volume is resynchronized.
# metareplace-e D11 c1d1s4 enables c1d1s4 partitions in D11.
# metareplace D11 c1d0s4 c1d1s4 uses c1d1s4 to replace the damaged c1d0s4 in volume D11
6) metaonline/metaoffline:
This command is used in raid1, but I don't think it's necessary. If the disk is damaged, you don't need offline, just detach.
It would be nice to have one more attach, who makes him raid1.
7) metattach/metadetach: add / remove volumes and partitions to the created raid.
8) metahs: modify the partition in the hot backup pool.
9) metaparam: modify the raid configuration, such as the read and write properties of raid0, and bind the hot backup pool to raid.
10) growfs: expand the volume set size online.
Format: growfs-M / mount-point / device-rdsk-point
2.2 Solaris Volume Manager Command Quick reference
Solaris Volume Manager Command description man page
Growfs extends the UFS file system in a non-destructive manner. Growfs (1m)
Metaclear deletes active volumes and hot spare pools. Metaclear (1m)
Metadb creates and deletes copies of the state database. Metadb (1m)
Metadetach separates volumes from RAID-0 or RAID-1 (mirrored) volumes, or separates log devices from transaction volumes. Note
-transaction volumes are no longer supported. Metadetach (1m)
Metadevadm checks the device ID configuration. Metadevadm (1m)
Metahs manages hot spares and hot spare pools. Metahs (1m)
Metaimport imports disk sets (including replicated disk sets) into an existing Solaris with device ID support in the disk set
Volume Manager
Configuration. Metaimport (1m)
Metainit configures the volume. Metainit (1m)
Metaoffline takes the child image offline. Metaoffline (1m)
Metaonline brings the child images online. Metaonline (1m)
Metaparam modifies volume parameters. Metaparam (1m)
Metarecover restores the configuration information of the soft partition. Metarecover (1m)
Metarename renames and swaps volume names. Metarename (1m)
Metareplace replaces components in child images and RAID-5 volumes. Metareplace (1m)
Metaroot sets up system files for mirroring the root (/) file system. Metaroot (1m)
Metaset manages disk sets. Metaset (1m)
Metastat displays the status of the volume or hot spare pool. Metastat (1m)
Metasync resynchronizes volumes during reboot. Metasync (1m)
Metattach connects components to RAID-0 or RAID-1 volumes. Metattach (1m)
Chapter 3 example of SVM command operation
1) Environment introduction: a certain amount of space needs to be added to isms_dg 's mps file system for database backup, which is expanded by the previous 4G
To 50g
Mps is used to back up the database of itellindb
/ dev/md/iscc_dg/dsk/d605 52522647 52097 51945324 1%
/ export/home/mps
2) add 46G to mps (d605) under iscc_dg and connect the components
Metattach-s iscc_dg d605 46g
3) extend the UFS file system in a non-destructive manner
Growfs-M / export/home/mps / dev/md/iscc_dg/rdsk/d605
4) View the results
Root@itellin2 (iscp7) # metastat-s iscc_dg d605
Iscc_dg/d605: Soft Partition
Device: iscc_dg/d510
State: Okay
Size: 106659840 blocks (50 GB)
Extent Start Block Block count
0 49152160 12288000
1 102400512 94371840 / / additional space
Iscc_dg/d510: Concat/Stripe
Size: 2856124416 blocks (1.3 TB)
Stripe 0: (interlace: 32 blocks)
Device Start Block Dbase State Reloc Hot Spare
D4s0 0 No Okay No
D5s0 0 No Okay No
Device Relocation Information:
Device Reloc Device ID
D4 No-
D5 No-
Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.