使用ASMACFS文件系统
ACFS是oracle提供的基于ASM的共享文件系统,在11.2版本之上才能使用。可以在安装oracle asm软件的主机上用作共享文件系统,存放归档日志,本地的rman备份等,比单纯放在ASM中更直观,可以使用os上的命令进行检查和操作。下面是简单的用法
1,create DG
2,修改版本,有时候虽然数据库的安装版本是11.2,一些参数版本不是,安装前请检查
3,如果已有DG,可省略
4,挂载文件系统
如果是rac其它主机也可以看到该文件系统了
6,扩acfs文件系统,resize 大小
7,修改DB_RECOVERY_FILE_DEST_SIZE到acfs上
参考文档
How To Resize An ACFS Filesystem/ASM Volume (ADVM) [ID 1173978.1]
How To Create A New ACFS Volume & Filesystem And Set The ACFS Filesystem Ownership To A Non-Grid/Oracle OS User? [ID 1322383.1]
http://docs.oracle.com/cd/E18283_01/server.112/e16102/asmfs_util001.htm#BABGBDFH
附录:
Deregister the file system with acfsutil registry -d.
For example:
$ /sbin/acfsutil registry -d /oracle/acfsmounts/acfs1
acfsutil registry: successfully removed ACFS mount point
/oracle/acfsmounts/acfs1 from Oracle Registry
For information about running acfsutil registry, see "acfsutil registry".
Dismount the file system.
For example:
# /bin/umount /oracle/acfsmounts/acfs1
You must dismount the file system on all nodes of a cluster.
Use umount on Linux systems or acfsdismount on Windows systems. For information about running umount or acfsdismount, see "umount" or "acfsdismount".
Remove the file system with acfsutil rmfs.
If you were not planning to remove the volume in a later step, this step is necessary to remove the file system. Otherwise, the file system is removed when the volume is deleted.
For example:
$ /sbin/acfsutil rmfs /dev/asm/volume1-123
For information about running acfsutil rmfs, see "acfsutil rmfs".
Optionally you can disable the volume with the ASMCMD voldisable command.
For example:
ASMCMD> voldisable -G data volume1
For information about running voldisable, see "voldisable".
Delete the volume with the ASMCMD voldelete command.
For example:
ASMCMD> voldelete -G data volume1
For information about running voldelete, see "voldelete".
In this Document
Symptoms
Changes
Cause
Solution
References
Applies to:
Oracle Server - Enterprise Edition - Version 11.2.0.2 and later
Information in this document applies to any platform.
Symptoms
ora.registry.acfs show offline and will not auto start
it is started on other node
Changes
restart of cluster
Cause
ACFS driver did not start on this node
Solution
manually start it using:
a) Start the ACFS driver manually
${GRID_HOME}/bin/acfsload start -s
b) Enable Volume in ASM instance.
ALTER DISKGROUP ENABLE VOLUME ;
( which you have created for ACFS/third party file system)
c) Mount volume as root
use your path in below example
mount -t acfs -rw /dev/asm/acfs01_db1-432 /oracle/bkup01
d) View filesystems as root
acfsutil info fs
1,create DG
SQL> CREATE DISKGROUP ACFSDG EXTERNAL REDUNDANCY DISK 'ORCL:ASMDISK8' SIZE 4157 M DISK 'ORCL:ASMDISK9' SIZE 4157 MATTRIBUTE 'compatible.asm' = '11.2', 'compatible.advm' = '11.2';
2,修改版本,有时候虽然数据库的安装版本是11.2,一些参数版本不是,安装前请检查
alter diskgroup FRA set attribute 'COMPATIBLE.ASM'='11.2';alter diskgroup FRA set attribute 'compatible.advm'='11.2'
3,如果已有DG,可省略
SQL> ALTER DISKGROUP FRA ADD VOLUME ACFSARCVOL SIZE 100G;Diskgroup altered.ASMCMD> volinfo -aDiskgroup Name: FRA Volume Name: ACFSARCVOL Volume Device: /dev/asm/acfsarcvol-306 State: ENABLED Size (MB): 102400 Resize Unit (MB): 256 Redundancy: UNPROT Stripe Columns: 4 Stripe Width (K): 128 Usage: Mountpath:
4,挂载文件系统
su - rootmkidr -p /archive chown oracle:oinstall /archive/sbin/mkfs -t acfs -b 4k /dev/asm/acfsarcvol-306[root@dtydb3 ~]# /sbin/mkfs -t acfs -b 4k /dev/asm/acfsarcvol-306mkfs.acfs: version = 11.2.0.2.0mkfs.acfs: on-disk version = 39.0mkfs.acfs: volume = /dev/asm/acfsarcvol-306mkfs.acfs: volume size = 107374182400mkfs.acfs: Format complete.[root@dtydb3 ~]# /sbin/acfsutil registry -f -a /dev/asm/acfsarcvol-306 /archiveacfsutil registry: mount point /archive successfully added to Oracle Registry[root@dtydb3 ~]#[root@dtydb3 ~]# /sbin/mount.acfs -o all[root@dtydb3 ~]# df -h/dev/asm/acfsarcvol-306 100G 304M 100G 1% /archive
5, 再一次查看信息
ASMCMD> volinfo -aDiskgroup Name: FRA Volume Name: ACFSARCVOL Volume Device: /dev/asm/acfsarcvol-306 State: ENABLED Size (MB): 102400 Resize Unit (MB): 256 Redundancy: UNPROT Stripe Columns: 4 Stripe Width (K): 128 Usage: ACFS Mountpath: /archive
如果是rac其它主机也可以看到该文件系统了
6,扩acfs文件系统,resize 大小
su - grid[grid@dtydb4 ~]$ /sbin/acfsutil size 110G /archiveacfsutil size: new file system size: 118111600640 (112640MB)[grid@dtydb4 ~]$ df -h /archiveFilesystem Size Used Avail Use% Mounted on/dev/asm/acfsarcvol-306 110G 3.5G 107G 4% /archive
7,修改DB_RECOVERY_FILE_DEST_SIZE到acfs上
SQL> ALTER SYSTEM SET DB_RECOVERY_FILE_DEST_SIZE = 10G SCOPE=BOTH SID='*';SQL> ALTER SYSTEM SET DB_RECOVERY_FILE_DEST = '/backup/flash_recovery_area' SCOPE=BOTH SID='*';如果不使用acfs,而是默认备份到ASM磁盘组FRA中,使用如下命令SQL> ALTER SYSTEM SET DB_RECOVERY_FILE_DEST = '+FRA' SCOPE=BOTH SID='*';
参考文档
How To Resize An ACFS Filesystem/ASM Volume (ADVM) [ID 1173978.1]
How To Create A New ACFS Volume & Filesystem And Set The ACFS Filesystem Ownership To A Non-Grid/Oracle OS User? [ID 1322383.1]
http://docs.oracle.com/cd/E18283_01/server.112/e16102/asmfs_util001.htm#BABGBDFH
附录:
1)删除acfs,官方的文档,可以参考下
To permanently remove a volume and Oracle ACFS file system, perform the following steps. These steps destroy the data in the file system.Deregister the file system with acfsutil registry -d.
For example:
$ /sbin/acfsutil registry -d /oracle/acfsmounts/acfs1
acfsutil registry: successfully removed ACFS mount point
/oracle/acfsmounts/acfs1 from Oracle Registry
For information about running acfsutil registry, see "acfsutil registry".
Dismount the file system.
For example:
# /bin/umount /oracle/acfsmounts/acfs1
You must dismount the file system on all nodes of a cluster.
Use umount on Linux systems or acfsdismount on Windows systems. For information about running umount or acfsdismount, see "umount" or "acfsdismount".
Remove the file system with acfsutil rmfs.
If you were not planning to remove the volume in a later step, this step is necessary to remove the file system. Otherwise, the file system is removed when the volume is deleted.
For example:
$ /sbin/acfsutil rmfs /dev/asm/volume1-123
For information about running acfsutil rmfs, see "acfsutil rmfs".
Optionally you can disable the volume with the ASMCMD voldisable command.
For example:
ASMCMD> voldisable -G data volume1
For information about running voldisable, see "voldisable".
Delete the volume with the ASMCMD voldelete command.
For example:
ASMCMD> voldelete -G data volume1
For information about running voldelete, see "voldelete".
2)如何手工启动acfs
In this Document
Symptoms
Changes
Cause
Solution
References
Applies to:
Oracle Server - Enterprise Edition - Version 11.2.0.2 and later
Information in this document applies to any platform.
Symptoms
ora.registry.acfs show offline and will not auto start
it is started on other node
Changes
restart of cluster
Cause
ACFS driver did not start on this node
Solution
manually start it using:
a) Start the ACFS driver manually
${GRID_HOME}/bin/acfsload start -s
b) Enable Volume in ASM instance.
ALTER DISKGROUP ENABLE VOLUME ;
( which you have created for ACFS/third party file system)
c) Mount volume as root
use your path in below example
mount -t acfs -rw /dev/asm/acfs01_db1-432 /oracle/bkup01
d) View filesystems as root
acfsutil info fs
>更多相关文章
- 11-06Hadoop是目前大数据领域最主流的一套技术体系
- 11-06大数据和人工智能:三个真实世界的用例
- 11-06为什么说,大数据与行业专家是“共生”关系?
- 11-06Python数据可视化:箱线图多种库画法
- 11-06这种思路讲解HDFS你肯定没见过?快速入门Hadoop必备
- 11-06媲美Pandas的数据分析工具包Datatable
首页推荐
佛山市东联科技有限公司一直秉承“一切以用户价值为依归
- 01-11全球最受赞誉公司揭晓:苹果连续九年第一
- 12-09罗伯特·莫里斯:让黑客真正变黑
- 12-09谁闯入了中国网络?揭秘美国绝密黑客小组TA
- 12-09警示:iOS6 惊现“闪退”BUG
- 12-05亚马逊推出新一代基础模型 任意模态生成大模
- 12-05OpenAI拓展欧洲业务 将在苏黎世设立办公室
- 12-05微软质疑美国联邦贸易委员会泄露信息 督促其
- 12-05联交所取消宝宝树上市地位 宝宝树:不会对公
- 12-04企业微信致歉:文档打开异常已完成修复
相关文章
24小时热门资讯
24小时回复排行
热门推荐
最新资讯
操作系统
黑客防御