This patch corrects the following: - Corrects a problem with an NFS V3 mounted AdvFS file system where under heavy I/O load, data being written to a file may be lost. Additionally, because file stats are not being saved, the file modification time may revert to a previous value. - Provides a performance improvement for AdvFS systems. - Corrects a problem in AdvFS where a data structure field is not initialized until after an AdvFS mount which is too late. This results in the inability for example to see the files after a remount. - Fixes a problem that occurs on SMP systems with an AdvFS filesystem in which the system panics with the following message: simple_lock: time limit exceeded - Fixes a problem with the vrestore command. When restoring a multi-volume tape archive, if the tapes that follow the first tape are write-protected, the following error message is displayed: vrestore: can't open device file - Fixes a problem where the vrestore program does not report failed exit status appropriately on incomplete or incorrect commands, corrupt or invalid saved sets, or file open failures. - Fixes a problem that occurs on SMP systems with an AdvFS filesystem in which the system panics with the following message: simple_lock: time limit exceeded - Fixes a problem that occurs on AdvFS systems. The chfsets function returns incorrect exit values and inappropriate error messages. - Enables AdvFS root quotas. - Fixes an AdvFS problem that causes a lockmode 4 system panic. - Fixes an AdvFS domain panic causing a system panic which has the following error message: SMP Assertion failed If a panic is not encountered, verify will show inconsistencies. - Fixes a problem in which vrestore can cause an occasional core dump (Floating Exception). - A system using an AdvFS clone fileset can panic with either a kernel memory fault in bs_real_invalidate_pages(), or with the panic string: "bs_real_invalidate_pages: buf refd or pinned". - Fixes a problem that occurs on AdvFS file systems. A kernel memory fault occurs on the AdvFS file system when accessing nfs-mounted files. - Prevents a "kernel memory fault" in the sbm_init() routine on systems using AdvFS. - Prevents a "kernel memory fault" in the msfs_reclaim() routine on systems using AdvFS. - Fixes an kernel memory fault panic. The system displays the following error message: trap: invalid memory read access from kernel mode - Fixes a problem that occurs when the user attempts to fill an AdvFS: the system crashes and displays the following panic: lock_write: hierarchy violation - Fixes a problem caused by the vrestore command. The command would fail when restoring multiple savesets from a TZS20 tape drive. - Fixes an AdvFS response time problem that occurred when an application with many random access reads of many files was being slowed down by the resulting number of writes to disk. - Fixes a problem in the defragment utility. Defragment is migrating more than 1 gigabyte of data at a time causing data to be lost and displaying the following message: log half full - Fixes a problem caused by the vdump command. When a user entered Ctrl/C to terminate a vdump operation, the command returned an incorrect status and mistakenly updated the /etc/vdumpdates file. - Fixes a problem that occurred when an AdvFS panic crashed the system but the visible symptom was a crash due to a kernel memory fault. - Fixes a problem with the chfsets command. When a root user exceeded the fileset quota (which root is allowed to do), the chfsets command reported negative values for the free and available blocks in the fileset. - Fixes a problem with AdvFS in which the following panic occurs: clone: str_stripe_clone err - Modifies the vd_remove() function to set domain panic instead of panicing the system. - Fixes a problem that crashed the system while it was running a "collision" test. The process would hang on a lock, never be woken, and crash the system. - Fixes an AdvFS problem that occurs when unmounting a domain. An unmount thread was waiting on a variable to be set to zero before continuing, but the routine that was to set the variable to zero never did. - Fixes a problem with the AdvFS fs_write routine, which would mishandle partial writes after detecting an error. - Corrects a problem where a panic would occur when running rmtrashcan on a clone. - Fixes a problem with AdvFS, which caused a system panic with the following message: log_flush_sync: pingpg error The system panic occurred when the AdvFS domain had already issued a domain panic and a user application then attempted to close a file in that domain. - Fixes a problem with AdvFS, which would corrupt a clone fileset when it truncated the original fileset. - Provides performance improvements for writes to AdvFS files which have had Atomic Write Data Logging enabled on them. Write performance improvements are for O_SYNC opens of such files and are realized for both local and NFS access. - Fixes a problem in AdvFS that produced the following system panic: bs_logflush_start: cannot write lsn - Fixes a problem with messages in system logs that reported AdvFS user and group quota limits. The messages were unclear: the user could not determine from them which users or groups were reaching the quota limits. - Fixes several problems associated with AdvFS tag files and directories, including displays of erroneous data and system panics. - Fixes a problem in AdvFS locking code which causes the following panic: kernel memory fault - Fixes a problem in AdvFS, which causes a system panic when a truncate operation is performed on a file. The panic is: log half full - Fixes a problem in AdvFS that was causing a memory leak. - Fixes the following problems in AdvFS: 1.) AdvFS does not return an error when a user opens a file in O_SYNC mode and power is lost on the disk drive. 2.) A locking error in the AdvFS fs_write() routine. - Fixes a problem with AdvFS that caused a page fault and the following panic: panic (cpu 0): kernel memory fault - Fixes two AdvFS problems: 1. An error message was misleading when a DIGITAL UNIX Version 4 system attempted to access a file domain created by DIGITAL UNIX Version 5. 2. A state field in an AdvFS data structure was initialized, but not maintained. - Fixes a problem where user files or the AdvFS frag file could lose data, if they are updated during an AdvFS migration (that is, during a balance, defragment, migrate, or rmvol of their AdvFS domain). - Fixes a problem with the vrestore command. The command had returned a success status code even though it had restored an incomplete file during the operation. - Fixes three verify command problems: 1. The command was displaying a large volume of meaningless data. 2. When it encountered a nonrecoverable error, the command did not properly exit. 3. The command sent some error messages to stderr, some to stdout. - Fixes a problem that occurs on AdvFS systems. The system will panic with the following error message: malloc_overflow: guard space corruption - Fixes a problem with AdvFS, which produced the following error while attempting to migrate a sparse file: E_CANT_MIGRATE_HOLE - Fixes the following problems in the AdvFS system: o The log file corruption caused panics during recovery and failures and display one of the following messages: ftx_fail: lgr_read failure -or- ftx_fail: dirty page not allowed o kernel memory fault o The error message: "can't clear a bit twice". -or- o The error message: "can't set a bit twice". Note: This fix only fixes a subset of the known set/clear bit panics. - Fixes a problem in the AdvFS logging code, The way locking was implemented was causing degraded performance. - Corrects an I/O subsystem performance bottleneck. A system which experiences periodic system slowdowns may need this patch. - Fixes a operating system hang condition. The hang condition exists due to processes deadlocking in the Advfs code. - Fixes a problem with AdvFS performance. The patch provides a performance improvement to the msync system call when it is called for an AdvFS mmapped file. - Fixes an AdvFS problem that occurs when the rmvol command is stopped before the commmand successfully removes a volume from a domain. As a result, the showfdmn and addvol commands interpreted the volume as still in the domain (although with no data available) and a balance operation returned the following AdvFS error message: get vol params error EBAD_VDI (-1030) This patch fixes a problem with the defragment command, where the -V option is not being parsed properly. This patch fixes a problem in AdvFS that produced the following system panic: malloc_overflow: guard space corruption This patch fixes a problem with the vdump command, which was modifiying the atime file attribute whenever files were backed up, thereby eliminating the ability to determine when the files were last accessed by a user. This patch enhances the AdvFS verify utility to detect incorrect "holes" in frags file. This patch fixes an AdvFS problem, which can allow I/O requests to bypass the ready lazy queue. This patch fixes a problem in the AdvFS system. The system hangs due to a deadlock between update daemon sync() syscall processing in AdvFS and the truncation of AdvFS file. This patch fixes a problem that occurs when vrestore is run from a script. Control c input to vrestore run from a script is not processed correctly. This patch changes the way some of the ADVFS advanced utilities work (rmvol, migrate, balance and defragment) as they were failing when trying to migrate file(s) from an ADVFS domain with heavy I/O. This patch corrects a problem observed when using the edquota command under the Advanced File System (AdvFS). The edquota command may display an incorrect grace period. This patch applies to AdvFS use only and corrects a problem whereby rmvol(8) will not remove multiple stripes of the same file on a volume. The error code EBAD_VDI (-1030) may be displayed. This patch fixes the following problems with the vrestore command: - vrestore is slow to complete when a partial restore operation is requested. - vrestore fails to ignore extended attribute records for those files that are not requested in a vrestore operation. This patch fixes two AdvFS problems: 1) When an AdvFS volume is nearly full, AdvFS files may become corrupt as they are closed. The verify utility can be used to detect this "overlapped frag corruption" problem. 2) The truncation of the fragment bitfile was erroneously being turned off. This feature allows AdvFS to give back disk space periodically. This patch fixes a panic in the AdvFS system. The panic has the following error message: lock_read: hierarchy violation This patch fixes the following problems: * A potential system hang when inactivating an AdvFS domain (QAR 65739) * A potential problem during AdvFS domain activation that can cause an AdvFS domain to be unmountable (QAR 64945) This patch fixes a potential problem with the vdump command. This patch provides the following fixes and enhancements to AdvFS: - AdvFS volumes were not setting the default I/O byte transfer size to the preferred size reported by the disk drives. - AdvFS chvol read and write transfer size range was increased. - The read-ahead algorithm was modified to improve performance under certain conditions. This enhancement for the /sbin/advfs/verify utility allows it to detect loops in the list of free frags kept in the frags file. This patch fixes a problem where a system can panic with a kernel memory fault in overlay_xtnt_map() when any of the AdvFS migration utilities (migrate,balance, rmvol, or defragment) are run on an AdvFS domain. This patch fixes a problem in which a system using AdvFS can Kernel Memory Fault when truncating a frag file for a fileset that is not mounted. Make vrestore work with QIC-120 and QIC-150 tapes This patch fixes an AdvFS hang that is caused by a deadlock between the_XentMM() and msfs_mmap() system calls. This patch fixes a problem in which a system can hang because cleanup_closed_list() can go into a loop. This patch introduces changes to the DECthreads libraries intended to improve the performance of threaded applications running on Digital UNIX 4.0d. This patch specifically addresses the areas of thread scheduling, synchronization object performance and SMP scalability. This patch fixes a problem on systems using the AdvFS filesystem, where the system can panic with the panic string, "del_clean_mcell_list: no primary xtnt record". This patch fixes a problem in AdvFS which could cause thread hangs or a system panic. - This patch fixes a problem in which the update daemon can hang. - This patch fixes a problem with AdvFS that will cause the system to panic with "kernel memory fault" in audit_rec_build(). - This patch fixes an AdvFS Domain Panic that occurs with the following message on the console: "load_x_cache: bad status from bs_refpg of sbm" - This patch fixes a problem where the "statfs" system call was reporting incorrect block usage on AdvFS filesets. As a side effect of this problem, the sendmail utility may sleep needlessly (waiting for space to become available). - Fixes the following problems: - A kernel memory fault system panic in routine spec_reclaim. - When executing the "file" command against a lat (BSD) special device, the "file" process will hang. - On multiCPU systems, hangs can occur in the revoke system call when multiple threads attempt to call "revoke" at the same time. - Fixes a problem where several processes accessing the same AdvFS file can hang in ubc_lookup(). - Fixes a problem with an unclear AdvFS message. When trying to mount an AdvFS fileset on a system that did not have AdvFS installed, the following message was displayed: No such device Now, in similar cases, the following AdvFS message is displayed: Cannot mount AdvFS fileset, AdvFS not installed - Fixes a problem with AdvFS and links in the /etc/fdmns directory. Previously, AdvFS did not ensure that every link in a directory entry pointed to a block device. Now, it does. - This patch fixes a problem with the mount command where it sometimes kills other processes. - This patch fixes a problem where the vdump program would dump core with the following message: "nnnn Resources lost(coredump)" - This patch corrects a problem in AdvFS that causes single-CPU systems to hang and causes multiple-CPU systems to panic with a "simple lock time limit exceeded" error specifying lock class name BfAccessTblMutex. - This patch corrects a problem that caused invalid fragment information to be reported for an AdvFS file. The invalid information was returned in response to a verify command. - This patch fixes a problem that caused the system to hang when AdvFS tests were run in lockmode 4. The fix allows xfer_xtnts_to_clone to recover after a crash. - This patch fixes a problem with the AdvFS addvol command. Prior to this patch, if the advol command was interrupted and a second addvol command was run, the AdvFS domain would be rendered unusable. - This patch fixes a problem in which system panics due to advfs lock hierarchy violation. - This patch fixes a problem with the defragment command. Prior to this patch the defragment command could fail and display inacurate error descriptions. The problem was caused by uninitialized variables for the command. - This patch fixes the problem where the system panics if AdvFS detects an inconsistency in the free list of mcells that is kept on a per-volume basis in an AdvFS domain. The panic string seen with this panic is "alloc_mcell: bad mcell free list". - This patch fixes a problem where "update" takes too long to sync mmap files when using an AdvFS file system. - This patch fixes the potential directory corruption,when system crashes during rmdir. - This patch fixes the problem where the system panics whenever nextFlushSeq reaches the max.This fix allows nextFlushSeq (and other buffer lsn's) to roll over. - This patch corrects a problem where a "can't clear a bit twice" panic occurs after an unanticipated system crash and an improperly handled AdvFS recovery operation. - This patch fixes the following two problems in AdvFS: o When a "log half full" or "log full" problem occurs, an entire system will panic. o The erorr message "ftx_bfdmn_recovery:bad record size\n N1 = 1" is received when the wordCnt, as returned by lgr_read, is not enough to hold the ftxDoneLRT record that preceeds each log record in a log page. - This patch fixes a problem where vdump will output the message, "can't reset atime" for each file it is backing up when used with an NFS mounted file system. - Corrects a problem in AdvFS where unmounting a domain that is already in a panicked state could result in the following system panic message: log_flush_sync: pinpg error\n N1 = 5 - corrects some error messages given when the AdvFS utility verify(8) detects file errors. It also corrects a problem whereby verify was unable to delete files with no directory entries. - Ensures all AdvFS root fileset buffers are flushed on shutdown. - Fixes the defragment program to properly report on extremely large (>4.3GB) freespace holes. Previously it would report "Free space" percentages larger than 100% and would add these large holes to the smallest range (<100K) instead of the largest range (>10M) where they belong. - Corrects a kernel memory fault that occurs when entering the "mount -o dual" command. Abbreviated stack: 9 _XentMM() 10 bs_bfdmn_sweep() 11 bs_bfdmn_activate() 12 bs_bfdmn_tbl_activate() 13 bs_bfset_activate_int() 14 bs_bfset_activate() 15 advfs_mountfs() - Fixes a problem in AdvFS. AdvFS may skip filesystem recovery after aborted domain activation. - Fixes a problem in AdvFS. The system panics with the following error message: SMP Assertion failed - Fixes a problem in which it prevents a system panic if str_stripe_clone returns an error. - Fixes two problems with the vrestore command. First, the command was slow to complete when a partial restore operation was requested. Second, the command failed to ignore extended attribute records for the files which were not requested for a vrestore operation. In addition this patch corrects intermittent failures to display archive records for the above files (compressed or not) when the list option was selected. - Patch avoids corruption of a filesystem when verify runs with '-r' & '-f' flags on an active domain. Verify returns usage message when '-r' flag is used with either '-f' or '-d'. - Fixes following problems with the /sbin/vdump command: o Non-zero level dumps on links that point to a mounted file system can now be performed. o To prevent danglinkg links after a vrestore, directory entries are now created instead of re-creating links that points to a mount file system. o vdump no longer ignores valid nfs mounts with inodes = 5 or 4. - Fixes a problem that may cause panics to occur when msfs_getpage() receives an error return from fs_write_add_stg() when attempting to write to an AdvFS domain that is out of disk space. - Fixes a problem in AdvFS. A fileset is busy when attempting to unmount giving an EBUSY error even though the fileset has no open files. - Fixes problem with vrestore where vrestore fails to restore certain files and directories having ACLs from a compressed vdump saveset, reporting: vrestore: error setting extended attributes 22 - Fixes a problem in the AdvFS system. A panic occurs with the following error message: lock_read: hierarchy violation - Fixes a problem with the AdvFS system. A panic occurs with the following error message: lock_read: hierarchy violation - Fixes a situation in which a slight memory leak can occur when recovering Advfs domains with mount. - Fixes a problem where a single cpu system using AdvFS can hang in cleanup_closed_list(). - Corrects AdvFS problems involving clone filesets. The statfs syscall (used by df) was incorrectly returning zero blocks USED for clones. The read-ahead code was incorrectly passing up opportunities to do read-ahead on clone filesets, resulting in a large performance penalty. - Corrects two problems in AdvFS property list handling: 1) Creation of property lists entries in AdvFS filesets with no available mcells will result in kernel memory fault (kmf). 2) The get_proplist_entry function (used to disassemble the property list buffer returned by the "getproplist" system call) returned incorrect name length on property list names longer than 127 characters. - Fixes a problem with the parameter checking code of the fcntl system call. As a result, incorrectly coded fcntl() parameters in user programs no longer panic the system. - Fixes the AdvFS race between extending and reading subextent maps and avoids the panic occured in advfs bs_get_bf_xtnt_map code (qar 61985). This patch also fixes the race with removing storage causing kernel memory fault (qar 66890). - Fixes a panic in AdvFS which can have the following error messages: panic (cpu 1): bs_cow_pg: pin clone err -OR- panic (cpu 1): bs_cow_pg: cannot get blkMap - Fixes a problem with making a msfs_putpage() call. The length argument may get its upper bits truncated which will result in an incorrect length calculation. - Fixes a problem in which an invalid error status is returned from the remove_entry system call. - Fixes a problem in AdvFS. The system panics with a kernel memory fault. - Fixes a problem in AdvFS. A system panic occured with the following error message: panic: del_dealloc_stg(): cant ref bmt page - Fixes the following /sbin/advfs/verify command problems: o Verify fails to complete on a large number of files. o Verify will core dump when an offset into mountd[] array that is used to pull out the fileset name is corrupted. o Verify incorrectly reports errors on BMT's that have multiple extent records for domains created with the mkfdmn -p switch. o Verify fails when lseeking on very large domains. - Fixes a problem that caused AdvFS to incorrectly calculate metadata file size for files greater than 4GB resulting in corruption on read and stat syscalls. - Fixes a problem where the output of a "ps" command, the PAGEIN column reports 0 for all processes. - Fixes a problem in Advfs. A panic occurs with the following error message: lock_read: hierarchy violation - Fixes AdvFS inconsistent quota problems and errors similar to the following appearing on the console: 'vmunix: chk_bf_quota: group quota underflow' - Fixes a problem with verify. When verify is run on a brand new domain, nfs warnings are displayed even though no nfs related activity is being done. - Fixes a system hang that could last up to a few minutes with large files when performing synchronous IO requests. - Fixes an AdvFS problem which caused the system to crash with a kernel memory fault. - Fixes a problem with a kernel memory fault in AdvFS. - Fixes a problem in which the chfile utility returns an incorrect error code. - Fixes a problem in AdvFS where putpage_lk/pg_busy deadlock causes hangs in the system. - Fixes the following vrestore problems: o a previous patch caused incomplete restores o a warning message is displayed when the path for the first file in a group of hardlinks is created without using original protection codes and property lists. o a warning message is displayed and vrestore aborts if it fails to malloc space for a property list o a message which had been inserted at the end of the message file, had the wrong message category (could cause messaging confusion) o an uninitialized variable in the code that restores property lists could cause malloc failures, memory faults, "error setting extended attributes" and infinite loops using the '-l' option o corrupted property list information could cause an infinite loop This patch fixes an AdvFS kernel memory fault caused by a race condition between migrate and chfile -L in bfflush_start. This patch fixes a problem in AdvFS. The following error messages can occur: panic: simple_lock: uninitialized lock -or- kernel memory fault: simple_lock: minimum spl violation This patch fixes a problem in AdvFS in which a system that had already domain panic'ed results in a system panic. This patch fixes a problem where the vdump command will sometimes store symbolic link files as directories in the vdump archive. This patch fixes a problem with AdvFS. An AdvFS domain becomes inaccessible when using the mount -d option. This patch fixes a problem with AdvFS in which a hang occurs due to a deadlock between bsbuf.state and bmt extent map lock. This patch fixes a problem with AdvFS where all processes are waiting for buffers causing the system to hang. This patch fixes a problem in AdvFS where user data may be lost when a clone file is migrated. This patch fixes a panic in AdvFS with the following error message: ftx_fail_2: dirty page not allowed This patch fixes hangs in AdvFS fileset operations such as clone creation and deletion when I/O errors or device full conditions resulted in the operation being "undone". This patch fixes a lock hierarchy violation in AdvFs. This patch fixes a memory leak when named pipes (FIFOs) are used. This patch prevents a system panic from occurring while using ADVFS. This patch modifies advfs kernel code and several utilities. AdvFS will no longer panic with the following error: ADVFS EXCEPTION : panic cpu(0) : bad frag free list. The code is modified so that during frag allocation when advfs determines that the frag group header's free list has been corrupted, it stops using it and marks it BAD. It is then removed from the free list so no more allocations can take place AND no deallocations are performed. The verify, shfragbf and vfragpg programs are modified to report BAD frag groups. This patch fixes a problem in which rmvol would hang in a wait state. This patch fixes a potential problem flushing data to disk when using data logging with sparse files. This patch adds support for activating temporary data logging on a mount point. This patch fixes an AdvFS hang that is caused by a thread waiting for flushCv notification and is holding resources that other threads want. This type of hang has been experienced when shutting the system down. This patch fixes a problem where threads can hang in x_load_inmem_xtnt_map(). This patch fixes a problem where a system can crash with the panic string, "bs_pinpg_one_int: nextflushseq(2) rollover". This patch fixes a problem where the setgid bit of a directory was not being set when created, if its parent directory has the setgid bit set. This patch fixes a panic in AdvFS which has the following error message: panic: Unaligned kernel space access from kernel mode This patch fixes a timing window where flushing data to disk can be incomplete when a system is going down, if more than one thread calls reboot() without first going through shutdown, /sbin/reboot, or /sbin/halt. This patch corrects a problem in which a single application's creating and removing of files repeatedly in the absence of other applications working on the same fileset can cause poor 'update' daemon performance due to a flawed kernel hashing algorithm. This patch fixes the following problems in the following commands: vdump: - failed to flag compressed extended attributes records that are split across a vdump BLOCK boundary - overrides the -D option when source path describes a root fileset NOTE: If you want to backup quota files, you must not use the -D option. - Correct "Rewinding" message to avoid a segfault with Internationalized messages. vrestore: - fails to properly handle extended attributes records in compressed archives. This results in malloc failures, proplist corruption, program abort, program crashes due to segfault or invalid memory access, and the display of the error message "error setting extended attributes" - fails to set extended attributes due to confusion over selective restore of the file or directory associated. Also results in display of error message "error setting extended attributes". - selective restore of hardlinked files is incomplete when they exist in different directories (fails to create directory for second occurrence of file with same inode number) - The -Q option is added to vrestore to allow the user to request that we ignore the quota files (thus avoiding the time it takes to process them). While performing the rmfset operation AdvFS panic'd with the following error message: "rbf_delete_int: can't find bf attributes"