Coder Social home page Coder Social logo

rolandstrauss / as400tail Goto Github PK

View Code? Open in Web Editor NEW

This project forked from projectvulcan/as400tail

0.0 0.0 0.0 455 KB

File monitoring utility on 5250 for AS/400 designed to behave like Unix tail command for PF-DTA.

License: MIT License

C 100.00%

as400tail's Introduction

AS400 File Monitoring Utility

Monitors a physical file like Unix tail command. Auto refresh the display and show new records.

Introduction

This tool was written out of frustration when required to repeatedly hit Enter key on DSPPFM command while monitoring log files (PF-DTA) for incoming transactions. I wrote this for me but I hope it will benefit you too.

How to Compile

First, upload the source to your AS/400 using FTP or other similar means, then set the correct source type for each member:

  1. PVFMONUSR RPGLE
  2. PVFMONUSU C
  3. PVFMONUSD DSPF

Compile the DSPF first using option 14. Then the RPGLE and C using option 15. Finally, issue CRTPGM PGM(PVFMONUSR) MODULE(PVFMONUSR PVFMONUSU). If you run into any difficulties with the source code, please verify that:

  1. The source physical file ('PF') is at least 112 in length, for example, CRTSRCPF FILE(QRPGLESRC) RCDLEN(112).
  2. The code page of the PF and your job is 37, for example, CHGJOB CCSID(37).
  3. The FTP mode of transfer was set to ASCII during upload.

Running the Program

CALL PVFMONUSR.

This is an image

Enter the file, library and member of the PF-DTA you wish to monitor. Press Enter. If your LIB/FILE,MBR path is valid, the screen will load and the navigation keys are displayed at the bottom of the display.

This is an image

When new entries are written to the monitored file, the display will refresh and highlight those new entries. Counter and timer at bottom right of the screen shows how many records were read in the last refresh and how long it's been since new entries were found. You can navigate left/right (like DSPPFM) if your records are longer.

Additional Notes

You will require ILE C compiler in addition to RPG and DDS. The program will always read last record entry, so if your file is not sequential or if your PF make use of REUSEDLT, then this program is not for you. Program was written in Free-Format RPG.

as400tail's People

Contributors

projectvulcan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.