Oracle Database Appliance – Extend /u01
Verify the actual
Situation and the Disk Configuration
As ODA default
/u01 space is around 100GB that is not enough as we have all oracle database
related binaries on that location including ORACLE_BASE and ORACLE_HOME
Note: ODA-2HA two node, so you have to perform same on both nodes as below
Currently, extending /u01 only node1
1.
Let’s check the current size of /u01
[root@ODA-2HA-X8~]# df -h /u01
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VolGroupSys-LogVolU01 99G
43G 51G 46% /u01
2. Let’s verify the physical volume for free space,
we can see 7428 free physical extents are available
[root@ODA-2HA-X8 ~]# pvdisplay
---
Physical volume ---
PV
Name /dev/md126p3
VG
Name VolGroupSys
PV
Size <446.15 GiB / not
usable 23.00 MiB
Allocatable yes
PE
Size 32.00 MiB
Total
PE 14276
Free PE 7428
Allocated
PE 6848
PV
UUID
fYtdV3-N71S-HKXf-Kov2-tIk8-X0pF-TfRLzn
3.
This is the actual size of the logical volume;
the actual logical volume size is 100 GB.
[root@ODA-2HA-X8 ~]# lvdisplay
/dev/mapper/VolGroupSys-LogVolU01
--- Logical
volume ---
LV
Path /dev/VolGroupSys/LogVolU01
LV
Name LogVolU01
VG
Name VolGroupSys
LV
UUID
VnV8hE-I0yy-yJz4-BOgR-jo3u-nsno-yNdHh1
LV Write
Access read/write
LV Creation
host, time localhost.localdomain, 2022-06-29 21:17:50 +0300
LV
Status available
# open 1
LV Size 100.00 GiB
Current
LE 3200
Segments 1
Allocation inherit
Read ahead
sectors auto
- currently
set to 8192
Block
device 252:39
Extend /u01
4.
Now we extend online the LVM with the lvextend
command from 100 GB to 200 GB.
[root@ODA-2Ha-X8 ~]# lvextend --size +100G
/dev/VolGroupSys/LogVolU01
Size of
logical volume VolGroupSys/LogVolU01 changed from 100.00 GiB (3200 extents) to
200.00 GiB (6400 extents).
Logical
volume VolGroupSys/LogVolU01 successfully resized.
[root@ODA-2HA-X8 ~]# lvdisplay
/dev/mapper/VolGroupSys-LogVolU01
--- Logical
volume ---
LV
Path
/dev/VolGroupSys/LogVolU01
LV
Name LogVolU01
VG
Name VolGroupSys
LV
UUID
VnV8hE-I0yy-yJz4-BOgR-jo3u-nsno-yNdHh1
LV Write
Access read/write
LV Creation
host, time localhost.localdomain, 2022-06-29 21:17:50 +0300
LV
Status available
# open 1
LV
Size 200.00 GiB
Current
LE 6400
Segments 2
Allocation inherit
Read ahead
sectors auto
- currently
set to 8192
Block
device 252:39
5.
Finally, the filesystem has to be resized.
[root@ODA-2HA-X8 ~]# resize2fs
/dev/VolGroupSys/LogVolU01
resize2fs 1.42.9 (28-Dec-2013)
Filesystem at /dev/VolGroupSys/LogVolU01 is mounted
on /u01; on-line resizing required
old_desc_blocks = 7, new_desc_blocks = 13
The filesystem on /dev/VolGroupSys/LogVolU01 is now
52428800 blocks long.
6.
Now we have 200GB space of /u01
[root@ODA-2HA-X8 ~]# df -h /u01
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VolGroupSys-LogVolU01 197G 43G 146G
23% /u01
Summary
Resizing the /u01 on an Oracle
Database Appliance is very easy and straightforward. There are no special
actions required, it’s just a logical volume, no downtime required. And there
is more space left on the physical volume for other resize actions.