NFS Mount 16+ group Issue in AIX

Hi,
I am trying to read files from NFS mount. The ID with which I am trying to read is part of 16+ groups.

This is causing problem in doing change directory to the NFS mount directory.

I was able to get some code which does newgrp to change the default group so that I could change directories into NFS mount.
But as per the man pages of "newgrp". Looks like newgrp command invokes new shell everytime when it is called.
I am calling newgrp command as part of my korn shell. I would like to know, if calling it will impact my rest of the shell.
Looks like I could handle this issue by using here document.
But not sure if this is the right way. I have read other documentation to handle this NFS mount 16+ group situation but nothing seems to be helpful in my case (and not easy to understand documentation)
Help is appreciated.

 
/usr/bin/newgrp group1 << newgrp1
echo "Changing directory to /nfsmount/abc" 
cd /nfs/abc
 
/usr/bin/newgrp group2
cd /nfs/abc/def
 
cp /nfs/abc/def/test.txt /landingarea/app
if [ $? -eq 0 ];
then
   echo "copy successfull"
else
   echo "copy failed
fi
newgrp1

I think you need <<newgrp1 not << newgrp1 but your idea is sound, yes.

Be sure to escape $'s with \ since they will substitue before the code is run otherwise.

Could you please explain how this thing will work technically without invoking new shell.

I cannot, because it will invoke a new shell. You can't avoid that.

I don't think that will be a problem though.