Solved

Unable to remove Volume

Posted on 2014-08-01
18
232 Views
Last Modified: 2014-08-04
Hello,

While removing the Logical Volume i am getting below message

#lvremove /dev/myvg/myvol

Can't remove open logical volume

then i tried..

#dmsetup info -c /dev/myvg/myvol
Name              Maj Min Stat Open Targ Event  UUID                                                                
myvg-myvol  253   5 L--w    1    1      0 LVM-Q9kPfNDXzG5mBFsvrRlXXHaKvw2nsf7M6m9Hd96gnZIAOC8TcmChO8dthaU9FLU5

# dmsetup remove --force /dev/myvg/myvol
device-mapper: resume ioctl failed: Invalid argument
device-mapper: remove ioctl failed: Device or resource busy

I checked in /etc/mtab there is no entry for this but in /proc/mounts it contains entry for this concerned LV apart from this this device is not mounted anywhere in the system.. That i have checked..

Can someone help me in this ?

TY/SA
0
Comment
Question by:Sandy
  • 10
  • 5
  • 3
18 Comments
 
LVL 37

Expert Comment

by:Gerwin Jansen
ID: 40235235
Can you check whether it is in use?

#fuser -cu /dev/myvg/myvol
0
 
LVL 21

Expert Comment

by:Mazdajai
ID: 40235581
From dmsetup it looks like there is a partition in this LV (open status of 1), can you confirm and provide lvdisplay?
0
 
LVL 13

Author Comment

by:Sandy
ID: 40235587
In lvdisplay also the status of open is #1
0
 
LVL 21

Expert Comment

by:Mazdajai
ID: 40235594
Can you confirm if there is a partition in this LV?
0
 
LVL 13

Author Comment

by:Sandy
ID: 40235598
If I got u correctly...  there is no partition and apart from this it is dm-5 and I had tried that also by removing but no success...

let me know if m understanding it wrong..

TY/SA
0
 
LVL 13

Author Comment

by:Sandy
ID: 40238438
Any Suggestions ?

TY/SA
0
 
LVL 37

Expert Comment

by:Gerwin Jansen
ID: 40238597
>> Any Suggestions ?
What did the fuser command report?
0
 
LVL 13

Author Comment

by:Sandy
ID: 40238650
There was no output.....

TY/SA
0
 
LVL 21

Expert Comment

by:Mazdajai
ID: 40238673
Have you tried to reboot the box?
0
VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

 
LVL 13

Author Comment

by:Sandy
ID: 40238706
No not yet... having the same idea as reboot should release the lock on FS.. i will give it a try but any solution which i can try on fly will be more preferable..

TY/SA
0
 
LVL 13

Author Comment

by:Sandy
ID: 40239211
I've requested that this question be closed as follows:

Accepted answer: 0 points for Sandy's comment #a40238706
Assisted answer: 200 points for Mazdajai's comment #a40238673

for the following reason:

Rebooted the system but still there is no root cause found as why this was happening..
0
 
LVL 21

Accepted Solution

by:
Mazdajai earned 500 total points
ID: 40238845
Does the reboot cleared the lock?
0
 
LVL 13

Author Comment

by:Sandy
ID: 40239046
yes.. it did.. :)

TY/SA
0
 
LVL 21

Expert Comment

by:Mazdajai
ID: 40239082
There is indeed a lock on the FS but seems you have not include output on lsof/fuser (not that we do not trust you :) ), we will not able to verify now.
0
 
LVL 13

Author Comment

by:Sandy
ID: 40239111
I can paste it aswell need to search output of cmds in logs but believe me there was nothing

ty/sa
0
 
LVL 37

Expert Comment

by:Gerwin Jansen
ID: 40239212
I believe rebooting the machine fixed the issue so  http:#a40238673 is the solution and not  http:#a40238706

Why assign only 200 points instead of the 500 that were in the question?
0
 
LVL 13

Author Comment

by:Sandy
ID: 40239230
Ok Sir.. I will assign once m back to my desk... Thanks for help

ty/sa
0
 
LVL 13

Author Closing Comment

by:Sandy
ID: 40239234
Let me try...  thanks all
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this tutorial I will explain how to make squid prevent malwares in five easy steps: Squid is a caching proxy for the Web supporting HTTP, HTTPS, FTP, and more. It reduces bandwidth and improves response times by caching and reusing frequently-…
Daily system administration tasks often require administrators to connect remote systems. But allowing these remote systems to accept passwords makes these systems vulnerable to the risk of brute-force password guessing attacks. Furthermore there ar…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now