.PS 60,72 .LM 9 .RM 70 .NHY .LITERAL V V A X X V V A A X X V V AAAAA X The Page Swapper V V A A X X V A A X X The Newsletter of the VAX/VMS SSSSSSS III GGGGGGG S I G Special Interest Group SSSSSSS I G GG S I G G SSSSSSS III GGGGGGG .end LITERAL .C 70; May Vol. 1 No. 2 1979 .s 1 Contributions to the Page Swapper should be sent to: .nf.nj .lm 18 .s 1 Donald Golden, Editor The Page Swapper Litton Resources Systems 3930 Westholme Drive Houston, Texas 77063 .lm 8 .f.j .s 1 Information about successes and problems, hints, inquiries to other SIG members, summaries of SPR's and fixes and SIG business items are all appropriate for publication. The newsletter will include neither advertising nor pricing information but testimonials when appropriately worded will be included. Information to be excluded from publication should be explicitly marked. .s 1 All contributions to The Page Swapper should be on a flexible diskette as an ASCII text file. The contributions will be compiled and printed on a Diablo letter quality printer for publication by DECUS. RUNOFF will be used with the following parameters: .lm 18 .nf.nj.s 1 _.PAPER SIZE 60,72 _.LEFT MARGIN 8 _.RIGHT MARGIN 72 _.NHY (no hyphenation) .LM 8 .F.J.S 1 Label your diskette and include a directory listing. The diskettes may be in either RT-11 FLX format or in Files-11 format. Make certain that the files containing contributions are readily identifiable. .s 1 To have your diskette returned promptly, label it carefully and include an addressed envelope with appropriate postage. Otherwise it will be available at the next Symposium. .s 1 For those of you who find the above procedure impossible, the newsletter will accept camera ready hardcopy on 8#1/2#X#11 paper with 1 inch margins. The above listed RUNOFF parameters are suitable for preparation of such copy. Please keep the amount of 'white space' (unused area) to a minimum to keep the cost of printing and mailing within reason. .pg By the time this newsletter hits the mails the Spring Symposium will be a [pleasant?] memory. We will have experienced some 42 hours of VAX/VMS special interest sections. This will have been the first symposium where the VAX SIG competes against itself for attendance at sessions. I hope everyone had a very informative, professionally profitable, good time in the Crescent City. .s 1 This issue of The Page Swapper is unique in that it is the second issue to have been sent to the publisher without substantial contributions from the user community. The problem is that we just aren't in full swing yet, the first issue was mailed about the same time as this one was being compiled. However, this will be the last issue with that lame excuse for being so slim. The next issue will have had two predecessors and everyone will know how to prepare contributions and where to send them. So bear with us for a bit and The Page Swapper should become as valuable and useful as the other SIG newsletters. .s 1 .s 1 VAX/VMS SPR's of interest: .s 1 [Editor's note- In this column we wish to present SPR's that are useful, informative, interesting, aggravating... The purpose is to share common problems and solutions. This column is also designed to fill in the gaps left by the absence of a VAX/VMS Software Dispatch. Another purpose is to disseminate DEC's SPR responses which solve problems for many users. The final purpose is to get real solutions to SPR's which DEC has closed without solving. Send me copies of SPR's (and responses if approporiate) and I'll try to put the essence into this column. Please be aware that the folks who respond to SPR's are willing to review their responses when we, the users, feel that they are inadequate. The mechanism to activate this review is a second SPR. This SPR should reference the number of the original SPR, redefine the problem, indicate that the solution presented in the initial response is inadequate, and give details as to why this solution is inadequate.] .s 2 ------------------------------------------------ .S 1 Despite the existence of the mailbox utilities and the shared global sections, there exists a need for a way to quickly share a memory area between cooperating processes. .s 1 The service would be implemented as follows: .list .le Process A would call a system service to lock a range of virtual addresses. This service would return suitable arguments to allow the process to subsequently unlock these pages and to allow a cooperating process to locate and map the identical space. .LE Process A would transmit the mapping information to process B, perhaps via a mailbox. .le Process B would utilize a system service similar to $EXPREG or $CRETVA to map the same (locked down) pages into its own virtual address space. .le Process B would process or otherwise use the information in the buffer. .le Process B would unmap the range of addresses and inform process A that it is through. .le Process A would unlock the pages. .end list This service would require certain privilege to execute since it could bring the system to its knees by locking down too many pages. Its utility for fast interprocess communication of large data buffers would be extremely great. .s 2 ------------------------------------------------ .S 1 If a tape is mounted with the /FOREIGN and /NOWRITE characteristics, the physical drive is then permanently software write locked until the system is re-booted. .s 2 ------------------------------------------------ .S 1 Occassionally the DCL command DIR will show a file with the message shown below. How does the file get into this state? How does one clean it up? .nf.nj DIRECTORY DB0:[0,0] 31-JAN-79 10:57 A.DIR;1 READ ATTRIBUTES ERR - file ID, sequence number check .f.j Response: This sort of thing is known as a "dangling directory entry". It is a directory entry whose file has been deleted out from under it (i. e., the file has been deleted but the directory entry has not been removed). The error message "sequence number check" appears because the ?pfile header that the directory entry points to has been re-used for another file; the header sequence number is incremented every time a header is re-used specifically to detect this condition. .s 1 A dangling directory entry is most often caused when a file is deleted which had synonyms (other directory entries that point to the same file, created with the PIP /EN command). Deleting the file removes the entry via which the file was deleted, but not the others. This situation would occur in a disk's MFD if a directory appeared in it both with alphabetic name and with a UIC style name, and was subsequently deleted. .s 1 To remove a directory entry, use the PIP /RM (remove) command, thus: .s 1 $ MCR PIP dev:[directory]name.typ;ver/RM .s 1 [Editor's comment: This was a great response and it worked. More importantly, it brought my RSX-11M memories back to life. I think the sparseness of the RSX-11M utility documentation in the VMS manual set is the source of this sort of problem. A quick survey of my VMS manuals showed no PIP /RM documentation. Digging into the trunk for my old RSX-11M binders brought forth a manual with all of PIP's (and FLX's, and VFY's, etc.) documentation.] .s 2 ------------------------------------------------ .S 1 The DMC11 Driver appears to have a bug in cancelling I/O. Clearer definition of the problem is not available at this time. When a process is using the DMC11 as a raw data channel in DDCMP mode and is STOPped from DCL, it occassionally does not stop. Process deletion gets rid of the process name, but the process hangs in there with I/O pending to the DMC11. A re-boot of the system is required to get rid of the process. .s 2 ------------------------------------------------ .S 1 FORTRAN needs a facility similar to the $xxxDEF facility in MACRO to make symbols available to the compiler. .s 2 ------------------------------------------------ .S 1 The mailbox driver does not recycle the mailbox numbers when they reach 32767. At this point the mailbox gets created but cannot be assigned in a different process. The message received is device not available. This problem is severe for those systems heavily dependent on mailboxes for communication between a network of cooperating processes. .s 2 ------------------------------------------------ .S 1 The UAF file should allow users to have a default set of privileges and an enhanced set of privileges. The normal case would be to have the default set activated at login. Then a simple command would upgrade the privileges to the enhanced set. Currently each of our users has two accounts to effect this duality of needs. .s 1 Furthermore there should be a set privilege command which allows symbolic setting and resetting of the privilege vector. .s 2 ------------------------------------------------ .S 1 SYSGEN's Current and Default parameter columns are confusing. I would have expected the Default column to show the set of parameters written by SYSINIT to SYS.EXE during the system bootstrap procedure. As it is, the Default column never changes and is therefore worthless. The current column shows the parameters in SYS.EXE only after the USE CURRENT command has been entered. This cost a couple of hours grief as we were trying to tune the system and could not be sure that the tuning parameters were being changed. The Default column should show what would be used were the system booted without change. The Current column should show the same as default until a USE is invoked. This will make SYSGEN less confusing and will get rid of the worthless set of parameters shown in the Default column. .s 2 ------------------------------------------------ .S 1 A great enhancement to the user interface to VMS would be an image SAVE and UNSAVE facility. The facility could be invoked after a control-Y by entering $#SAVE#filespec and the image restarted at a later date by typing $#RESTART#filespec. This would allow users to 'checkpoint' an image at a problem point and then debug from that point without re-running a lengthly procedure from scratch. .s 2 ------------------------------------------------ .S 1 Another neat enhancement to VMS would be a DETACH command. Entered following a control-Y, the command would detach the current process from the terminal and allow the user to proceed with other activities. This would be particularly useful for images where startup needs to be monitored or interactive and then the running is free of need for user input or output. .s 2 ------------------------------------------------ .S 1 The response to the SPR pointing the lack of PSL documentation in XDELTA was: .s 1 The PSL may be examined with DELTA or XDELTA by the command: .s 1 .i 10 RF+4/ .s 1 That is, the PSL is stored in the longword following the PC. .s 2 .page Unsolicited Random Input .s 1 [Editor's note: In this section we will present interesting trivia and helpful facts about VAX/VMS. The sources will be unnamed at present to protect the innocent.] .s 1 .c 68; Driver Hints .s 1 .list .le When invoking the macro that builds the Driver Prologue Table, specify the value of the FLAGS argument with the 'M' form of the bit's symbolic name. This is in conflict with the preliminary edition of the Guide to Writing a Device Driver. On page 7-2 this manual shows an example with arguments DPT$V__SVP and DPT$V__UNLOAD. These should be DPT$M__SVP and DPT$M__UNLOAD, since the macro expands the FLAGS argument as: .BYTE FLAGS. Using the wrong form can result in a fatal bugcheck or other unexpected system or driver behavior. .le UCBSIZE is a required argument to the DPTAB macro. Its omission will result in a bugcheck at device CONNECT. .le XDELTA is not a permanent part of the executive. To get it you must set the software boot flags in R5 at system boot time. See page D-12 of the VAX/VMS Installation Guide for information on these options. .le The options file for the command to link a user-written device driver should contain "BASE=0" with no preceeding slash ['/']. .LE During device CONNECT, SYSGEN verifies the existence of the device being connected by trying to read the device register specified with the /CSR switch. If the device does not respond because of a bad value or bad connection, a UBA error will occur. SYSGEN clears the UBA status register of any errors and clears the UCB$v__ONLINE in the device unit's UCB, setting the device offline. This is done to avoid entering the driver's device initialization code for a non-existent device unit. Since SYSGEN tests for the existence of the device at IPL 31, the UBA cannot interrupt. Once the status register has been cleared of errors, the UBA will drop its interrupt request. VAX/VMS tests for device existence that way during power recovery as well. At any other time, however, UBA timeouts will cause the unexpected UBA interrupt bugcheck. This applies both to slave synch timeouts and select timeouts. Before the bugcheck, the EXEC copies the UBA registers into the general registers, so that their contents will be printed during the bugcheck console dump. The general registers are loaded as follows: .lm 25 .s 1 R0 - UBA Configuration Register .br R1 - Control Register .br R2 - Status Register .br R3 - Diagnostic Control Register .br R4 - Failed Map Address Register .br R5 - Failed Unibus Address Register .end list .lm 9 .s 1 For a description of the UBA register layout, see the VAX=11/780 Hardware Handbook, Chapter 9. .s 1 An unexpected UBA bugcheck following a user driver CONNECT is the result of a user error. Likely possibilities are incorrect displacements from the CSR for other device registers or incorrect addressing modes in referencing the device registers or any other coding errors resulting in an attempted access to a non-existent unibus location. The Failed Unibus Address Register (FUBAR) will contain the invalid unibus address. .s 2 .c 68;AST Cleanup Problem .s 1 In the listing of the ASTDEL module of the executive, just following the symbol EXE$ASTDEL, there are two paragraphs which are quoted in their entirety below: .s 1 "A window exists between the ASTEXIT CHMK and the REI, during which 4 longwords remain on the stack of the access mode exiting the AST. If AST's occur more rapidly for an access level than they can be processed, there will be an accumulation of these 4 longword units on the stack of that mode until the stack overflows. .s 1 If this becomes a problem the ASTEXIT CHMK can be made to conclude the stack cleaning at a substantial cost in time and code." .s 1 It is true. We got quite a few of these 4 longword units on our stack and then it overflowed with a splendid set of error messages. At the time, we were running a cooperating set of processes which caused about 400 AST's per second by themselves, not counting those required by VMS. A 100 millisecond wait about every 7 seconds apparently allowed VMS to clean the stack so that the set of processes ran for about 64 continuous hours without any glitches. .s 1 The word from the VAXWORKS was that the full cleanup had been tried and the performance degradation was unacceptable. The decision was made to let the stacks be corrupted for those cases when too many AST's arrive in a short interval and to let the cleanup proceed stochastically. For the the hapless user who had too many AST's for too long a period, the two paragraphs above would tell her or him what happened. In our case, and I imagine that in most cases, the four longwords left on the stack are the last four longwords of an AST routine call frame. These contain a saved PC which points to an instruction on the page of the fiche where the above two paragraphs live. I cannot fault the decision not to clean the stack in the CHMK, but I do wish the documentation had been in one of the manuals where AST's were discussed. .s 2 .c 68;Words about DSC .s 1 DSC makes some assumptions about the output device when a copy is performed. For example, regardless of where your index file is on the input medium, it will be at the beginning of the volume after a DSC restore operation. Also, whatever your cluster factor is on the input disk, it will be the same on the output disk. (It is 11 on the Distribution magtape. Vaxworks recovered several thousand blocks when the cluster factor on the data disk was changed to 5.) Also, note that the default system has a cluster factor of 11 and an extend size of 5. A better relationship for general purpose use might be to reverse the numbers or make them equal. Proper values for these numbers will depend on the application. .s 1 It seems that stand alone DSC does not recognize magtapes on TR_10 or above, this problem has been SPR'ed. .s 1 Finally, beware of logical names. It is quite possible to DSC a disk to itself with disasterous results. It has been done! .s 2 It is assumed that all articles submitted to the editor of this newsletter are with the author's permission to publish in any DECUS publication. The articles are the responsibility of the authors and, therefore, DECUS, Digital Equipment Corporation, and the editor assume no responsibility or liability for articles or information appearing in the document. .s 2 .c 68; c 1979, DECUS