July 8

0 comments

IFS File system error occurred. Error number 3021?

By NickLitten

July 8, 2019

CPYFRMIMPF, IBM i OS, IFS

Some of IBM’s error messages are more cryptic than others. Copying files from the IFS using CPYFRMIMPF sometimes spits out error messages which are less than clear:

CPYFRMIMPF FRMSTMF('/FOLDER/FOLDER/FILE') TOFILE(*LIBL/FILENAME) MBROPT(REPLACE) RCDDLM(LF) STRDLM(NONE) RMVBLANK(NONE)FLDDLM(TAB) ERRRCDOPT(REPLACE) RPLNULLVAL(FLDDFT)
File system error occurred. Error number 3021
Copy command ended because of error.

Internet Search for CPYFRMIMPF 3021 shows nothing!

How to find CPYFRMIMPF error codes?

Lookup the related CPE error message: DSPMSGD CPExxxx

so, in this case, 3021 means

DSPMSGD CPE3021
Ifs file system error occurred. Error number 3021? 1
DSPMSGD RANGE(CPE3021) MSGF(QCPFMSG)

In this case the ‘value specified for the argument is not correct‘ is telling us that the FRMSTMF value is incorrect, or file is not found.

Fix the FRMSTMF file name or add some error checking to your program code.

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

Join the IBM i Community for FREE Presentations, Lessons, Hints and Tips

>