Windows Server 2003
1819681 Members
3540 Online
109605 Solutions
New Discussion юеВ

How to create an automatic service by using "sc" command

 
Hanry Zhou
Super Advisor

How to create an automatic service by using "sc" command

I am trying to put the following command in services. The command "lmgrd" is locate in the directory of C:\dffile, and this command is going to use the file "reference.lic" under the same directory. The following is the the command line that I will use manually in the DOS command line:

C:\>cd
c:\dflicsvr
C:\dflicsvr>lmgrd -c c:\dffile\reference.lic -z &

Would you please help me out to put this service in the registry by using "sc" command?

I tried different way, but all did not work out.

Thanks in advance!

lmgrd -c c:\path_to_license_file -z &
none
3 REPLIES 3
Michal Kapalka (mikap)
Honored Contributor

Re: How to create an automatic service by using "sc" command

Hanry Zhou
Super Advisor

Re: How to create an automatic service by using "sc" command

mikap,

the difficulty to use sc in this case is the command "mgrd" also has -c option as well as referencing another file "reference.lic" within the same directory, and then "-z" option in the end. So, I don't know how I should put all these together. Would you mind to write down whole sentence?
none
Hanry Zhou
Super Advisor

Re: How to create an automatic service by using "sc" command

using task
none