Subscribe to Posts by Email

Subscriber Count

    699

Disclaimer

All information is offered in good faith and in the hope that it may be of use for educational purpose and for Database community purpose, but is not guaranteed to be correct, up to date or suitable for any particular purpose. db.geeksinsight.com accepts no liability in respect of this information or its use. This site is independent of and does not represent Oracle Corporation in any way. Oracle does not officially sponsor, approve, or endorse this site or its content and if notify any such I am happy to remove. Product and company names mentioned in this website may be the trademarks of their respective owners and published here for informational purpose only. This is my personal blog. The views expressed on these pages are mine and learnt from other blogs and bloggers and to enhance and support the DBA community and this web blog does not represent the thoughts, intentions, plans or strategies of my current employer nor the Oracle and its affiliates or any other companies. And this website does not offer or take profit for providing these content and this is purely non-profit and for educational purpose only. If you see any issues with Content and copy write issues, I am happy to remove if you notify me. Contact Geek DBA Team, via geeksinsights@gmail.com

Pages

ASM: ACFS Filesystem , practiced and explained.

Background:- According to documentation here

A lot more on that part in documentation,

  • How about creating a database home on the ASM Diskgroups?
  • How about using my asm diskgroups to store my backups or any other generic files?
  • How about using my asm diskgroup as cluster filesystem like vxfs

Well the answer is ACFS!!!! Read on…

The acfs filesystem is capable of providing the generic or cluster filesystem capabilities like VCFS etc.

It supports to generic files like Oracle Homes or any other journling filesystem capabilities, remember without this only database related files are managed in the diskgroups in ASM, that restriction is lifted with help of ACFS.

What you need?

1) ADVM – ASM Dynamic Volume Manager (the module that provides by Oracle Grid infrastructure now, acfs* executables in the $GI_HOME)

“acfsload” – to start and stop the drivers

“advmutil” – to display ASM dynamic volume details

“acfsutil” – to register and unregister acfs mount points, display the “registry” contents, display acfs file system metadata and create and remove acfs snapshots.

“asmcmd” – to create and delete asm dynamic volumes, display volume metadata, list disk groups anddisplay volume statistics

2) ASMLib – ASM Library, ASM Support lib and ASM Drivers from oracle site.

3) ASM Instance

What you will learn today?

We will use ACFS filesystem as my Oracle Home, this ACFS filesystem is mounted by ASM diskgroups, facilitated by ASM Volumes, volumes created on the disk partitions added in the asm registry.

The high level steps will be:-

1) Load the ACFS driver into kernel

2) Create partitions (but do not journal them) for the newly added disks

3) Provision the partitions with ASM Lib i.e creating asm disks

4) Use ASMCA to configure the Volumes and ACFS filesystem

The asmca broadly does the following, Just in case if you want to do the same in asmcmd

1) executes volcreate

2) execute volenable

3) execute mkdg to create a diskgroup based on the volume created in step 1

4) execute mount diskgroup

5) Add the entries in fstab with acfs filesystem

6) Mount the acfsfilesystem

 

Let’s Practice

Step1 : Load the acfs into kernel

(assuming you have Grid Home installed and asm is running and ASM lib is loaded)

Manually load the modules required for ACFS, with the command:

/u01/app/grid/product/11.2.0/grid/bin/acfsload start -s

 

Step2: Create Partitions

Two new disks on my server, lets utilize those, fdisk –l reveals the same.

clip_image002

Create a partition layout in those two /dev/sdd, /dev/sde disks

clip_image002[5]

Note:- You need to create a partitions on disk before using and recognised by ASM as a provisioned disk

 

Step3: Provision the disks with ASM libraries.

clip_image002[7]

You can see that I have the ACFSDISK1 and ACFSDISK2 as my asm provisioned disks, DBDATA and DBHOME also.

Step 4: Use ASMCA , to add this acfs disks to my ASM instances as volumes, for that First you need to create diskgroups

a) Click on Diskgroup tab & create.

 clip_image002[9]

b) Provide the Diskgroup Name as ACFS

clip_image002[11]

c) See, the diskgroup ACFS, DBDATA, DBHOME has been created.(the DBHOME and DBDATA is created earlier, not to be confused, please)

clip_image002[13]

Now create a mount point clusterfilesystem/Volumes. Click on cluster filesystem tab and select create volume.

clip_image002[15]

d) Provide the acfs Volume name, etc and also you will see two sections, the volume you are creating is for Database Home or generic filesystem etc.

clip_image002[19]

 

e)clip_image002[21]

clip_image002[23]

Now your Diskgroup created,acfs volume created and mounted and registered for next reboot. Lets check in OS.

5) Add entries in /etc/fstab for persistent mount of volumes during the reboots.

image

Note: Observe the filesystem mount type acfs for the line /dev/asm/* stuff , its acfs, for normal it will be ext3,

6) Mount them.

Before ACFS snap:-

clip_image002[27]

After ACFS creation snap:-

clip_image002[25]

I had now, /u02/acfstest as my generic filesystem and the /u02/app/oracle/product/11.2.0/db_1 as the database home (this has created as dbhome earlier on acfs only)

Below table is for your understanding more on this,

image

Troubleshooting:-

Sometimes the acfs volumes does not mount when the reboot happens, you may need to rely on the command line using asmcmd.

Case:- ACFS Volumes does not mount after reboot

1) Verify the asm driver and advm is loaded and running

The screenshot says advm is not running.

clip_image002[29]

2) Start ADVM,

Go to Oracle Grid Home and then use acfsload start –s,

observe the advm is now loaded into kernel

clip_image002[31]

 

3) Check the volume now in asmcmd, if not enabled let enable with volenable command

clip_image002[33]

Its disabled …..

4) Lets enable it… When you enable the volume the underlying diskgroup will be mounted automatically here in this case DBHOME

clip_image002[35]

Observe the mountpath, the volume device etc, same entries as like in fstab

5) Check in OS, my sqlplus is not available, as at OS level the volume is not mounted.

clip_image002[37]

 

6) Either keeping the following lines in fstab or using mount –t with acfs filessytem will help now

/dev/asm/dbhome-314 /u02/app/oracle/product/11.2.0/db_1 acfs

or

/bin/mount –t acfs /dev/asm/dbhome-314 /u02/app/oracle/product/11.2.0/db_1

 

7) Verify the mounts at OS level now, my DB HOME back again, you can sqlplus and your database binaries now.

image 

Not that too complex, but one must know about the storage and the basic unix administration in order to get along with this.

-Thanks

Geek DBA

4 comments to ASM: ACFS Filesystem , practiced and explained.

  • […] in previous post, we have two disks one utilized for /u04/acfstest which is 1.8gb, now am going to add another disk […]

  • […] in previous post, we have two disks one utilized for /u04/acfstest which is 1.8gb, now am going to add another disk […]

  • Taufique

    We have Oracle GoldenGate installed and configured on ACFS in 2 node Oracle RAC. Now, we have an activity of storage migration which required to change whole storage including GI Home, Oracle Home and GG Home (ACFS).

    What should be the approach to migrate storage of ACFS of Oracle GoldenGate.

    Regards,

    • Geek DBA

      Hi

      Sorry for not being prompt as I was busy.

      You are talking about storage migration. And I believe you use ASM as you mentioned ACFS.

      ACFS or OCR/Voting Disk are managed via ASM Diskgroups

      So in that case, you just need to create new disks to the existing groups for OCR/ACFS and then rebalance will automatically take place. Once rebalance operations complete, delete the existing disks then another rebalance operations kicks off.

      I said disks not the diskgroups.

      -Thanks
      Suresh