Unable to run a task via command prompt (CMD.exe)

Questions about Cobian Reflector
Post Reply
vijaivisu
Posts: 3
Joined: 23 Nov 2023, 15:03

Unable to run a task via command prompt (CMD.exe)

Post by vijaivisu »

I am unable to run a task via command prompt (CMD.exe) or shortcut. I am getting an error message "The program is already running (perhaps as a service)". Shouldn't the program/service be running in the background for execution of a task via command prompt? How to solve this?
User avatar
cobian
Site Admin
Posts: 4644
Joined: 31 Oct 2020, 01:25
Location: Sweden
Contact:

Re: Unable to run a task via command prompt (CMD.exe)

Post by cobian »

If the service is installed and running, change the type of installation to Application .
--
Luis Cobian
Cobian Backup's creator
vijaivisu
Posts: 3
Joined: 23 Nov 2023, 15:03

Re: Unable to run a task via command prompt (CMD.exe)

Post by vijaivisu »

I already tried the type of installation as Application. I am getting the error message "The program is already running".
User avatar
cobian
Site Admin
Posts: 4644
Joined: 31 Oct 2020, 01:25
Location: Sweden
Contact:

Re: Unable to run a task via command prompt (CMD.exe)

Post by cobian »

Perhaps the program was already running? You cannot have both the service and the applicationn runninng at the same time.

Or perhaps the application is running onn anothher user's login?
--
Luis Cobian
Cobian Backup's creator
vijaivisu
Posts: 3
Joined: 23 Nov 2023, 15:03

Re: Unable to run a task via command prompt (CMD.exe)

Post by vijaivisu »

There is only one user. After installation, the program starts with windows startup. If I run the following command in command prompt, then the same error message "the Program is already running (perhaps as a service)" is displayed.

"C:\Program Files\Cobian Reflector\Cobian.Reflector.Application.exe" -bu

I tried installation type as a service and as an application (for all users). In both case I am getting the same error and the backup tasks are not executed.

Could you please guide me how to run the above mentioned command in command prompt without any error?
Last edited by vijaivisu on 28 Nov 2023, 02:36, edited 2 times in total.
User avatar
cobian
Site Admin
Posts: 4644
Joined: 31 Oct 2020, 01:25
Location: Sweden
Contact:

Re: Unable to run a task via command prompt (CMD.exe)

Post by cobian »

You say that the program is auto-starting with windows. Then the program is already running. If you do a

"C:\Program Files\Cobian Reflector\Cobian.Reflector.Application.exe" -bu

then you will get this message.

1- Use the instance that is already running

or

2. Close that instance first and then , run "C:\Program Files\Cobian Reflector\Cobian.Reflector.Application.exe" -bu
--
Luis Cobian
Cobian Backup's creator
vijaivisu
Posts: 3
Joined: 23 Nov 2023, 15:03

Re: Unable to run a task via command prompt (CMD.exe)

Post by vijaivisu »

Yes, That works. But I need the program running in the background for some reason (auto backup weekly) and I have to run some tasks manually before every shutdown of PC (I want to create a short cut to run the tasks and shutdown the PC using the program's Post-backup events option instead of using Windows default Start menu Shutdown option). Is there any way (any command) to run a task while the program is running in the background?
Last edited by vijaivisu on 29 Nov 2023, 08:48, edited 2 times in total.
User avatar
cobian
Site Admin
Posts: 4644
Joined: 31 Oct 2020, 01:25
Location: Sweden
Contact:

Re: Unable to run a task via command prompt (CMD.exe)

Post by cobian »

I see... You can just kill the process Cobian.Backup.Application.exe in your batch before starting it again.

Unfortunatly only one instance can be running at the same time. :cry:
--
Luis Cobian
Cobian Backup's creator
vijaivisu
Posts: 3
Joined: 23 Nov 2023, 15:03

Re: Unable to run a task via command prompt (CMD.exe)

Post by vijaivisu »

I tried your idea. If I include a command (Net Stop) to kill the service in the batch file. I could not run the file without UAC. Anyway thank you for your support.
User avatar
cobian
Site Admin
Posts: 4644
Joined: 31 Oct 2020, 01:25
Location: Sweden
Contact:

Re: Unable to run a task via command prompt (CMD.exe)

Post by cobian »

:OK
--
Luis Cobian
Cobian Backup's creator
Post Reply