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
Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

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

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.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
as400 calendar 2 183
AS400 CPU allocation 3 117
Pointer not set for location referenced. 12 183
Excel 2016 Import Data Using Microsoft Query 6 138
This article was originally published on Monitis Blog, you can check it  here . If you have responsibility for software in production, I bet you’d like to know more about it. I don’t mean that you’d like an extra peek into the bowels of the sour…
Recently, Microsoft released a best-practice guide for securing Active Directory. It's a whopping 300+ pages long. Those of us tasked with securing our company’s databases and systems would, ideally, have time to devote to learning the ins and outs…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…
Finding and deleting duplicate (picture) files can be a time consuming task. My wife and I, our three kids and their families all share one dilemma: Managing our pictures. Between desktops, laptops, phones, tablets, and cameras; over the last decade…

726 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