In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Recently, I want to flexibly manage the local hard disk of the server through LVM. The specific questions are as follows: [root@localhost ~] # pvcreate / dev/sdb
Device / dev/sdb not found (or ignored by filtering).
[root@localhost ~] # lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
Nvme0n1 259:0 0 2.9T 0 disk
Sda 8:0 0 744.1G 0 disk
├─ sda1 8:1 0 5G 0 part / boot
└─ sda2 8:2 0 739.1G 0 part
├─ VolGroup-LogVol01 (dm-0) 253 dm-0 0 0 390.6 G 0 lvm /
└─ VolGroup-LogVol00 (dm-1) 253 dm-1 1 0 260G 0 lvm [SWAP]
Sdb 8:16 0 21.8T 0 disk
[root@localhost soft] # fdisk-l / dev/sdb
WARNING: GPT (GUID Partition Table) detected on'/ devamp sdbstores! The util fdisk doesn't support GPT. Use GNU Parted.
Disk / dev/sdb: 24000.0 GB, 23999996231680 bytes
255 heads, 63 sectors/track, 2917833 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
/ dev/sdb1 1 267350 2147483647 + ee GPT
From the above, you can see that / dev/sdb adds a disk partition of sdb1 by default, and it is a GPT partition; I don't want to
Because it is very inconvenient to manage GPT, you can do the following operations to solve the problem through some information:
[root@localhost soft] # fdisk / dev/sdb
WARNING: GPT (GUID Partition Table) detected on'/ devamp sdbstores! The util fdisk doesn't support GPT. Use GNU Parted.
WARNING: The size of this disk is 24.0 TB (23999996231680 bytes).
DOS partition table format can not be used on drives for volumes
Larger than (2199023255040 bytes) for 512-byte sectors. Use parted (1) and GUID
Partition table format (GPT).
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
Switch off the mode (command 'c') and change display units to
Sectors (command'u').
Command (m for help): P
Disk / dev/sdb: 24000.0 GB, 23999996231680 bytes
255 heads, 63 sectors/track, 2917833 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
/ dev/sdb1 1 267350 2147483647 + ee GPT
Command (m for help): d
Selected partition 1
Command (m for help): P
Disk / dev/sdb: 24000.0 GB, 23999996231680 bytes
255 heads, 63 sectors/track, 2917833 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
Command (m for help): W
The partition table has been altered!
Calling ioctl () to re-read partition table.
Syncing disks.
As you can see above, delete the partition corresponding to its disk, as long as there is no data (remember)
[root@localhost soft] # pvcreate / dev/sdb
Physical volume "/ dev/sdb" successfully created
[root@localhost soft] # pvdisplay
"/ dev/sdb" is a new physical volume of "21.83 TiB"
-NEW Physical volume
PV Name / dev/sdb
VG Name
PV Size 21.83 TiB
Allocatable NO
PE Size 0
Total PE 0
Free PE 0
Allocated PE 0
The PV was created successfully, and then the management can be flexibly extended with LVM.
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.