- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Change logical volume name
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
09-23-2003 11:27 AM
09-23-2003 11:27 AM
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-23-2003 11:43 AM
09-23-2003 11:43 AM
SolutionUsing your /dev/vg21/lvol1 to /dev/vg21/rice as an example:
1) Unmount whatever dir /dev/vg21/lvol1 is mounted to.
# umount /whatever
2) Rename the LV
# cd /dev/vg21
# mv lvol1 rice
# mv rlvol1 rrice
Note that in this step you MUST mv BOTH the lvol1 and rlvol1 files. Be SURE that you include the leading 'r' in the new name for the rlvol1 to rrice (2 r's in this rice).
3) Modify /etc/fstab to change the name the lvol that is mounted from /dev/vg21/lvol1 to /dev/vg21/rice
# cp /etc/fstab /etc/fstab.back
# vi /etc/fstab
4) Remount the LV
# mount /whatever
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-23-2003 11:44 AM
09-23-2003 11:44 AM
Re: Change logical volume name
You can change the name of a Logical Volume using the following steps:
1. Umount the Filesystem
2. mv /dev/vg21/lvol1 /dev/vg21/rice
3. mv /dev/vg21/rlvol1 /dev/vg21/rrice
4. Edit /etc/fstab
5. Mount filesystem
Note that you cannot rename a Volume Group without recreating it.
Cheers
Con
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-23-2003 11:55 AM
09-23-2003 11:55 AM
Re: Change logical volume name
The above is also in the knowledge base
http://www5.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000062941034
HTH
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-23-2003 03:58 PM
09-23-2003 03:58 PM
Re: Change logical volume name
as other says that method will work and alternatively you can use following method.
it's bit lenthy.
1. unmount file system
2. note down the Major and minor number of lvol1/rlvol1.
3. delete device file for lvol1 and rrlvol1.
4. recreate device file name rice rrice with same major and minor numbers using mknod.
5. change fstab and rmount it.
Sunil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-23-2003 10:27 PM
09-23-2003 10:27 PM
Re: Change logical volume name
Get the minor number for the lvol you want to rename: let's say 0x1a0000,
mknod /dev/vgxx/rnewlvol c 64 0x1a0000
mknod /dev/vgxx/newlvol b 64 0x1a0000
Now test this:
lvdisplay -v /dev/vgxx/newlvol
Compare this to an lvdisplay of the old lvol. It will be the same.
Now you have the option to use the new name without any funny business. You can delete the old names (using rm, not lvremove!) once you are happy that you do not use the old lvol name anywhere where you have not changed it to the new (like in /etc/fstab, scripts, Omniback, etc).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-24-2003 03:50 AM
09-24-2003 03:50 AM