RUNRMTCMD fatal error: handle is invalid

pts.
Tags:
AS/400
RUNRMTCMD
Hello, I am facing an issue while using the RUNRMTCMD command from iseries. I am trying to Zip a set of text files that are produced as output in the IFS directory. The IFS directory is mapped to the Win2000 machine. The command I am using to accomplish this is: RUNRMTCMD CMD('"C:WinzipWZZip.exe -a -P "C:Program FilesTestTest.zip" "C:Program FilesTest*.*""') RMTLOCNAME('xxx.xxx.xxx.xx' *IP) RMTUSER(XXXXXX) RMTPWD(XXXXXX) 

 When i execute this command, I am receiving an error message: 

FATAL ERROR: win32/windows system error (util.cpp@1305): The handle is invalid. 

 Program is terminating! The same command when executed using the RUN option in windows, works fine. Has anyone faced this issue before OR can anyone provide insights into why this issue is happening? Thanks,

Answer Wiki

Thanks. We'll let you know when a new response is added.

You may look at the profiles. In my experience the AS400 and the server user id/password must match. You may want to look that if you are dealing with multiple as400′s and servers you have a common userid/password in all of them and that the authority is the same.

Discuss This Question: 2  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • TheQuigs
    You don't have to use a PC to 'zip' the files at all. Try a command such as: STRQSH CMD('jar cfM Test.zip Test*.*') This would zip all files starting with 'Test' in the current users home directory to a zip file called "Test.zip". You can spedcify the full IFS path to the files to be archived and the name of the archive to be generated. If you want more details on the "jar" command, look for it on one of Sun's websites -- I don't have the URL's handy at this time. There was a good article written on MC Press Online at: http://www.mcpressonline.com/mc?1@202.sGp1cGbnIo7.2@.6aebf1ca
    0 pointsBadges:
    report
  • TomLiotta
    Since there has been no attempt to answer, maybe something can be dug up. The scenario doesn't make a lot of sense. Is this an actual attempted command or did you just put "C:\Program Files\Test*.*" as an example? What doesn't make sense is that it references a local PC directory that contains files from the IFS. The files would normally have been put there by the PC user, not the iSeries user. But now the attempt to zip them is from the iSeries user. Why would the PC user move the files but not also zip them? I would imagine that a test is being done. The directory was chosen just for the purpose of figuring out why RUNRMTCMD won't properly execute WZZip.exe regardless of the directories. The normal scenario would involve an attempt to run WZZip.exe against files in a mapped drive to the IFS. But if the mapping doesn't resolve in the process started by RUNRMTCMD, then file handles might be reported as invalid. Maybe. Where do you see the error? Tom
    125,585 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following