Use the falcon resource pool in centos 7 and configure it as LVM mirror

Source: Internet
Author: User

Use the falcon resource pool in centos 7 and configure it as LVM mirror

Ensure thatFalconThe specified device already has a resource pool available for use.

Operating Environment# Uname-

Linux zzsrv1.localdomain 3.10.0-123. el7.x86 _ 64 # 1smp mon Jun 30 12:09:22 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

# Cat/etc/RedHat-release

Centos linuxrelease 7.0.1406 (CORE)

Install the iSCSI package # Mount/dev/CDROM/mnt/CDROM/

Mount:/dev/sr0is write-protected, mounting read-only

# Cd/mnt/CDROM/packages/# ls iSCSI *

Iscsi-initiator-utils-6.2.0.873-21.el7.x86_64.rpm

Iscsi-initiator-utils-iscsiuio-6.2.0.873-21.el7.x86_64.rpm

# Rpm-uvh iscsi-initiator-utils-6.2.0.873-21.el7.x86_64.rpmiscsi-initiator-utils-iscsiuio-6.2.0.873-21.el7.x86_64.rpm

 

Warning: iscsi-initiator-utils-6.2.0.873-21.el7.x86_64.rpm: Header V3 RSA/sha256signature, key ID f4a80eb5: nokey

Preparing... ################################### [100%]

Updating/installing...

1: iscsi-initiator-utils-iscsiuio-6. ################################# [50%]

2: iscsi-initiator-utils-6.2.0.873-2 ################################# [100%]

# Rpm-QC iSCSI-initiator-utils

/Etc/iSCSI/iscsid. conf

Configure iSCSI

Because all the configuration files I use are default, that is, there is no user name or password, the subsequent operations will be simpler. If you need the user name and password, you can change it through the configuration file, you can also change it in the command mode. Specific usableIscsiadm-helpView commands

# Iscsiadm-M node-T iqn.2000-03.com. falconstor-ipstor.FalconStor-CDPVA.liunx-test-0-p192.168.188.128: 3260 -L

Loggingin to [iface: Default, target: iqn.2000-03.com. falconstor-ipstor.FalconStor-CDPVA.liunx-test-0, portal: 192.168.188.128, 3260] (multiple)

Loginto [iface: Default, target: iqn.2000-03.com. falconstor-ipstor.FalconStor-CDPVA.liunx-test-0, portal: 192.168.188.128, 3260] successful.

# Fdisk - L

Disk/dev/SDA: 21.5 GB, 21474836480 bytes, 41943040 sectors

......

 

Disk/dev/SDB: 21.5 GB, 21474836480 bytes, 41943040 sectors

......

 

Disk/dev/SDC: 21.5 GB, 21474836480 bytes, 41943040 sectors

Units = sectorsof 1*512 = 512 bytes

Sector size (logical/physical): 512 bytes/512 bytes

I/O size (minimum/optimal): 512 bytes/512 bytes

Now, this Linux system can use the falcon disk to create the mirror of LVM.

# Fdisk/dev/SDB

Welcome to fdisk (util-Linux 2.23.2 ).

Changes willremain in memory only, until you decide to write them.

Be carefulbefore using the write command.

 

Device does notcontain a recognized Partition Table

Building a newdos disklabel with disk identifier 0xa04efd3a.

 

Command (M forhelp): n

Partition type:

P primary (0 primary, 0 extended, 4 free)

E extended

Select (defaultp ):

Using defaultresponse P

Partition Number (1-4, default 1 ):

First Sector (2048-41943039, default 2048 ):

Using defaultvalue 2048

Last sector, + sectors or + size {K, M, g} (2048-41943039, default 41943039 ):

Using defaultvalue 41943039

Partition 1 oftype Linux and of size 20 Gib is set

 

Command (M forhelp): p

 

Disk/dev/SDB: 21.5 GB, 21474836480 bytes, 41943040 sectors

Units = sectorsof 1*512 = 512 bytes

Sector size (logical/physical): 512 bytes/512 bytes

I/O size (minimum/optimal): 512 bytes/512 bytes

Disk label type: DoS

Disk identifier: 0xa04efd3a

 

Device boot start end blocks ID system

/Dev/sdb1 2048 41943039 20970496 83 Linux

 

Command (M forhelp): W

The partitiontable has been altered!

 

Calling IOCTL () to re-read partition table.

Syncing disks.

[[Email protected] # fdisk/dev/SDC

Welcome to fdisk (util-Linux 2.23.2 ).

 

Changes willremain in memory only, until you decide to write them.

Be carefulbefore using the write command.

 

Device does notcontain a recognized Partition Table

Building a newdos disklabel with disk identifier 0xe8278ed3.

 

Command (M forhelp): n

Partition type:

P primary (0 primary, 0 extended, 4 free)

E extended

Select (defaultp ):

Using defaultresponse P

Partition Number (1-4, default 1 ):

First Sector (2048-41943039, default 2048 ):

Using defaultvalue 2048

Last sector, + sectors or + size {K, M, g} (2048-41943039, default 41943039 ):

Using defaultvalue 41943039

Partition 1 oftype Linux and of size 20 Gib is set

 

Command (M forhelp): W

The partitiontable has been altered!

 

Calling IOCTL () to re-read partition table.

Syncing disks.

# Ll/dev/SD *

BRW-RW ---- 1 root disk 8, 0 aug16 09:43/dev/SDA

BRW-RW ---- 1 root disk 8, 1 aug16 09:43/dev/sda1

BRW-RW ---- 1 root disk 8, 2 aug16/dev/sda2

BRW-RW ---- 1 root disk 8, 16 Aug 16 :49/dev/SDB

BRW-RW ---- 1 root disk 8, 17 Aug 16 :49/dev/sdb1

BRW-RW ---- 1 root disk 8, 32 Aug 16 11: 49/dev/s

BRW-RW ---- 1 root disk 8, 33 Aug 16 :49/dev/sdc1

# Pvcreate/dev/SD [BC] [1]

Physical Volume "/dev/sdb1" successfully created

Physical Volume "/dev/sdc1" successfully created

# Vgcreate vgdata/dev/SD [BC] 1

Volume group "vgdata" successfully created

# Lvcreate-M1-l 19.51g vgdata-N backupdlv/dev/SD [BC] 1

Rounding up size to full physicalextent 19.51 Gib

Logical volume "backupdlv" created

# LVS-a-O + Devices

Lv vg attr lsize pool ORIGIN data % Move logcpy % sync convert Devices

Root centos_zzsrv1-wi-ao ---- 18.23g/dev/sda2 (328)

Swap centos_zzsrv1-wi-ao ---- 1.28g/dev/sda2 (0)

Backupdlv vgdata RWI-a-r --- 19.51g 5.23 backupdlv_rimage_0 (0), backupdlv_rimage_1 (0)

[Backupdlv_rimage_0] vgdata iwi-AOR --- 19.51g/dev/sdb1 (1)

[Backupdlv_rimage_1] vgdata iwi-AOR --- 19.51g/dev/sdc1 (1)

[Backupdlv_rmeta_0] vgdata EWI-AOR --- 4.00 m/dev/sdb1 (0)

[Backupdlv_rmeta_1] vgdata EWI-AOR --- 4.00 m/dev/sdc1 (0)

# Mkfs. ext4/dev/vgdata/backupdlv

Mke2fs 1.42.9 (28-dec-2013)

Filesystem label =

OS type: Linux

Block size = 4096 (log = 2)

Fragment size = 4096 (log = 2)

Stride = 0 blocks, stripe width = 0 blocks

1281120 inodes, 5114880 Blocks

255744 blocks (5.00%) reserved for the Super User

First data block = 0

Maximum filesystem blocks = 2153775104

157 block groups

32768 blocks per group, 32768 fragments per group

8160 inodes per group

Superblock backups stored on blocks:

32768,983 04, 163840,229 376, 294912,819 200, 884736,160 5632, 2654208,

4096000

 

Allocating group tables: Done

Writing inode tables: Done

Creating Journal (32768 blocks): Done

Writing superblocks and filesystem accountinginformation: Done

# Mkdir/backupd # Mount/dev/vgdata/backupdlv/backupd

If you want to use this device directly at next startup, you can set the iSCSI boot and fstab mount.

Now, Falcon is used in Linux.


This article from the "cloud computing Park" blog, please be sure to keep this source http://leegh.blog.51cto.com/8764149/1541024

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.