2012年3月26日星期一

Moncler StoreLinuxSystem Administrator Raiders ( three) author Li Wanpeng team Department se

LinuxSystem Administrator Raiders ( three) author Li Wanpeng team Department server has a total of 8 hard disks, each 600GB ,but DF h ,see ,actually only about 600GB ,where is other seven harddisk? Use parted and LVM to solve this problem .
One .Using the parted tool : root@chinaltcdragon parted GNU Parted 2.1 # use / dev / SDA Welcome to GNU Parted !Type to view a list of commands (parted) P Model: IBM ServeRAID M5015 ( SCSI ) Disk / dev / SDA: 599GB Sector size ( logical / physical ) :512B / 512B Partition Table : GPT Number Start End Size File system Name 1049kB 211MB 210MB FAT16 start mark 1 2 211MB 735MB 524MB ext4 3 735MB 599GB 598GB LVM could see the / dev / SDA is already well area ,then we can copy ,in accordance with the specifications of the other seven harddisk partition .
The first fdisk l found their names :/ dev / sdb1 172825584959999 + EE GPT Disk / dev / SDA: 599 GB ,598999040000 bytes / dev / sda1 172825584959999 + EE GPT Disk / dev / SDD: 599 GB ,Moncler Store,598999040000 bytes / dev / SDD1 172825584959999 + EE GPT Disk / dev / SDC: 599 GB ,598999040000 bytes / dev / SDC1 172825584959999 + EE GPT Disk / dev / SDH: 599 GB ,598999040000 bytes / dev / sdh1 172825584959999 + EE GPT Disk / dev / SDG: 599 GB ,598999040000 bytes / dev / sdg1 172825584959999 + EE GPT Disk / dev / SDE: 599 GB ,598999040000 bytes / dev / SDE1 172825584959999 + EE GPT Disk / dev / SDF: 599 GB ,598999040000 bytes / dev / SDF1 172825584959999 + EE GPT / dev / SDD here to partition : # parted / dev / SDD GNU Parted 2.
1 / dev / SDD Welcome to use GNU Parted !Type to view a list of commands .Harddisk :( parted ) P Model: IBM ServeRAID M5015 ( SCSI ) Disk / D EV / SDD: 599GB Sector size ( logical / physical ) :512B / 512B Partition Table: GPT Number Start End Size File system Name logo used in the parted mkpart command input help partition ,you can view the parted various command :( parted ) mkpart partition name ? ?1 types of file system ? ext2 FAT16 starting point ??1049k end point ?211m ( parted ) mkpart partition name ? ?2 types of file system ? ext2 ext4 starting point ??211m end point ?735m ( parted ) mkpart partition name ? ?3 types of file system ? ext2 ext4 starting point ??735m end point ?598GB is then set to boot partition partition 1 :( parted ) set 1 boot on partition finished print again ,harddisk partition information :( parted ) P Model: IBM ServeRAID M5015 ( SCSI ) Disk / dev / SDD: 599GB Sector size ( logical / physical ) :512B / 512B Partition Table: GPT Number Start End Size File system Name 1 1049kB 211MB 210MB 1 sign to start the 2 211MB 735MB 524MB 23 735MB 598GB 597GB 3 if the partition process a partition was wrong ,you can use RM + number to delete partition ,the input help can be found at .
Two .Use the LVM: here are some command :LVM vgscan ,UGG UK Sale,vgdisplay ,lvscan ,Vibram Shoes,pvscan .LVM part of the operation is divided in several steps: creating physical volume: lvm> ;pvcreate / dev / sdd3 Writing physical volume data to disk " / dev / sdd3" ;Physical ;volume " ;successfully created / dev / sdd3" ;to view the current volume group vgscan Reading all name lvm> ;physical volumes .
This may take a while... Found volume group " ;vg_chinaltcdragon" ;using metadata type lvm2 physical volume volume group to add lvm> ;vgextend vg_chinaltcdragon / dev / sdd3 Volume group " ;vg_chinaltcdragon" ;successfully extended to check this volume group logical volume lvm> which have lvscan ;ACTIVE / dev / vg_chinaltcdragon / lv_root inherit ACTIVE / dev / vg_chinaltcdragon / lv_home inherit ACTIVE / dev / vg_chinaltcdragon / lv_swap inherit vg_chinaltcdragon volume group described here has 3 logical volumes .
Add the physical volume to logical volume lvm> ;lvextend / dev / vg_chinaltcdragon / lv_home / dev / sdd3 Extending logical volume lv_home to 2.09 TiB Logical volume lv_home successfully resized logical volume lvm> lvscan check ;ACTIVE / dev / vg_chinaltcdragon / lv_root inherit ACTIVE / dev / vg_chinaltcdragon / lv_home inherit ACTIVE / dev / vg_chinaltcdragon / lv_swap inherit can see the / dev / vg_chinaltcdragon / lv_home the logical volume has increased in size .
But DF h look ,did not change: root@chinaltcdragon # DF - H file system volume is available with %% mount point / dev / mapper / vg_chinaltcdragon-lv_root 50G 3.9G 43G TMPFS 18G 188K 9% / 18G 1% / dev / SHM / dev / sda2 485M 62M 398M 14% / boot / dev / sda1 200M 256K 200M 1% / boot / EFI / dev / mapper / vg_chinaltcdragon-lv_home 1.
6T 140G 1.4T 10% / home here is 1.6T ,because team foreigners have used parted and LVM mounted on the 2 harddisk .The last part ,Dr Dre Headphones,use the tool resize2fs logical volume size : root@chinaltcdragon # resize2fs / dev / vg_chinaltcdragon / lv_home resize2fs 1.
41.12 ( 17-May-2010 ) Filesystem at / dev / vg_chinaltcdragon / lv_home is mounted on / home on-line resizing ;required old desc_blocks = 100 ,new_desc_blocks = 134 Performing an on-line resize of / dev / vg_chinaltcdragon / lv_home to 561076224 ( 4K ) blocks .
The filesystem on / dev / vg_chinaltcdragon / lv_home is now 561076224 blocks long. Check again ,has been extended to 2.1TB ,OK ,Well done ,Lady Gaga Heartbeats! # DF - H file system volume is available with %% mount point / dev / mapper / vg_chinaltcdragon-lv_root 50G 3.
9G 43G 9% / TMPFS 18G 188K 18G 1% / dev / SHM / dev / sda2 485M 62M 398M 14% / boot / dev / sda1 200M 256K 200M 1% / boot / EFI / dev / mapper / vg_chinaltcdragon-lv_home 2.1T 142G 1.
Related articles:

没有评论:

发表评论