| Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
08-03-2012, 04:58 PM
|
#1
|
|
LQ Newbie
Registered: Aug 2012
Posts: 2
Rep: 
|
LVM pvs is showing /dev/dm-x as PV name instead of /dev/mapper
Hello folks,
I am having some hard time making LVM's pvs command print /dev/mapper devices instead of dm-X devices.
Extract from lvm.conf:
preferred_names = [ "^/dev/mapper/", "^/dev/[hs]d" ]
filter = [ "a/dev/mapper/.*/", "a/dev/sdb/", "a/dev/sdc/", "r/dev/sd.*/" ]
The weirdest part is that I'm getting /dev/mapper entries when I issue pvscan, but not when I do pvs.
[root@begonia ~]# pvscan
PV /dev/sdc1 VG Volsdc_local lvm2 [135.50 GB / 508.00 MB free]
PV /dev/sdb5 VG Volsda400 lvm2 [46.50 GB / 18.50 GB free]
PV /dev/mapper/new_eva_sandisk1p1 VG NewSanVolEVA01 lvm2 [200.00 GB / 10.00 GB free]
PV /dev/mapper/new_eva_sandisk2p1 VG NewSanVolEVA01 lvm2 [250.00 GB / 5.00 GB free]
PV /dev/mapper/san_disk1 VG san_vg1 lvm2 [450.00 GB / 15.00 GB free]
Total: 5 [1.06 TB] / in use: 5 [1.06 TB] / in no VG: 0 [0 ]
[root@begonia ~]# pvs
PV VG Fmt Attr PSize PFree
/dev/dm-7 san_vg1 lvm2 a- 450.00G 15.00G
/dev/dm-8 NewSanVolEVA01 lvm2 a- 250.00G 5.00G
/dev/dm-9 NewSanVolEVA01 lvm2 a- 200.00G 10.00G
/dev/sdb5 Volsda400 lvm2 a- 46.50G 18.50G
/dev/sdc1 Volsdc_local lvm2 a- 135.50G 508.00M
[root@begonia ~]# ls -l /dev/mapper/
total 0
crw------- 1 root root 10, 63 Aug 4 2012 control
brw-rw---- 1 root disk 253, 6 Aug 3 23:26 new_eva_sandisk1
brw-rw---- 1 root disk 253, 9 Aug 3 23:26 new_eva_sandisk1p1
brw-rw---- 1 root disk 253, 5 Aug 3 23:26 new_eva_sandisk2
brw-rw---- 1 root disk 253, 8 Aug 3 23:26 new_eva_sandisk2p1
brw-rw---- 1 root disk 253, 17 Aug 3 23:26 NewSanVolEVA01-staging
brw-rw---- 1 root disk 253, 11 Aug 3 23:26 NewSanVolEVA01-u01
brw-rw---- 1 root disk 253, 12 Aug 3 23:26 NewSanVolEVA01-u02
brw-rw---- 1 root disk 253, 13 Aug 3 23:26 NewSanVolEVA01-u04
brw-rw---- 1 root disk 253, 14 Aug 3 23:26 NewSanVolEVA01-u06
brw-rw---- 1 root disk 253, 15 Aug 3 23:26 NewSanVolEVA01-u07
brw-rw---- 1 root disk 253, 16 Aug 3 23:26 NewSanVolEVA01-u99
brw-rw---- 1 root disk 253, 7 Aug 3 23:26 san_disk1
brw-rw---- 1 root disk 253, 24 Aug 3 23:26 san_vg1-san_staging
brw-rw---- 1 root disk 253, 18 Aug 3 23:26 san_vg1-san_u01
brw-rw---- 1 root disk 253, 19 Aug 3 23:26 san_vg1-san_u02
brw-rw---- 1 root disk 253, 20 Aug 3 23:26 san_vg1-san_u04
brw-rw---- 1 root disk 253, 21 Aug 3 23:26 san_vg1-san_u06
brw-rw---- 1 root disk 253, 22 Aug 3 23:26 san_vg1-san_u07
brw-rw---- 1 root disk 253, 23 Aug 3 23:26 san_vg1-san_u99
brw-rw---- 1 root disk 253, 0 Aug 4 2012 Volsda400-LogVol00
brw-rw---- 1 root disk 253, 3 Aug 4 2012 Volsda400-LogVol01
brw-rw---- 1 root disk 253, 2 Aug 4 2012 Volsda400-LogVol02
brw-rw---- 1 root disk 253, 1 Aug 4 2012 Volsda400-LogVol03
brw-rw---- 1 root disk 253, 4 Aug 4 2012 Volsda400-LogVol04
brw-rw---- 1 root disk 253, 10 Aug 3 23:26 Volsdc_local-u888
I have read these existing forum topics, but nothing worked for me.
http://www.linuxquestions.org/questi...x-path-754073/
http://www.linuxquestions.org/questi...volume-754741/
What am I doing wrong?
|
|
|
|
08-04-2012, 04:16 PM
|
#2
|
|
Member
Registered: Aug 2006
Posts: 601
Rep:
|
I actually think you are doing nothing wrong at all
Could you do ls -lh /dev/dm* ?
Note that LVM actually uses dm.
The ls -lh of the dm* devices should confirm this. (if your udev rules keeps them there.)
|
|
|
|
08-05-2012, 10:27 AM
|
#3
|
|
LQ Newbie
Registered: Aug 2012
Posts: 2
Original Poster
Rep: 
|
Thanks for replying.
Actually, I think I found the problem. It seems that "pvdispay", "pvs" and possibly other commands simply ignore the changes you do to lvm.conf. However, "pvscan" is reading the config correctly.
When I disabled caching (write_cache_state = 0), I started getting the PVM names I was after.
|
|
|
|
08-05-2012, 12:12 PM
|
#4
|
|
Member
Registered: Aug 2006
Posts: 601
Rep:
|
Quote:
Originally Posted by n0rus
Thanks for replying.
Actually, I think I found the problem. It seems that "pvdispay", "pvs" and possibly other commands simply ignore the changes you do to lvm.conf. However, "pvscan" is reading the config correctly.
When I disabled caching (write_cache_state = 0), I started getting the PVM names I was after.
|
In the end these are symlinks.
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 10:50 PM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|