Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

193 lines
5.0 KiB

  1. /*++ BUILD Version: 0001 // Increment this if a change has global effects
  2. Copyright (c) 1991-1993 Microsoft Corporation
  3. Module Name:
  4. lmstats.h
  5. Abstract:
  6. This module defines the API function prototypes and data structures
  7. for the following groups of NT API functions:
  8. NetStatistics
  9. Author:
  10. Dan Lafferty (danl) 29-Mar-1991
  11. Environment:
  12. User Mode - Win32
  13. Notes:
  14. You must include NETCONS.H before this file, since this file depends
  15. on values defined in NETCONS.H.
  16. Revision History:
  17. 28-Mar-1991 Danl
  18. Ported from LM2.0 and the LMNETAPI spec.
  19. --*/
  20. #ifndef _LMSTATS_
  21. #define _LMSTATS_
  22. #ifdef __cplusplus
  23. extern "C" {
  24. #endif
  25. //
  26. // Function Prototypes - Statistics
  27. //
  28. NET_API_STATUS NET_API_FUNCTION
  29. NetStatisticsGet (
  30. IN LPTSTR server,
  31. IN LPTSTR service,
  32. IN DWORD level,
  33. IN DWORD options,
  34. OUT LPBYTE *bufptr
  35. );
  36. //
  37. // Data Structures - Statistics
  38. //
  39. #ifdef LM20_WORKSTATION_STATISTICS
  40. typedef struct _STAT_WORKSTATION_0 {
  41. DWORD stw0_start;
  42. DWORD stw0_numNCB_r;
  43. DWORD stw0_numNCB_s;
  44. DWORD stw0_numNCB_a;
  45. DWORD stw0_fiNCB_r;
  46. DWORD stw0_fiNCB_s;
  47. DWORD stw0_fiNCB_a;
  48. DWORD stw0_fcNCB_r;
  49. DWORD stw0_fcNCB_s;
  50. DWORD stw0_fcNCB_a;
  51. DWORD stw0_sesstart;
  52. DWORD stw0_sessfailcon;
  53. DWORD stw0_sessbroke;
  54. DWORD stw0_uses;
  55. DWORD stw0_usefail;
  56. DWORD stw0_autorec;
  57. DWORD stw0_bytessent_r_lo;
  58. DWORD stw0_bytessent_r_hi;
  59. DWORD stw0_bytesrcvd_r_lo;
  60. DWORD stw0_bytesrcvd_r_hi;
  61. DWORD stw0_bytessent_s_lo;
  62. DWORD stw0_bytessent_s_hi;
  63. DWORD stw0_bytesrcvd_s_lo;
  64. DWORD stw0_bytesrcvd_s_hi;
  65. DWORD stw0_bytessent_a_lo;
  66. DWORD stw0_bytessent_a_hi;
  67. DWORD stw0_bytesrcvd_a_lo;
  68. DWORD stw0_bytesrcvd_a_hi;
  69. DWORD stw0_reqbufneed;
  70. DWORD stw0_bigbufneed;
  71. } STAT_WORKSTATION_0, *PSTAT_WORKSTATION_0, *LPSTAT_WORKSTATION_0;
  72. #else
  73. //
  74. // NB: The following structure is REDIR_STATISTICS in sdk\inc\ntddnfs.h. If you
  75. // change the structure, change it in both places
  76. //
  77. typedef struct _STAT_WORKSTATION_0 {
  78. LARGE_INTEGER StatisticsStartTime;
  79. LARGE_INTEGER BytesReceived;
  80. LARGE_INTEGER SmbsReceived;
  81. LARGE_INTEGER PagingReadBytesRequested;
  82. LARGE_INTEGER NonPagingReadBytesRequested;
  83. LARGE_INTEGER CacheReadBytesRequested;
  84. LARGE_INTEGER NetworkReadBytesRequested;
  85. LARGE_INTEGER BytesTransmitted;
  86. LARGE_INTEGER SmbsTransmitted;
  87. LARGE_INTEGER PagingWriteBytesRequested;
  88. LARGE_INTEGER NonPagingWriteBytesRequested;
  89. LARGE_INTEGER CacheWriteBytesRequested;
  90. LARGE_INTEGER NetworkWriteBytesRequested;
  91. DWORD InitiallyFailedOperations;
  92. DWORD FailedCompletionOperations;
  93. DWORD ReadOperations;
  94. DWORD RandomReadOperations;
  95. DWORD ReadSmbs;
  96. DWORD LargeReadSmbs;
  97. DWORD SmallReadSmbs;
  98. DWORD WriteOperations;
  99. DWORD RandomWriteOperations;
  100. DWORD WriteSmbs;
  101. DWORD LargeWriteSmbs;
  102. DWORD SmallWriteSmbs;
  103. DWORD RawReadsDenied;
  104. DWORD RawWritesDenied;
  105. DWORD NetworkErrors;
  106. // Connection/Session counts
  107. DWORD Sessions;
  108. DWORD FailedSessions;
  109. DWORD Reconnects;
  110. DWORD CoreConnects;
  111. DWORD Lanman20Connects;
  112. DWORD Lanman21Connects;
  113. DWORD LanmanNtConnects;
  114. DWORD ServerDisconnects;
  115. DWORD HungSessions;
  116. DWORD UseCount;
  117. DWORD FailedUseCount;
  118. //
  119. // Queue Lengths (updates protected by RdrMpxTableSpinLock NOT
  120. // RdrStatisticsSpinlock)
  121. //
  122. DWORD CurrentCommands;
  123. } STAT_WORKSTATION_0, *PSTAT_WORKSTATION_0, *LPSTAT_WORKSTATION_0;
  124. #endif
  125. typedef struct _STAT_SERVER_0 {
  126. DWORD sts0_start;
  127. DWORD sts0_fopens;
  128. DWORD sts0_devopens;
  129. DWORD sts0_jobsqueued;
  130. DWORD sts0_sopens;
  131. DWORD sts0_stimedout;
  132. DWORD sts0_serrorout;
  133. DWORD sts0_pwerrors;
  134. DWORD sts0_permerrors;
  135. DWORD sts0_syserrors;
  136. DWORD sts0_bytessent_low;
  137. DWORD sts0_bytessent_high;
  138. DWORD sts0_bytesrcvd_low;
  139. DWORD sts0_bytesrcvd_high;
  140. DWORD sts0_avresponse;
  141. DWORD sts0_reqbufneed;
  142. DWORD sts0_bigbufneed;
  143. } STAT_SERVER_0, *PSTAT_SERVER_0, *LPSTAT_SERVER_0;
  144. //
  145. // Special Values and Constants
  146. //
  147. #define STATSOPT_CLR 1
  148. #define STATS_NO_VALUE ((unsigned long) -1L)
  149. #define STATS_OVERFLOW ((unsigned long) -2L)
  150. #ifdef __cplusplus
  151. }
  152. #endif
  153. #endif // _LMSTATS.H