Certifications: No rescue for 3000s
HP Certified Pro outsourcing

MPE shell expands, with explanation

Way back in the middle 1990s HP added the Posix shell to the HP 3000, so customers who had Unix and MPE running in the same shop could train operators and managers with a single set of commands. Posix was a plus, making the 3000 appear more Unix-like (which seemed important at the time).

Over the years, however, Posix has been a feature to be discovered for most 3000 managers and operators. (By the way, the computer's operating system was renamed from MPE/XL to MPE/iX just for this added Posix feature).

But enough history; Posix is still on the 3000 and remains a powerful interface tool, an alternative to the CI interface that HP created for the system. You can even call Posix commands from the CI, a nifty piece of engineering when it can be done. That's not always possible, though. A customer wanted to know how to "expand wildcard shells" using Posix. He tried from the CI and had this story to relate.

:LL /BACKUPS/HARTLYNE/S*
ls: File or directory “/BACKUPS/HARTLYNE/S*” is not found

So how do I do this? I need to be able to tell tar to archive all of the reels of a STD STORE set via a regexp.  It does not work in tar, and it apparently does not in ls, so I speculate that there is something special about the innovation of Posix utilities from the CI that I am not aware of. What is it?

Jeff Vance, the 3000 CI guru at while at HP who now develops at K-12 app vendor QSS, had this reply:

   Wildcards on most (all) Unix systems, including Posix implementations, are done by the shell, not the individual programs or in-lined shell commands, like ls in your example. A solution is to run the shell and execute ll from within.

Greg Stigers then supplied the magic Posix shell command to do the expansion:

SH.HPBIN.SYS '-c "/bin/ls -l /BACKUPS/HARTLYNE/S*"'

In a note of thanks, the customer said that getting the answer by working with the HP 3000 community's newsgroup "is like having an entire IT department right outside my door."

An interesting footnote if you've read this far: The Posix shell for the 3000 is one part of the operating system not built by HP. The shell was licensed by HP from MKS, and Hewlett-Packard pays royalties to MKS so Posix can work inside of MPE/iX. That's an issue that OpenMPE and HP will have to clear up before any emulation or source-license arrangements can be worked out.

For now, enjoy using Posix as a way to get familiar with the commands in Unix systems. In the great majority of instances, these commands are the same.

Comments