Start Services Problem

Jul 16, 2010 at 10:05 PM
I could not start services. Following error occurs: The SupperSocketService service on Local Computer started and then stopped. Some services stop automatically if they are not in use by other services or programs.
Jul 17, 2010 at 1:22 AM

Is there some log in /Logs/error.log or /logs/info.log?

Jul 17, 2010 at 9:31 AM
Edited Jul 17, 2010 at 9:32 AM

There isn't log and My Operation system is win7

C:\RaMaZaN\SuperSocket\SocketService\bin\Debug>SuperSocket.SocketService.exe -c
Press any key to start server!

Unhandled Exception: System.ArgumentNullException: Value cannot be null.
Parameter name: type
   at System.Activator.CreateInstance(Type type, Boolean nonPublic)
   at System.Activator.CreateInstance(Type type)
   at SuperSocket.SocketServiceCore.SocketServerManager.Start(IConfig config) in
 C:\RaMaZaN\SuperSocket\SocketServiceCore\SocketServerManager.cs:line 80
   at SuperSocket.SocketService.Program.RunAsConsole() in C:\RaMaZaN\SuperSocket\SocketService\Program.cs:line 57
   at SuperSocket.SocketService.Program.Main(String[] args) in C:\RaMaZaN\SuperSocket\SocketService\Program.cs:line 36

C:\RaMaZaN\SuperSocket\SocketService\bin\Debug>pause
Press any key to continue . . .

Jul 17, 2010 at 4:30 PM

It seems that you missed some configurations.

The code below is the simplest configuration:


<socketServer>
		<servers>
		  <add name="Kerry's Remote Process Server" serviceName="remoteProcess" ip="Any" port="911" mode="Async">
			  <parameters>
				  <!--<add name="userSetting" value="FtpUser.xml" />-->
			  </parameters>        
		  </add>
		</servers>
		<services>
		  <add serviceName="remoteProcess" type="RemoteProcessService.RemoteProcessServer, RemoteProcessService" />
		</services>
</socketServer>	  

You can check the Sample "RemoteProcessService" in QuickStart for more information: http://supersocket.codeplex.com/SourceControl/changeset/view/55159#1124501

Jul 17, 2010 at 4:42 PM

After checking the code by your exception's stacktrace, I found this issue was caused by the service you use for server hasn't been configured.

For example, if you set serviceName as "remoteProcess" for server:

<add name="Kerry's Remote Process Server"  serviceName="remoteProcess" ip="Any" port="911" mode="Async">
 </add>


then you must define the service "remoteProcess" in services node:

 

<services>
<add serviceName="remoteProcess" type="RemoteProcessService.RemoteProcessServer, RemoteProcessService" /> </services>



On the other hand, I'll give proper exception/log message when this kind of error occurs.