Windows: Treat invalid AFSFetchStatus as VBUSY Modify cm_Analyze() to accept an AFSFetchStatus parameter which when set is verified for validity. If the status info is invalid, then consider the response equivalent to VBUSY and attempt to query an alternate file server (if any.) Log the invalid status info to the Windows Application Event Log as a Warning. When cm_Analyze() is processing the response of an RPC that returns multiple AFSFetchStatus structures, pass in the one that corresponds with the source object. Change-Id: I84be22f332ff6fd7bc9620347f958538a3412380 Reviewed-on: http://gerrit.openafs.org/8404 Tested-by: BuildBot <buildbot@rampaginggeek.com> Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Windows: improved idle dead time handling RX_CALL_IDLE has been treated the same as RX_CALL_DEAD which is a fatal error that results in the server being marked down. This is not the appropriate behavior for an idle dead timeout error which should not result in servers being marked down. Idle dead timeouts are locally generated and are an indication that the server: a. is severely overloaded and cannot process all incoming requests in a timely fashion. b. has a partition whose underlying disk (or iSCSI, etc) is failing and all I/O requests on that device are blocking. c. has a large number of threads blocking on a single vnode and cannot process requests for other vnodes as a result. d. is malicious. RX_CALL_IDLE is distinct from RX_DEAD_CALL in that idle dead timeout handling should permit failover to replicas when they exist in a timely fashion but in the non-replica case should not be triggered until the hard dead timeout. If the request cannot be retried, it should fail with an I/O error. The client should not retry a request to the same server as a result of an idle dead timeout. In addition, RX_CALL_IDLE indicates that the client has abandoned the call but the server has not. Therefore, the client cannot determine whether or not the RPC will eventually succeed and it must discard any status information it has about the object of the RPC if the RPC could have altered the object state upon success. This patchset splits the RX_CALL_DEAD processing in cm_Analyze() to clarify that only RX_CALL_DEAD errors result in the server being marked down. Since Rx idle dead timeout processing is per connection and idle dead timeouts must differ depending upon whether or not replica sites exist, cm_ConnBy*() are extended to select a connection based upon whether or not replica sites exist. A separate connection object is used for RPCs to replicated objects as compared to RPCs to non-replicated objects (volumes or vldb). For non-replica connections the idle dead timeout is set to the hard dead timeout. For replica connections the idle dead timeout is set to the configured idle dead timeout. Idle dead timeout events and whether or not a retry was triggered are logged to the Windows Event Log. cm_Analyze() is given a new 'storeOp' parameter which is non-zero when the execute RPC could modify the data on the file server. Change-Id: Idef696b15a8161335aa48907c15a4dc37f918bdb Reviewed-on: http://gerrit.openafs.org/6118 Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com> Tested-by: BuildBot <buildbot@rampaginggeek.com>
Windows: log SMB or RDR in use at startup Change-Id: Ib38d8a755a8ace9db672ce2d10bcdd370e9e3de6 Reviewed-on: http://gerrit.openafs.org/5338 Tested-by: BuildBot <buildbot@rampaginggeek.com> Tested-by: Jeffrey Altman <jaltman@openafs.org> Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
Windows: Add shutdown event log message Add an explicit message that the shutdown sequence is complete. This is necessary because during a Windows OS shutdown, the service is frequently killed prior to the memory mapped file is fully released. Change-Id: I1ad2471e1e1442d836d6abac09fc5cdd08edae0b Reviewed-on: http://gerrit.openafs.org/5053 Reviewed-by: Derrick Brashear <shadow@dementia.org> Reviewed-by: Jeffrey Altman <jaltman@openafs.org> Tested-by: Jeffrey Altman <jaltman@openafs.org>
Windows: remove trailing whitespace remove trailing whitespace from NTMakefile *.h *.c *.cpp *.idl *.def *.txt *.htm Change-Id: I948a7511a20d0ad522b647b788536f9b6f5dda16 Reviewed-on: http://gerrit.openafs.org/4548 Reviewed-by: Derrick Brashear <shadow@dementia.org> Tested-by: Derrick Brashear <shadow@dementia.org>
Windows: handle rx busy call channel Register an error code for rx busy call channel detection. Force a retry whenever CM_RX_BUSY_CALL_CHANNEL is received by cm_Analyze(). Log the event to both the internal trace log and the Windows Event Log along with the server address. Change-Id: I196fb99d38bb89f57f296fd1b60d2a7f17fec80c Reviewed-on: http://gerrit.openafs.org/4183 Reviewed-by: Derrick Brashear <shadow@dementia.org> Reviewed-by: Jeffrey Altman <jaltman@openafs.org> Tested-by: Jeffrey Altman <jaltman@openafs.org>
libroken: Build on windows A minimal change set to get libroken to build on Windows. Sadly, libroken contains definitions for a number of platform compatibility macros which were previously scattered throughout the windows code. These scattered macros have to be removed in order to build libroken. The impact of this removal is that a very large number of files throughout the tree require the addition of "roken.h" to pick up the new compatibility code. The bulk of this change is adding these includes. In addition, some of the added includes add roken dependencies to the Unix build. So, also add libroken to the build rules in affected Unix Makefiles. Change-Id: Ifba431bd37e67b1e273fbc6f69b805a232193456 Reviewed-on: http://gerrit.openafs.org/3205 Tested-by: BuildBot <buildbot@rampaginggeek.com> Reviewed-by: Derrick Brashear <shadow@dementia.org>
Windows: Add version number to event log start pending message LICENSE MIT Change-Id: I6a2eca99cf1db9792eb76b04adbc87c4b64aa483 Reviewed-on: http://gerrit.openafs.org/3034 Reviewed-by: Derrick Brashear <shadow@dementia.org> Reviewed-by: Jeffrey Altman <jaltman@openafs.org> Tested-by: Jeffrey Altman <jaltman@openafs.org>
Windows: Log cell along with volume id for server errors When logging server volume instance errors to the windows application event log, be sure to log the cell as well. Translating from server ip address is non-trivial. Make it easier for administrators triaging issues to plug the volume and cell info into vos commands. LICENSE MIT Change-Id: I801fcd5c1afba4a8cdef4386fec72b9a529d4cfb Reviewed-on: http://gerrit.openafs.org/2653 Tested-by: BuildBot <buildbot@rampaginggeek.com> Reviewed-by: Derrick Brashear <shadow@dementia.org> Reviewed-by: Jeffrey Altman <jaltman@openafs.org> Tested-by: Jeffrey Altman <jaltman@openafs.org>
Windows: engage path mtu discovery for rx Change-Id: Ice32ca652dfcf1c14577c696eaca074f61a62675 Reviewed-on: http://gerrit.openafs.org/2085 Tested-by: Jeffrey Altman <jaltman@openafs.org> Reviewed-by: Derrick Brashear <shadow@dementia.org> Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
Windows: define new event log messages for cm_Analyze VBUSY, VRESTARTING, etc. Add MSG_SERVER_REPORTS_VBUSY, MSG_SERVER_REPORTS_VRESTARTING, MSG_ALL_SERVERS_BUSY, MSG_ALL_SERVERS_OFFLINE, and MSG_ALL_SERVERS_DOWN. Add event message throttling. Only permit one copy of a message to be generated every five seconds if the message will duplicate the prior message. This often occurs when a server or volume becomes inaccessible and there were a large number of requests queued on it. Integrate these new messages into cm_Analyze processing for VBUSY, VRESTARTING, ALLDOWN, ALLOFFLINE, and ALLBUSY errors. LICENSE MIT Change-Id: Ib30595ded23724810e294133fa75873e20ffbf0b Reviewed-on: http://gerrit.openafs.org/1762 Tested-by: Jeffrey Altman <jaltman@openafs.org> Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
windows-dirty-buffers-20090608 LICENSE MIT In the buf_IncrSync thread, if the volume is known to be unavailable do not attempt to write the buffer. Just skip it. In buf_Sync(), if we are shutting down and a buffer is left dirty, log a message to the Windows Event Log indicating that the dirty buffer was lost.
windows-remove-reset-all-vcs-event-20090328 LICENSE MIT remove the smb reset all VCs message. duplicates the reportSessionStartups functionality.
smb-vc-reset-on-request-20090218 LICENSE MIT When processing SMB_SESSION_SETUP_ANDX in smb_ReceiveV3SessionSetupX it is possible that the smb client might indicate that it requires an Mpx Count greater than we are configured to support. If so, log it to the Windows Event Log as a warning. It is also possible that the client might specify that its maximum receive buffer is smaller than the SMB_PACKETSIZE. If so, log it to the Windows Event Log as a warning. Finally, if the client specifies a virtual circuit number of zero, the client thinks this is its first time communicating with us. In which case we should invalidate all prior virtual circuits. We also log this request to the Windows Event Log as informational.
windows-eventlog-20080308 LICENSE MIT we need set privilege not query privilege
windows-eventlog2-20080301 LICENSE MIT set the registry values on each start. otherwise, we will never update the incorrect entries left over from previous installs.
windows-eventlog-20080301 LICENSE MIT somewhere along the way Microsoft stopped opening Event Message files explicitly. Instead they search the PATH environment variable for the specified file. I think this is broken but simply registering "afsd_service.exe" instead of the fully qualified path works.
windows-vc-locks-and-more-20060115 This patch fixes several issues: * the smb virtual circuits can be active and/or dead. this patch improves the handling of vc's making the transition from active to dead * correct the refcounts on the smb_user_t and smb_vc_t objects * replace the deprecated GetCurrentTime() with GetTickCounts() which is the new name. This function needs to be replaced with something else because its return value wraps after 49.7 days * hold the correct locks when adjusting the scp->fileLocksH queue * add new event log entries for unexpected session closures and send packet failures
windows-eventlog-20051219 For afsd_service.exe, properly use the Event Log by constructing message strings stored in a MESSAGETEXT resource. This patch also removes a large number of debugging related event messages that should never have been seen by an end user. That data is now logged to the trace.log where it should have been logged initially. Similar changes need to be implemented for afslogon.dll and afscreds.exe The afsd_eventlog.[ch] files should be broken out into its own library so that it can be reused efficiently. The afsreg.h header was cleaned up to ensure name consistency and to remove the last vestiges of "IBM AFS". ==================== This delta was composed from multiple commits as part of the CVS->Git migration. The checkin message with each commit was inconsistent. The following are the additional commit messages. ==================== Do not change "AFS Client" to "OpenAFS Client" unless the installers are also updated. ==================== remove temporary files upon clean
windows-64-bit-type-safety-20051105 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== This delta was composed from multiple commits as part of the CVS->Git migration. The checkin message with each commit was inconsistent. The following are the additional commit messages. ==================== more corrections for use of 64-bit types on Windows ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler ==================== 64-bit type safety changes required for successful compilation on Windows 64-bit systems with the VS 2005 compiler