- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: How do yuo know if a LV is in use? and if a LV...
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
05-04-2007 02:24 AM
05-04-2007 02:24 AM
How do yuo know if a LV is in use? and if a LV is mounted?
already i have used these:
e.g:
lvdisplay v /dev/vg00/lvol2
lvdisplay -v /dev/vg00/lvol2
mount -v
more /etc/fstab
fuser -c /dev/vg00/lvol2
fuser -u /dev/vg00/lvol2
none of these is displaying what i expect, whitch is, if it is in use, or if it is mounted.
What command may i use for this?
Thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 02:28 AM
05-04-2007 02:28 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
# bdf /dev/vg00/lvol2
..should also show whether or not it's mounted, but will probably yield the same results.
When you say "none of these is displaying what i expect": what do they display, and what do you expect ? :-)
Cheers,
Wout
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 02:29 AM
05-04-2007 02:29 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 02:30 AM
05-04-2007 02:30 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
One way to know if a filesystem is mounted on a logical volume is to look at 'etc/mnttab'.
# cat /etc/mnttab
If you want to assess what files and/or directories are open, use 'lsof' which is available from the HP-UX Porting Center.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 02:31 AM
05-04-2007 02:31 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
# swapinfo -tam
--> will show your active swapping devices. It's probably there ;-)
(0 points on this post please, this should have been above)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 02:34 AM
05-04-2007 02:34 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
mount | grep ${lv}
will tell you if it's mounted.
The other potential option is its used as a raw volume in a database...
ls -ld /dev/${vg}/r${lv##*/}
will show the ownership of the raw volume. If it's not root, then it's probably being used as a raw volume.
Doug
------
Senior UNIX Admin
O'Leary Computers Inc
linkedin: http://www.linkedin.com/dkoleary
Resume: http://www.olearycomputers.com/resume.html
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 02:37 AM
05-04-2007 02:37 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 03:11 AM
05-04-2007 03:11 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
i have lvol3, lvol12 for swap pri, but swapinfo -tab display lvol2, lvol3 and lvol12, the strange thing is that lvol2 is not in fstab or mntab, why is this happening?
i have lvol4 and i can´t see it, i don´t know if lvol4 is being use. Tried to run lsof but isn´t installed.
how do i know who mounted lvol2 as swap area?
e.g.
taken from fstab:
/dev/vg00/lvol12 ... swap pri=1 0 0
/dev/vg00/lvol3 ... swap pri=1 0 0
swapinfo -tab:
# swapinfo -tam
Mb Mb Mb PCT START/ Mb
TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 8192 3407 4785 42% 0 - 1 /dev/vg00/lvol2
dev 12288 3420 8868 28% 0 - 1 /dev/vg00/lvol12
dev 8192 3430 4762 42% 0 - 1 /dev/vg00/lvol3
reserve - 17718 -17718
memory 9451 1316 8135 14%
total 38123 29291 8832 77% - 0 -
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 03:18 AM
05-04-2007 03:18 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
vg00/lvol2 should always exist.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 03:18 AM
05-04-2007 03:18 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
lvol2 is the swap space created when the OS is first installed. It is never "mounted" and hence will never show in the mnttab or fstab. In fact most swap should be device swap, since it is faster.
As stated earlier there are applications (usually datbases) that write directly to the lvol, and do not require a file system to be mounted. In this case, as stated earlier, the only way to truly know if it is in use is documentation - and communication with the DBA's
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 03:22 AM
05-04-2007 03:22 AM
SolutionYou can get lsof from any of the HP-UX Porting Centres.
http://hpux.its.tudelft.nl/hppd/hpux/Sysadmin/lsof-4.77/
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 03:39 AM
05-04-2007 03:39 AM
Re: How do yuo know if a LV is in use? and if a LV is mounted?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2007 03:40 AM
05-04-2007 03:40 AM