AS400 Error Trapping

Our companies currently run a very old application which is no longer supported by the company.  (Upgrading to the current version, even if available, not an option)

We are upgrading our AS400 OS to V6.  Almost all the functions in the application work correctly with the exception of two main ones.  When these options are requested the system locks and goes into never-never land forever.  No error message or indication of issues in the log.  I have tried to debug but we don't have the source and/or it was not compiled with the debug option.  

Does anyone have any suggestion which would help me to determine what is happening?

Thank You...
Who is Participating?
Dave FordConnect With a Mentor Software Developer / Database AdministratorCommented:
If you can't get an updated version of your program and you don't have a program listing, then I suppose the only thing you can do would be to inspect the job while it's running.

Using the WrkActJob command, you'd locate the offending job and get the details by entering a 5 to "Work with" that job. Hopefully, you have at least one AS/400-savvy operator or programmer to look at the various displays such as job log, call stack, locks, and spool files. Hopefully, that information will point you towards isolating the problem.

lynn_harrisAuthor Commented:
Wow... nice to know I'm incompetent.  

I check the things you indicated before asking....

There are no messages in joblog.  There are no files showing any IO count that would indicate a loop.  There is are no files with lock status wait.

I see the program running in the call stack and the object is cobol- *pgm type CBL.  I tried to put into debug with STRDBG... it does not come up.  It appears OPTION(*SRCDBG) or OPTION(*LSTDBG) where not used when compiled.  

We have object only from the vendor.  

Guess some question are to stupid to ask.....
Gary PattersonVP Technology / Senior Consultant Commented:
It isn't a stupid question.  But since you provided so little information, I suspect daveslash assumed you aren't very familiar with the AS/400, and is encouraging you to engage a resource that is knowledgable of basic "hung job" troubleshooting.

So can you share some details?  Even better, post some screen shots.

1) Look at the job in WRKACTJOB.  What is the Status?  Refresh a few times.  Is status changing?  If so, to what?

2) Is CPU utilization high or low for this job (what is it?)

3) What Function is shown?

4) Take option 5 and post the call stack.  I'd like to see what is running.  Refresh the call stack a few times.  Is it always about the same place?

5) Look at open files.  Are I/O counts moving?

Post back as much detailed info about the job as possible, and we'll be better able to help you.  There are a lot of things that can be happening, and without more information, it is just hard to narrow it down.

- Gary Patterson

Check out my EE profile:
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

Dave FordSoftware Developer / Database AdministratorCommented:
Gary is exactly right. Apparently incorrectly, I assumed you were more of a "business" type (as opposed to a "technical" type). I apologize for the insulting inference. It certainly wasn't intentional.
lynn_harrisAuthor Commented:
Hi.... First, Dave I apologize for be so short.  I really didn't provide enough information.  It was in my head, but I didn't communicate it.

Thank you both for responding.  I will provide more background and better information.  

All libraries are currently be converted and installed in the new environment.  The ones I was working with before where old and I want to illuminate that as a possible issue.  The upgrade was started a year ago and due to business requirement was put on the back burner.

From memory… the status of the job was display wait.  The io count was very low and not moving, no file had a status of lock wait, the program list does not change (but I will check more frequently to be sure), the session remains locked and must be cancelled to exit.  

I know I’m missing something and appreciate help looking at it.

I will provide screen prints of the job, as well as background information when the system is up.

Thank You.
lynn_harrisAuthor Commented:
also, cpu usage low and remains low.
Gary PattersonVP Technology / Senior Consultant Commented:
There are a lot of options here.

For example, we recently did a source code recovery project for a client that had lost the source code to several applications.  Source code recovery is not always possible, but it could be an option for you.

But if the application migrated properly over the years, there is a good chance it is "runnable" if we can just find the reason that it is hanging.    

Is the problem program OPM COBOL or ILE COBOL?

- Gary Patterson
lynn_harrisAuthor Commented:
I will have to look when the system is backup.  Still restoring and converting.  More tomorrow.  

...… the status of the job was display wait.
That would be confusing. If that's the status, then the job isn't hung or locked up; it's just waiting for someone to press <Enter> or some other function key before it continues.

Check the job locks to see what display device is allocated to the job.

lynn_harrisAuthor Commented:
True Tom .... Once libraries and data brought over again I will double check.  It doesn't make sense. I will get screen prints and get accurate info posted.  Thank you.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.