LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 09-19-2019, 02:44 AM   #1
lelunicu
Member
 
Registered: Jun 2019
Posts: 105

Rep: Reputation: 0
lvdisplay


hi,
i like to know if the below conbfiguration is raid 0.

sudo lvdisplay -m|more
--- Logical volume ---
LV Path /dev/y/test
LV Name test
VG Name y
LV UUID oLKKGm-lIOW-6XmQ-P2Z9-1AiK-WB5t-I8VfXZ
LV Write Access read/write
LV Creation host, time test, 2018-04-14 10:25:42 +0000
LV Status available
# open 1
LV Size 118.99 GiB
Current LE 30462
Segments 3
Allocation inherit
Read ahead sectors auto
- currently set to 8192
Block device 253:5

--- Segments ---
Logical extents 0 to 12798:
Type linear
Physical volume /dev/sdb1
Physical extents 0 to 12798

Logical extents 12799 to 25597:
Type linear
Physical volume /dev/sdb2
Physical extents 0 to 12798

Logical extents 25598 to 30461:
Type linear
Physical volume /dev/sdc1
Physical extents 0 to 4863

Last edited by lelunicu; 09-19-2019 at 02:46 AM.
 
Old 09-19-2019, 04:31 AM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Quote:
Originally Posted by lelunicu View Post
Type linear
RAID 0 is striping. You LV is not striped.
 
Old 09-19-2019, 07:34 AM   #3
lelunicu
Member
 
Registered: Jun 2019
Posts: 105

Original Poster
Rep: Reputation: 0
then what is this lv?
 
Old 09-19-2019, 06:52 PM   #4
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Quote:
Originally Posted by lelunicu View Post
then what is this lv?
A non-striped, non-mirrored logical volume. Also known as a linear logical volume.
 
Old 09-24-2019, 05:12 AM   #5
lelunicu
Member
 
Registered: Jun 2019
Posts: 105

Original Poster
Rep: Reputation: 0
linear or concatenated.right?
the data will be written first in /dev/sdb1,when this is full then will write in /dev/sdb2.
 
Old 09-24-2019, 05:24 AM   #6
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Quote:
Originally Posted by lelunicu View Post
linear or concatenated.right?
The correct term is "linear", but "concatenated" is a correct description.

Quote:
the data will be written first in /dev/sdb1,when this is full then will write in /dev/sdb2.
This is not correct. Let's create a scenario:
sdc is free.
Volume 1 has physical extents on sdb.
Volume 2 also has physical extents on sdb.
Volume 1 is extended - new physical extents come from sdc.
Volume 2 is removed.
Volume 1 is extended again - new physical extents may come from sdb.
"linear" means that there is no mirroring, striping or other RAID level. You can also ask for a volume to be contiguous; in this case, I think it will be allocated as you say.

Last edited by berndbausch; 09-24-2019 at 05:25 AM.
 
Old 09-24-2019, 08:09 AM   #7
lelunicu
Member
 
Registered: Jun 2019
Posts: 105

Original Poster
Rep: Reputation: 0
then how data is written on lv?
 
Old 09-24-2019, 09:28 AM   #8
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Just like any other storage device.

Remember that storage is random-access. You can write blocks sequentially, or you can seek to a position and write at that position. Therefore, data is not written from the beginning to the end, as you said.

When dealing with linear logical volumes, each logical extent is mapped to exactly one physical extent. When you write to the logical volume sequentially, you start at the first logical extent, filling the corresponding physical extent. When the extent is full, you continue at the second logical extent, filling the corresponding physical extent. And so on.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
lvdisplay not showing lv_home jimblegend Linux - Server 2 03-29-2017 06:41 PM
(LVM) open failed: no such file or directory output in lvdisplay command rohitchauhan Linux - General 1 04-28-2014 12:17 PM
df and lvdisplay discrepency on size. marcos602phx Linux - Newbie 3 10-25-2009 12:06 AM
lvdisplay -v doesn't diplay detail LV info osiosi Linux - Newbie 6 06-28-2006 12:03 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:02 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration