Posted on 2013-10-29
Last Modified: 2014-01-10
One of our developers is attempting to use GMAKE in QP2TERM. He is getting a permissions error:

/QOpenSys/usr/bin/-sh: gmake: 0403-006 Execute permission denied

I attempted to do a chmod 777 /QIBM/ProdData/DeveloperTools/qsh/bin/gmake

When I do this, I get the following error:

0481-014 chmod: not all requested changes were made to gmake

I tried to "cd" to the directory with GMAKE in it, but that hasn't helped.

Any ideas?
Question by:Matthew Roessner
  • 3
  • 2
  • 2
  • +1
LVL 16

Expert Comment

by:theo kouwenhoven
ID: 39609105
Go to a as/400 (iSeries) Green screen and use the WRKAUT command :-)
LVL 35

Expert Comment

by:Gary Patterson
ID: 39609360
cd to folder containing gmake
ls -l

Post results.

Author Comment

by:Matthew Roessner
ID: 39609400
lrwxrwxrwx    1 qsys     0                54 Oct 14 07:35 del -> /QSYS.LIB/QAPTL.LIB/DEL.PGM                
-rwx---r-x    1 qsys     0              2377 Aug 31 2007  edtstmf                                          
-rwx---r-x    1 qsys     0              2771 Aug 31 2007  ez                                                
-rwx---r-x    1 qsys     0              2769 Aug 31 2007  ezmrg                                            
lrwxrwxrwx    1 qsys     0                56 Oct 14 07:35 flex -> /QSYS.LIB/QAPTL.LIB/FLEX.PGM              
lrwxrwxrwx    1 qsys     0                56 Oct 14 07:35 gawk -> /QSYS.LIB/QAPTL.LIB/GAWK.PGM              
lrwxrwxrwx    1 qsys     0                58 Oct 14 07:35 gmake -> /QSYS.LIB/QAPTL.LIB/GMAKE.PGM            
lrwxrwxrwx    1 qsys     0                56 Oct 14 07:35 gzip -> /QSYS.LIB/QAPTL.LIB/GZIP.PGM              
lrwxrwxrwx    1 qsys     0                54 Oct 14 07:35 icc -> /QSYS.LIB/QAPTL.LIB/ICC.PGM                
lrwxrwxrwx    1 qsys     0                52 Oct 14 07:35 ld -> /QSYS.LIB/QAPTL.LIB/LD.PGM                  
lrwxrwxrwx    1 qsys     0                68 Oct 14 07:35 makedepend -> /QSYS.LIB/QAPTL.LIB/MAKEDEPEND.PGM  
-rwx---r-x    1 qsys     0              2442 Aug 31 2007  mred                                              
-rwx---r-x    1 qsys     0              2370 Aug 31 2007  mrhex                                            
lrwxrwxrwx    1 qsys     0                52 Oct 14 07:35 ps -> /QSYS.LIB/QAPTL.LIB/PS.PGM                  
lrwxrwxrwx    1 qsys     0                54 Oct 14 07:35 qar -> /QSYS.LIB/QAPTL.LIB/QAR.PGM                
-rwx---r-x    1 qsys     0              2375 Aug 31 2007  review
Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

LVL 35

Expert Comment

by:Gary Patterson
ID: 39609565
lrwxrwxrwx    1 qsys     0                58 Oct 14 07:35 gmake -> /QSYS.LIB/QAPTL.LIB/GMAKE.PGM        

This means that "gmake" is a symbolic link to the native *PGM object QAPTL/GMAKE.  

So in addition to having the correct Posix rights to the gmake link, you'll probably also need to make sure your developer has adequate rights to the program object (using EDTOBJAUT, for example) in order to execute it.
LVL 27

Expert Comment

ID: 39613392
Normally, QAPTL/GMAKE should have *PUBLIC *USE. Library QAPTL would be the same.

Has this developer had success before doing related work in PASE? The problem isn't necessarily with permissions for gmake itself. Can you show the exact statements that result in the error?


Author Comment

by:Matthew Roessner
ID: 39616428
Our developers haven't done much in PASE before, so this is uncharted territory...  I will check with the developer and will see if I can get the exact statements he is executing...

Author Comment

by:Matthew Roessner
ID: 39625308
Our developer is essentially trying to do the following, just as an example:

From within QP2Term:

export PATH=/QIBM/ProdData/DeveloperTools/qsh/bin:/usr/bin:$PATH

Then run the following:

gmake -v

When he runs this command, he gets the following error:

/QOpenSys/usr/bin/-sh: gmake: 0403-006 Execute permission denied.
LVL 27

Accepted Solution

tliotta earned 500 total points
ID: 39646757
For the 0403-006 error, there are two general possibilities.

First, it could be an issue with the object being accessed, i.e., the gmake object itself. And the issue could be anywhere along the path as it resolves, i.e., either along the path to the symbolic link or the path to the resolved object.

And second, the issue could be with the shell that is invoked to execute the object. In this case, the shell should be referenced through /QOpenSys/usr/bin/sh. That is another symbolic link that shows on my system as:


Open in new window

So far, it all covers at least four different paths -- the two that I just mentioned above plus /QSYS.LIB/QAPTL.LIB/GMAKE.PGM  and /QIBM/ProdData/DeveloperTools/qsh/bin/gmake. Two of the four are for the symbolic links.

I hadn't looked at the path to the sh shell before. It seems odd to me that it starts with "../.." redirection instead of simply starting with the absolute '/QIBM' node. By starting with "../..", the resolution to the absolute path would seem to begin at some 'current' directory point that would have to be two levels below /root in the IFS. The resolution goes up two levels, then attempts to go down into /QIBM.

That last paragraph might be irrelevant, but it might be meaningful.


Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Is your phone running out of space to hold pictures?  This article will show you quick tips on how to solve this problem.
The business world is becoming increasingly integrated with tech. It’s not just for a select few anymore — but what about if you have a small business? It may be easier than you think to integrate technology into your small business, and it’s likely…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question