Saturday, 25 July 2026

What is a Job in AS400 (IBM i)? Jobs, Job Queues & Job Logs Explained

If you're new to AS400, or IBM i, you may have heard terms like jobs, batch jobs, job queues, subsystems, and job logs. But what exactly is a job, and how does IBM i actually process the work we perform?

We'll understand the basics of IBM i jobs and look at interactive jobs, batch jobs, job queues, subsystems, and job logs. We'll also take a look at commands like WRKACTJOB, WRKJOB, and SBMJOB.

What Is a Job in IBM i?

The simplest way to understand a job is:

A job is a unit of work that IBM i manages and processes.

When you log in to IBM i using a 5250 terminal, your interactive session is associated with a job. When you run commands or programs, that work is performed in the context of your job.

Similarly, when you submit a batch process, IBM i creates a job to handle that work.

A job has identifying information such as a job number, user name, and job name. For example:

123456/USER1/MYJOB

This information is useful when troubleshooting because it allows us to identify and investigate a specific job.

Interactive Jobs

An interactive job is generally associated with a user directly interacting with the IBM i system.

For example, when you connect to IBM i using a 5250 emulator and enter commands or work with an application, you are working through an interactive job.

Batch Jobs

A batch job performs work without requiring continuous interaction from a user.

Batch jobs are commonly used for tasks such as:

  • Nightly processing
  • Generating reports
  • Billing
  • Database updates
  • Large-scale data processing

The SBMJOB command can be used to submit work as a batch job.

For example:

SBMJOB CMD(CALL PGM(MYLIB/MYPGM))

The exact command depends on the program or task you want to run, but the basic idea is that the work is submitted for batch processing.

What Is a Job Queue?

When a batch job is submitted, it may not start running immediately.

The job may first be placed on a job queue, where it waits until it can be processed.

A simple way to think about this is:

Submit Job → Job Queue → Job Processing

So, if someone says, "My batch job isn't running," one of the first things to determine is whether the job is actually running or whether it is waiting on a job queue.

What Is a Subsystem?

A subsystem provides an environment where jobs are processed and managed.

IBM i systems can have subsystems for different types of workloads, including interactive and batch processing.

You may have heard of subsystems such as:

QINTER

and

QBATCH.

The exact configuration varies between IBM i systems, but the important thing to remember is that jobs are processed within subsystems.

WRKACTJOB

One of the most useful commands for viewing jobs is:

WRKACTJOB

This stands for Work with Active Jobs.

It displays information about active jobs on the system, including details such as the job name, user, job number, job type, status, and subsystem.

You may see interactive jobs, batch jobs, and various system jobs.

WRKACTJOB is particularly useful when investigating what's currently happening on an IBM i system.

WRKJOB

Another useful command is:

WRKJOB

This stands for Work with Job.

It allows you to investigate a particular job and access information related to it.

Depending on the available options, you can examine details such as the job status, job log, call stack, and other job-related information.

What Is a Job Log?

The job log is one of the most important tools for troubleshooting IBM i applications.

During the life of a job, IBM i and the applications running within that job can generate messages.

These messages may indicate problems such as:

  • An object that doesn't exist
  • A file that cannot be found
  • A decimal data error
  • An authority problem
  • A record lock
  • Other application or system errors

If a program fails, one of the first things you should do is identify the relevant job and check its job log.

The job log can often provide the information needed to understand what actually happened.

The Big Picture

A simple way to understand IBM i job processing is:

User → Job → Job Queue → Subsystem → Processing → Job Log

An interactive session runs through an interactive job. A batch process can be submitted as a batch job, which may wait on a job queue before being processed by a subsystem.

If something goes wrong, the job and its job log can provide valuable information for troubleshooting.