Home |
Function SMB3SInit |
Function SMB3SInitThis function initializes and starts the SMB3 server. void SMB3SInit(const char * HostName, const char * WorkGroup, int Interface, unsigned int Flags); ParametersHostNameThe NetBIOS name of the server. WorkGroupThe workgroup name of the server. If the server is not a member of a workgroup, use parameter "WORKGROUP" or NULL. InterfaceThe RTIP-32 interface number on which the NetBIOS daemon should publish the HostName. The server is still accessible on other interfaces through its IP address or a DNS name. FlagsThe parameter is currently not used and should be set to 0. All string parameters passed to this function must be permanently allocated (string constants, global variables, heap allocated, but not local/stack allocated) as only the pointers to the strings are copied. All strings may be accessed after the function returns. This function requires a LOOP_BACK interface. If none is installed, it will add one, which requires CFG_NIFACES to be large enough. It also opens numerous sockets which may require CFG_NUDPPORTS and CFG_NTCPPORTS to be increased. For optimal performance, CFG_TCP_SEND_WAIT_ACK should be set to 0 as the server uses many sockets in blocking mode. The I/O Accelerator can also improve the network throughput. This function creates two internal threads with names "SMB3 NetBIOS" and "SMB3 Server" with priorities and stack sizes defined through config parameters PRIOTASK_NORMAL and SIZESTACK_BIG. Once the SMB3 server has been started through this function, shares and users must be defined through functions SMB3SAddShare and SMB3SAddUser.
|