2.2.4.25.3 Final Server Response

 SMB_Parameters
   {
   UCHAR WordCount;
   Words
     {
     USHORT Count;
     }
   }
 SMB_Data
   {
   USHORT ByteCount;
   }

SMB_Header:

Command (1 byte): This field MUST contain the SMB_COM_WRITE_COMPLETE (section 2.2.4.28) command code of 0x20.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

SMB_Parameters

SMB_Data

...

SMB_Parameters (3 bytes):


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

WordCount

Words

WordCount (1 byte): This field MUST be 0x01.

Words (2 bytes):


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

Count

Count (2 bytes): This field contains the total number of bytes written to the file by the server.

SMB_Data (2 bytes):


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

ByteCount

ByteCount (2 bytes): This field MUST be 0x0000. No data is sent by this message.

Error Codes

SMB error class

SMB error code

NT status code

POSIX equivalent

Description

SUCCESS (0x00)

SUCCESS

(0x0)

STATUS_SUCCESS

(0x00000000)

EFBIG

The file has grown too large and no more data can be written to the file. A Count of zero (0x0000) MUST be returned to the client in the server response. This indicates to the client that the file system is full.

SUCCESS (0x00)

SUCCESS

(0x0)

STATUS_SUCCESS

(0x00000000)

NOSPC

No space on the file system. The server MUST return a zero (0x0000) in the Count field of the response. This indicates that the file system is full.

ERRDOS (0x01)

ERRnoaccess

(0x0005)

EAGAIN

Resources for I/O on the server are temporarily exhausted.

ERRDOS (0x01)

ERRnoaccess

(0x0005)

STATUS_ALREADY_COMMITTED

(0xC0000021)

ENOLCK

A record lock has been taken on the file or the client has attempted to write to a portion of the file that the server knows has been locked, opened in deny-write mode, or opened in read-only mode.

ERRDOS (0x01)

ERRbadfid

(0x0006)

STATUS_INVALID_HANDLE

(0xC0000008)

STATUS_SMB_BAD_FID

(0x00060001)

ENFILE

Invalid FID, or FID mapped to a valid server FID but it was not acceptable to the operating system.

ERRDOS (0x01)

ERRnomem

(0x0008)

STATUS_INSUFF_SERVER_RESOURCES

(0xC0000205)

ENOMEM

The server is out of resources.

ERRDOS (0x01)

ERRbadaccess

(0x000C)

STATUS_ACCESS_DENIED

(0xC0000022)

Write permission required. The UID provided does not have write permission on the specified FID.

ERRDOS (0x01)

ERRlock

(0x0021)

STATUS_FILE_LOCK_CONFLICT

(0xC0000054)

STATUS_LOCK_NOT_GRANTED

(0xC0000055)

The requested byte range was already locked by a different process (PID).

ERRDOS (0x01)

ERRnotconnected

(0x00E9)

STATUS_PIPE_DISCONNECTED

(0xC00000B0)

EPIPE

Write to a named pipe with no reader.

ERRSRV (0x02)

ERRerror

(0x0001)

EDEADLK

The write would block due to locking and deadlock would result.

ERRSRV (0x02)

ERRerror

(0x0001)

ERANGE

Attempted write size is outside of the minimum or maximum ranges that can be written to the supplied FID.

ERRSRV (0x02)

ERRerror

(0x0001)

STATUS_INVALID_SMB

(0x00010002)

A corrupt SMB request was received. In addition to other causes, this status is sent if the value of the DataLength field is invalid with respect to either the CountOfBytes field or the number of bytes in the SMB_Data_Bytes.Data field.

ERRSRV (0x02)

ERRinvtid

(0x0005)

STATUS_SMB_BAD_TID

(0x00050002)

Invalid TID in request.

ERRSRV (0x02)

ERRqfull

(0x0031)

STATUS_PRINT_QUEUE_FULL

(0xC00000C6)

Print queue is full - too many queued items.

ERRSRV (0x02)

ERRqtoobig

(0x0032)

STATUS_NO_SPOOL_SPACE

(0xC00000C7)

Print queue is full - too many queued items.

ERRSRV (0x02)

ERRbaduid

(0x005B)

STATUS_SMB_BAD_UID

(0x005B0002)

The UID specified is not known as a valid ID on this server session, or the user identified by the UID does not have sufficient privileges.

ERRSRV (0x02)

ERRusestd

(0x00FB)

STATUS_SMB_USE_STANDARD

(0x00FB0002)

Write MPX support is not available. Use a standard write request.

ERRHRD (0x03)

ERRdata

(0x0017)

STATUS_DATA_ERROR

(0xC000003E)

EIO

A problem has occurred in the physical I/O.

ERRHRD (0x03)

ERRwrite

(0x001D)

ENXIO

The device associated with the file descriptor is a block-special or character-special file and the value of the file pointer is out of range.

ERRHRD (0x03)

ERRdiskfull

(0x0027)

STATUS_DISK_FULL

(0xC000007F)

ENOSPC

The file system is full.