0
votes

i developed windows service working fine in my computer when i tried install it in windows server 2008 Standard 32 bit it is give me error

The inner exception System.ComponentModel.Win32Exception was thrown with the fol lowing error message:

The dependency service or group failed to start.

i checks all way to install the window service, by Batch by installutill and by using installshild every time i got this error log

Running a transacted installation.

Beginning the Install phase of the installation. See the contents of the log file for the c:\Program Files\H2A\KnittingControlSer vice\Knitting.exe assembly's progress. The file is located at c:\Program Files\H2A\KnittingControlService\Knitting.Inst allLog. Installing assembly 'c:\Program Files\H2A\KnittingControlService\Knitting.exe'. Affected parameters are:

logtoconsole =
   logfile = c:\Program Files\H2A\KnittingControlService\Knitting.InstallLog
   "assemblypath = c:\Program Files\H2A\KnittingControlService\Knitting.exe"

Installing service Knitting Control Service... Service Knitting Control Service has been successfully installed. Creating EventLog source Knitting Control Service in log Application... An exception occurred in the OnAfterInstall event handler of System.ServiceProce ss.ServiceInstaller. System.InvalidOperationException: Cannot start service Knitting Control Service on computer '.'. The inner exception System.ComponentModel.Win32Exception was thrown with the fol lowing error message: The dependency service or group failed to start.

An exception occurred during the Install phase. System.InvalidOperationException: An exception occurred in the OnAfterInstall ev ent handler of System.ServiceProcess.ServiceInstaller. The inner exception System.InvalidOperationException was thrown with the followi ng error message: Cannot start service Knitting Control Service on computer '.'. . The inner exception System.ComponentModel.Win32Exception was thrown with the fol lowing error message: The dependency service or group failed to start.

The Rollback phase of the installation is beginning. See the contents of the log file for the c:\Program Files\H2A\KnittingControlSer vice\Knitting.exe assembly's progress. The file is located at c:\Program Files\H2A\KnittingControlService\Knitting.Inst allLog. Rolling back assembly 'c:\Program Files\H2A\KnittingControlService\Knitting.exe' . Affected parameters are: logtoconsole = logfile = c:\Program Files\H2A\KnittingControlService\Knitting.InstallLog assemblypath = c:\Program Files\H2A\KnittingControlService\Knitting.exe Restoring event log to previous state for source Knitting Control Service. Service Knitting Control Service is being removed from the system... Service Knitting Control Service was successfully removed from the system.

The Rollback phase completed successfully.

The transacted install has completed. The installation failed, and the rollback has been performed."

1
Properly formatted the text - Alexei - check Codidact
yes i did but the same error still exists - Monzer Al.khiami

1 Answers

0
votes

I've had similar issues in the past and they have often turned out to be permission-related. Are you running your install script as an "Administrator"? (right-click on script -> "Run As Administrator")