프린트 하기 URL 복사

OS 환경 : Oracle Linux 9.6 (64bit)

 

DB 환경 : Oracle Database 19.31.0.0

 

방법 : 오라클 19c ACFS 크기 변경 방법

본문에서는 acfs 파일시스템을 resize 시키는 방법을 설명함

 

 

현재 acfs 확인

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
$ df -Th /acfs/
Filesystem               Type  Size  Used Avail Use% Mounted on
/dev/asm/acfs_my_vol-150 acfs  1.0G  311M  714M  31/acfs
 
$ asmcmd volinfo -G DATA acfs_my_vol
Diskgroup Name: DATA
 
         Volume Name: ACFS_MY_VOL
         Volume Device: /dev/asm/acfs_my_vol-150
         State: ENABLED
         Size (MB): 1024
         Resize Unit (MB): 64
         Redundancy: UNPROT
         Stripe Columns: 8
         Stripe Width (K): 1024
         Usage: ACFS
         Mountpath: /acfs

1gb가 할당되어 있음

 

 

acfsutil 명령으로 확인

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
$ acfsutil info fs
/acfs
    ACFS Version: 19.0.0.0.0
    on-disk version:       49.0
    compatible.advm:       19.0.0.0.0
    ACFS compatibility:    19.0.0.0.0
    flags:        MountPoint,Available,KiloSnap
    creation time:   Fri Aug 14 12:52:10 2026
    mount time:      Fri Aug 14 12:55:11 2026
    mount sequence number: 0
    number of nodes:       1
    allocation unit:       4096
    metadata block size:   4096
    volumes:      1
    total size:   1073741824  (   1.00 GB )
    total free:   747929600  ( 713.28 MB )
    file entry table allocation: 262144
    primary volume: /dev/asm/acfs_my_vol-150
        label:
        state:                 Available
        major, minor:          25076801
        logical sector size:   512
        size:                  1073741824  (   1.00 GB )
        free:                  747929600  ( 713.28 MB )
        metadata read I/O count:         2098
        metadata write I/O count:        48
        total metadata bytes read:       8843264  (   8.43 MB )
        total metadata bytes written:    622592  ( 608.00 KB )
        ADVM diskgroup:        DATA
        ADVM resize increment: 67108864
        ADVM redundancy:       unprotected
        ADVM stripe columns:   8
        ADVM stripe width:     1048576
    number of snapshots:  0
    snapshot space usage: 0  ( 0.00 )
    replication status: DISABLED
    compression status: DISABLED

더 상세한 정보를 볼수 있음

 

 

현재 디스크그룹 용량 확인

1
2
3
$ asmcmd lsdg
State    Type    Rebal  Sector  Logical_Sector  Block       AU  Total_MB  Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
MOUNTED  EXTERN  N         512             512   4096  1048576     40959    12897                0           12897              0             N  DATA/

여유 용량이 있음

 

 

5gb로 증설

1
2
$ acfsutil size 5G /acfs
acfsutil size: new file system size: 5368709120 (5120MB)

바로 증설됨

 

 

현재 acfs 확인

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
$ df -Th /acfs/
Filesystem               Type  Size  Used Avail Use% Mounted on
/dev/asm/acfs_my_vol-150 acfs  5.0G  319M  4.7G   7/acfs
 
$ asmcmd volinfo -G DATA acfs_my_vol
Diskgroup Name: DATA
 
         Volume Name: ACFS_MY_VOL
         Volume Device: /dev/asm/acfs_my_vol-150
         State: ENABLED
         Size (MB): 5120
         Resize Unit (MB): 64
         Redundancy: UNPROT
         Stripe Columns: 8
         Stripe Width (K): 1024
         Usage: ACFS
         Mountpath: /acfs

크기가 증설됨

 

 

현재 크기에서 1gb 더 증설

1
2
$ acfsutil size +1G /acfs
acfsutil size: new file system size: 6442450944 (6144MB)

 

 

현재 디스크그룹 용량 확인

1
2
3
$ asmcmd lsdg
State    Type    Rebal  Sector  Logical_Sector  Block       AU  Total_MB  Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
MOUNTED  EXTERN  N         512             512   4096  1048576     40959     7777                0            7777              0             N  DATA/

Free_MB가 기존보다 6gb 더 줄어듬

 

 

만약 acfs 파일시스템을 아직 만들지 않은 순수 ADVM volume인 경우 acfsutil이 아닌 volresize 명령으로 변경해야함

1
$ asmcmd volresize -G DATA -s 2G acfs_my_vol

 

 

아직 용량을 다 사용하지 않은 경우 용량 축소도 가능함

1
2
$ acfsutil size -1G /acfs
acfsutil size: new file system size: 5368709120 (5120MB)

 

 

이 경우 q 옵션을 이용해 가능여부를 먼저 확인할수도 있음
샘플 파일 acfs에 삽입

1
$ cp p39062956_190000_Linux-x86-64.zip /acfs/

 

 

현재 acfs 경로에 4.1gb 크기의 파일이 존재함

1
2
3
4
$ ls -lh /acfs/
total 4.1G
drwx------ 2 root   root      64K Aug 14 12:55 lost+found
-rw-r--r-- 1 oracle oinstall 4.1G Aug 14 13:27 p39062956_190000_Linux-x86-64.zip

 

 

acfs는 현재 5gb인데 3gb로 줄이는 명령을 q 옵션을 주고 수행

1
2
$ acfsutil size 3G /acfs -q
acfsutil size: Resize request would cause 0.0015 TB of data to be moved.

1500mb 가량의 데이터를 옮겨야 size를 줄일수 있다고 나옴

 

 

이 내용을 무시하고 수행시 에러 발생함

1
2
$ acfsutil size 3G /acfs
acfsutil size: ACFS-03168: Internal error: Cannot find hostname 0

 

 

데이터 삭제 후 resize하면 정상적으로 동작함

1
2
3
$ rm /acfs/*
$ acfsutil size 3G /acfs
acfsutil size: new file system size: 3221225472 (3072MB)

 

 

결론 :
acfs 파일시스템 resize는 acfsutil size 명령을 사용해서 할수 있음
하지만 acfs 파일시스템을 만들기 전(advm 볼륨)이란면 asmcmd의 volresize 명령으로 크기를 증설하면됨

 

 

참조 : 

https://docs.oracle.com/en/database/oracle/oracle-database/19/ostmg/manage-acfs-advm-commands.html#GUID-79A8333D-4E1C-4788-944D-EC86E4278C00
https://docs.oracle.com/en/database/oracle/oracle-database/19/ostmg/manage-advm-asmcmd.html#GUID-E5762528-EEA2-4B7D-AE49-647A18CE31A9

오라클 19c ACFS 구성 테스트 ( https://positivemh.tistory.com/1388 )

오라클 19c ACFS 경로 변경 테스트 ( https://positivemh.tistory.com/1389 )

오라클 19c Restart 환경 hostname 변경 후 ACFS 문제 해결 ( https://positivemh.tistory.com/1435 )