- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- lvm_lock and lvextend
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-21-2005 09:40 AM
06-21-2005 09:40 AM
lvm_lock and lvextend
I have vgextended the disk to /dev/vg00
I have mkbooted the disk and added the command ("hpux -lq").
I am now lvextending -m 1 the logical volumes. In the past I have been able to (I am pretty sure I have) do mulitple lvextend's at the same time BUT this time it came up with the error message:
Cannot lock "/etc/lvmconf//lvm_lock" still trying ...#
So why is this happening?
Second thing is this, when I check the file lvm_lock it was an file that is at least 20 days old.
I checked for running lvm processes and also checked to if any processes where acessing the file using lsof but there were none.
I deleted the file, ran another lvextend and found the lvm_conf file back again ran another lvextend with the same error message. But once the first lvextend process finished I was able to run another one even though the lvm_lock file was still present. How is this possible?
I could try using my other login to see if it relates to the shell but......
From what I have read the lvm_lock file is only present when changes are being made to the lvmtab file, but access should be very quick not the length of time it takes to mirror the logical volume - not to mention the file being left after the command has finished.
I would also add that the machine has been re-booted in the last week so the first lvm_lock file was present before but did not stop me running the lvextend command the very first time.
What is going on?
Many thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-21-2005 09:52 AM
06-21-2005 09:52 AM
Re: lvm_lock and lvextend
I prefer scripting the lvextend commands like:
for i in 1 2 3 4 5 6 7 8 9
do
echo "Mirroring /dev/vg00/lvol${i}"
lvextend -m 1 /dev/vg00/lvol${i} /dev/dsk/c?t?d?
done
That way no manual intervention is required and as soon as 1 finishes the next will start.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-21-2005 09:52 AM
06-21-2005 09:52 AM
Re: lvm_lock and lvextend
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-21-2005 10:06 AM
06-21-2005 10:06 AM
Re: lvm_lock and lvextend
Purpose of the lvm_lock files is that when lvm commands run and need to access the lvmtab file there needs to be a way so that they do not update/access the file when it is being updated/accessed by other lvm commands.
By deleting the lvm_lock file you could have one lvm command update or access the lvmtab file while another command is already doing this. This could cause the system to behave incorrectly or even corrupt the lvmtab file or worst case cause it to be lost completely.
Sometimes it might be necessary to delete the lvm_lock file to release the lvmtab file for lvm commands. If the process holding the lvm_lock can be killed gracefully it should remove the lock. A reboot may be needed afterward to free the lvmtab file. Afterward the lvm command should work fine.
cheers!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-21-2005 10:20 AM
06-21-2005 10:20 AM
Re: lvm_lock and lvextend
I can assure you that no other processes are accessing either the lvmtab or the lvm_lock.
As someone said, maybe I cannot run the lvextend command twice (I must be thinking of Solaris and mirroring that root disk because it can run mulitple mirrors on the slices at the same time).
Anyway I have just checked on two other machines and the file is present there so maybe it is simply suppose to be there.
Thanks for all your help am closing this now.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-21-2005 11:41 AM
06-21-2005 11:41 AM