Tuesday, September 6, 2011

AIX Script for creating volume group and JFS2

AIX Script for creating volume group and JFS2

Though smit/smitty is a great tool for the purpose mentioned in the title still when you need to create a number of vgs' and mount points then scripting is helpful ... here is such a sample script which is nothing but a repeated commands ...(  * before this step physical storages should be presented to the server  * here I'm creating filesystem directly on vg, no LV ...)



==== ===
vg creation
========


mkvg -y vgoradata4 -S -v 1024 hdisk14
mkvg -y vgoradata5 -S -v 1024 hdisk15
mkvg -y vgoradata6 -S -v 1024 hdisk16
mkvg -y vgoradata7 -S -v 1024 hdisk17
mkvg -y vgoradata8 -S -v 1024 hdisk18
mkvg -y vgoradata9 -S -v 1024 hdisk19
mkvg -y vgoradata10 -S -v 1024 hdisk20

== ===

JFS 2 Creation

======


crfs -v jfs2 -g vgoradata3 -m /oradata3 -a size=195G
crfs -v jfs2 -g vgoradata4 -m /oradata4 -a size=195G
crfs -v jfs2 -g vgoradata5 -m /oradata5 -a size=195G
crfs -v jfs2 -g vgoradata6 -m /oradata6 -a size=195G
crfs -v jfs2 -g vgoradata7 -m /oradata7 -a size=195G
crfs -v jfs2 -g vgoradata8 -m /oradata8 -a size=195G
crfs -v jfs2 -g vgoradata9 -m /oradata9 -a size=195G
crfs -v jfs2 -g vgoradata10 -m /oradata10 -a size=195G
== ====

Mounting
=======

mount /oradata3
mount /oradata4
mount /oradata5
mount /oradata6
mount /oradata7
mount /oradata8
mount /oradata9
mount /oradata10


No comments:

Post a Comment