- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Add new disk using LVM on RedHat AS 4.0
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
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
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-14-2007 01:48 AM
тАО05-14-2007 01:48 AM
I need to use one disk already installed on my Linux Server:
Red Hat AS 4.0:
Note: (Physical Volume pvcreate is already performed by someone else).
1. Create new Volume Group VolGroup01 using (/dev/sdb1).
2. Create new Logical Volumes LogVol01 (30GB) & LogVol02 (30GB) in new VolGroup VolGroup01.
3. Make two volumes of 30 GB each.
4. Format the new volumes.
5. Mount them on /u02 (30GB) and /u03 (30GB).
6. FSTAB entires.
[root@wolfdev03 ~]# fdisk -l
Disk /dev/sda: 73.4 GB, 73406611456 bytes
255 heads, 63 sectors/track, 8924 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 8924 71577607+ 8e Linux LVM
Disk /dev/sdb: 73.4 GB, 73406611456 bytes
128 heads, 32 sectors/track, 35003 cylinders
Units = cylinders of 4096 * 512 = 2097152 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 35003 71686143+ 8e Linux LVM
-------------------------------------------------------------------
[root@wolfdev03 ~]# pvscan
PV /dev/sda2 VG VolGroup00 lvm2 [68.25 GB / 32.00 MB free]
PV /dev/sdb1 VG VolGroup00 lvm2 [68.34 GB / 68.34 GB free]
Total: 2 [136.59 GB] / in use: 2 [136.59 GB] / in no VG: 0 [0 ]
-------------------------------------------------------------------
[root@wolfdev03 ~]# lvscan
ACTIVE '/dev/VolGroup00/LogVol00' [58.22 GB] inherit
ACTIVE '/dev/VolGroup00/LogVol01' [10.00 GB] inherit
Thanks,
Gulam.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 02:06 AM
тАО05-14-2007 02:06 AM
Re: Add new disk using LVM on RedHat AS 4.0
after pvcreate
Either
vgcreate a new volume group.
vgcreate -n newvg /dev/sdb1
lvcreate -L 30 GB newvg
mkfs.ext3
mount
You got a filesystem to use.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 02:30 AM
тАО05-14-2007 02:30 AM
Re: Add new disk using LVM on RedHat AS 4.0
[root@wolfdev03 ~]# vgcreate VolGroup01 /dev/sdb1
Physical volume '/dev/sdb1' is already in volume group 'VolGroup00'
Unable to add physical volume '/dev/sdb1' to volume group 'VolGroup01'
Thanks,
Gulam.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 03:27 AM
тАО05-14-2007 03:27 AM
Solution1. Create new Volume Group VolGroup01 using (/dev/sdb1).
Not possible/needed, sdb already in a volume group.
2. Create new Logical Volumes LogVol01 (30GB) & LogVol02 (30GB) in new VolGroup VolGroup01.
3. Make two volumes of 30 GB each.
LogVol01 already exists, use a new logical volume name. Let's say, LogVol02 and LogVol03.
lvcreate -n LogVol02 -L 30GB VolGroup00
lvcreate -n LogVol03 -L 30GB VolGroup00
4. Format the new volumes.
mkfs -t ext3 /dev/VolGroup00/LogVol02
mkfs -t ext3 /dev/VolGroup00/LogVol03
tune2fs -i 0 -c 0 -m 0 /dev/VolGroup00/LogVol02
tune2fs -i 0 -c 0 -m 0 /dev/VolGroup00/LogVol03
5. Mount them on /u02 (30GB) and /u03 (30GB).
mkdir /u02
mount /dev/VolGroup00/LogVol02 /u02
mkdir /u03
mount /dev/VolGroup00/LogVol03 /u03
6. FSTAB entires.
Copy/paste another fstab entry and correct the device and mount point fields.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 04:18 AM
тАО05-14-2007 04:18 AM
Re: Add new disk using LVM on RedHat AS 4.0
if you want to create VolGroup01 with /dev/sdb1 first you have to
$ vgreduce VolGroup00 /dev/sdb1
then
$ vgcreate VolGroup01 /dev/sdb1
rgds
HGH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 04:20 AM
тАО05-14-2007 04:20 AM
Re: Add new disk using LVM on RedHat AS 4.0
Thanks,
Gulam.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 04:29 AM
тАО05-14-2007 04:29 AM
Re: Add new disk using LVM on RedHat AS 4.0
no you do not need to take volumegroup offline neither for reducing nor for extending.
Just make sure no LE of /dev/sdb1 is used:
PV /dev/sdb1 VG VolGroup00 lvm2 [68.34 GB / 68.34 GB free]
looks good for me.
rgds
HGH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2007 06:13 AM
тАО05-14-2007 06:13 AM
Re: Add new disk using LVM on RedHat AS 4.0
This job is done.
Thanks,
Gulam.