Every OPatch experience is different and from time to time applying a patch fails for varying reasons. Today I wanted to patch an Oracle Database 18c home. During the apply process, OPatch complained about a missing shrept.lst file.
The target was to update an existing Oracle 18c installation from release update 18.5 to 18.6. It was already successfully updated this year. After that nothing changed (really!).
So I called OPatch and during the relinking phase, the following error was raised.
Patching component oracle.has.common.cvu, 126.96.36.199.0... Make failed to invoke "/usr/bin/make -f ins_net_client.mk client_sharedlib ORACLE_HOME=/u00/app/oracle/product/18"....'genclntsh: genclntsh: Could not locate /u00/app/oracle/product/18/network/admin/shrept.lst make: *** [client_sharedlib] Error 1 ' Make failed to invoke "/usr/bin/make -f ins_rdbms.mk client_sharedlib ORACLE_HOME=/u00/app/oracle/product/18"....'genclntsh: genclntsh: Could not locate /u00/app/oracle/product/18/network/admin/shrept.lst make: *** [client_sharedlib] Error 1 ' The following make actions have failed : Re-link fails on target "client_sharedlib".
Indeed, the $ORACLE_HOME/network/admin/shrept.lst was missing. I checked similar systems and the file was there. So it looks like that someone or something deleted the file and without this file relinking will fail.
If you have other similar Oracle installations with the same release and architecture, you can just copy the file from there. Another solution would be to copy the file from the downloaded installation media to the existing Oracle home.
In previous releases, this file was created by a Java JAR file. If you face this error in a previous release, have a look at the My Oracle Support Note “genclntsh: Could not locate $ORACLE_HOME/network/admin/shrept.lst” (Doc ID 340978.1).
For the case that the file is there, check that the permissions are set to 644.
$> cd $ORACLE_HOME/network/admin $> ls -l shrept.lst -rw-r--r--. 1 oracle oinstall 1441 May 22 10:13 shrept.lst