Link to home
Start Free TrialLog in
Avatar of g0all
g0allFlag for Saint Pierre and Miquelon

asked on

AIX : Create file system on a existing LV?

Hi,

I'm having a raw lv, lv_test.
Can somebody tell me how to create a file system on that  LV so I'll be able to mount it?

Thanks!
Avatar of woolmilkporc
woolmilkporc
Flag of Germany image

OK,

here's somebody to tell you.

crfs -v jfs2 -d lv_test -m /mount/point -A yes
mount /mount/point

Replace /mount/point with the actually desired mountpoint. No need to create it beforehand, crfs will do it for you.

Note that there should be a jfs2 log volume available in the VG.
Check with "lsvg -l vgname |grep log"

If there isn't we will either have to create one or we must specify as an additional parameter "-a logname=INLINE" to configure inline logging for this FS.

"-A yes" means automatic mounting at system restart.

wmp
Avatar of g0all

ASKER

Hi wmp,

Thank you, but I'm doing something wrong, not sure what:

 crfs -v jfs2 -d lv_test -m /test2 -A yes
crfs: 0506-947 lv_test: logical volume must be type jfs2.
Usage: crfs -v Vfs {-g Volumegroup | -d Device} -m Mountpoint
        [-u Mountgroup] [-A {yes|no}] [-t {yes|no}] [-p {ro|rw}]
        [-l Logpartitions] [-n nodename] [-a Attribute=Value]


lslv lv_test
LOGICAL VOLUME:     lv_test                VOLUME GROUP:   rootvg
LV IDENTIFIER:      00d5bb3200004e0000000130e0f804c8.13 PERMISSION:     read/write
VG STATE:           active/complete        LV STATE:       closed/syncd
TYPE:               raw                    WRITE VERIFY:   off
MAX LPs:            512                    PP SIZE:        64 megabyte(s)
COPIES:             1                      SCHED POLICY:   parallel
LPs:                1                      PPs:            1
STALE PPs:          0                      BB POLICY:      relocatable
INTER-POLICY:       minimum                RELOCATABLE:    yes
INTRA-POLICY:       middle                 UPPER BOUND:    32
MOUNT POINT:        N/A                    LABEL:          None
MIRROR WRITE CONSISTENCY: on/ACTIVE
EACH LP COPY ON A SEPARATE PV ?: yes
Serialize IO ?:     NO
ASKER CERTIFIED SOLUTION
Avatar of woolmilkporc
woolmilkporc
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of g0all

ASKER

So the order is:

chlv -t jfs2 lv_test

 crfs -v jfs2 -d lv_test -m /test2 -A yes

?

Regarding the log:

lsvg -l rootvg |grep log
hd8                 jfs2log    1       1       1    open/syncd    N/A

Is that fine?
OK, correct. And the log is present, that's perfect.
Avatar of g0all

ASKER

Perfect!
Avatar of g0all

ASKER

Short question: that log is related to LV or to VG?
You can configure one single log for all LVs in the VG, one log per LV, or several logs each one for a subset of the LVs in the VG.
If there is only one log in the VG "crfs" assumes this one as the default log and uses it automatically.

The log and its FS must be in the same VG, however. No "cross-VG" logging!

Thx for the points!
Avatar of g0all

ASKER

Thank you so much!!!!!!!!!!!!!!!!!!!!!!