Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

Saving the contents of memory

&pagelevel(3)&pagelevel

A memory dump saves the contents of, for example, registers, real memory, address spaces or files at the time of an actual or suspected error. A dump is started either automatically by an error detection facility of the operating system or of the currently active program or explicitly by entering an appropriate command at the terminal or console. Depending on the seriousness or scope of the error which has occurred, a distinction is made in BS2000 between:

  • a full dump, which also terminates the operating system program, and

  • a partial dump, which does not terminate the operating system.

If the cause and effect of an error cannot be localized, and if an essential part of the operating system is affected, all main memory and background memory areas of BS2000 must be saved for diagnosis. Dumps of this sort are generated by the program SLED (Self-Loading Emergency Dump, see chapter “SLED dump”). SLED operates independently of BS2000.
Once a full dump has been generated, the operating system program is reloaded. It is possible to set up the system so that saving of the memory contents and restarting of the operating system are carried out automatically.

If the error can be narrowed down to a single task, only that part of the memory contents used by the task needs to be saved. If the error occurred in the user program, a partial dump therefore tends to cover solely the user address space of the errored task. However, if the error occurred in an operating system function and has no consequences for other tasks, then parts of the operating system address space are also saved.

Whereas the errored task is normally terminated by the error handling routine after a partial dump has been generated, the operating system and all other tasks continue to run both during and after output of the dump.

In BS2000, partial dumps (system, area or user dumps) can be created by means of the CDUMP2 macro (see chapter “CDUMP Output area, user or system dump”). CDUMP2 runs asynchronously, i.e. concurrently with other tasks under BS2000 control. The scope of the partial dump generated by way of CDUMP2 varies depending on the specified operands and on the privilege of the calling task.

SNAP dumps are a special form of partial dump (see chapter “SNAP dump”). SNAP saves the class 1 and class 3 memory of the operating system and the name and entry point lists of all operating system modules (EOLDTAB).

SNAP is called by the operating system from the status TPR or SIH. This generally happens when an unusual operating system state arises that is not serious enough to terminate the session. Following the call, SNAP automatically suspends BS2000 operation for a maximum of 24 seconds, generates a dump independently of BS2000, and then reactivates the operating system.