Creating a volume group using mkvg -y trialvg xyz
works but
the same line represented like this mkvg -y $vg_name $dev_name
in a shell script
causes the following problem :
bash-4.0# ./execute_AIX.sh
Creating VG trialvg with device xyz
Executing Command: mkvg -y trialvg xyz
0519-100 libodm: Cannot open the object class collection file.
Check path name and permissions.
0516-307 mkvg: Unable to access Device Configuration
Database.
Creating VG: Failed

- 667
- 1
- 15
- 33
-
1Please edit your question and include the contents of ./execute_AIX.sh – Roman Cheplyaka Oct 22 '10 at 20:30
5 Answers
Somebody must have set the maxdata
environment variable. That causes this error.
This has something to do with the max #
of shared memory segment that a process can attach to (shmat problem).
So do export LDR_CNTRL=MAXDATA=0x80000000@DSA
and try again. It should work.
In maxdata=0x80000000 setting, only segment b and c will be available for shmat (after 8 segments are allocated for user heap) and one more shmat request will fail as segment e is already attached.

- 11
- 1
You may want to use set -x
in the script to see what commands get executed.

- 37,738
- 7
- 72
- 121
Your clue is in a portion of the error message: "Check path name and permissions."
There is something different between the environment of your script and your interactive environment. Two likely candidates are a missing shebang (or one that specifies a different shell) or a PATH
that differs. Without seeing the script it's difficult to guess.

- 346,391
- 90
- 374
- 439
Please check you ODMDIR environment variable (env |grep ODMDIR). This should point to "/etc/objrepos".

- 5,040
- 3
- 40
- 47