Closing CMD Window with CMD backup command

Backup agent for Microsoft Windows servers and workstations (formerly Veeam Endpoint Backup FREE)

Closing CMD Window with CMD backup command

Veeam Logoby john510 » Sun Oct 11, 2015 11:19 pm

I created a bat file with the following command to start a full backup with Veeam, but cant get the CMD window to close automaticlly ?
------------------------------------
Creating Standalone Full Backups

To create a standalone full backup, use a command with the following syntax:

"C:\Program Files\Veeam\Endpoint Backup\Veeam.EndPoint.Manager.exe" /standalone

------------------
john510
Influencer
 
Posts: 11
Liked: never
Joined: Tue Jun 02, 2015 11:28 pm

Re: Closing CMD Window with CMD backup command

Veeam Logoby Dima P. » Mon Oct 12, 2015 7:52 am

Hi john510,

Try to use the following
Code: Select all
//your script part//
exit
Dima P.
Veeam Software
 
Posts: 6242
Liked: 440 times
Joined: Mon Feb 04, 2013 2:07 pm
Location: SPb
Full Name: Dmitry Popov

Re: Closing CMD Window with CMD backup command

Veeam Logoby john510 » Mon Oct 12, 2015 12:00 pm

My script
--------------------------------------
"C:\Program Files\Veeam\Endpoint Backup\Veeam.EndPoint.Manager.exe" /standalone
exit
--------------
does not close the window
john510
Influencer
 
Posts: 11
Liked: never
Joined: Tue Jun 02, 2015 11:28 pm

Re: Closing CMD Window with CMD backup command

Veeam Logoby PTide » Mon Oct 12, 2015 12:07 pm 1 person likes this post

Hi,

assume your intial batch was like
Code: Select all
some_software.exe
exit


try to change it to
Code: Select all
start some_software.exe
exit
PTide
Veeam Software
 
Posts: 3019
Liked: 246 times
Joined: Tue May 19, 2015 1:46 pm

Re: Closing CMD Window with CMD backup command

Veeam Logoby john510 » Mon Oct 12, 2015 6:03 pm

I tried this below:

---------------------------------
Code: Select all
start "C:\Program Files\Veeam\Endpoint Backup\Veeam.EndPoint.Manager.exe" /standalone
exit

--------------------------------------
it opened the cmd window for second and did close it but the backup did NOT run then..
john510
Influencer
 
Posts: 11
Liked: never
Joined: Tue Jun 02, 2015 11:28 pm

Re: Closing CMD Window with CMD backup command

Veeam Logoby PTide » Tue Oct 13, 2015 9:57 am

Please try

Code: Select all
cd "C:\Program Files\Veeam\Endpoint Backup\"
start Veeam.Endpoint.Manager.exe /standalone
exit
PTide
Veeam Software
 
Posts: 3019
Liked: 246 times
Joined: Tue May 19, 2015 1:46 pm

[MEGRED] Start endpoint backup remotely

Veeam Logoby lowlander » Tue Oct 20, 2015 12:55 pm

Hi Can we start a Endpoint backup remotely ?

E.g. powershell

Any examples are welcome :)
lowlander
Service Provider
 
Posts: 267
Liked: 20 times
Joined: Sun Dec 28, 2014 11:48 am

Re: Closing CMD Window with CMD backup command

Veeam Logoby Dima P. » Wed Oct 21, 2015 12:34 pm

Hi lowlander,

VEB since the latest update has two scripting options to start a backup (either incremental or standalone full backup). Check this Help Center article for more details: Performing Backup with Command Line Interface. This scrips can be wrapped up anyway you want or used to start a backup remotely.
Dima P.
Veeam Software
 
Posts: 6242
Liked: 440 times
Joined: Mon Feb 04, 2013 2:07 pm
Location: SPb
Full Name: Dmitry Popov

Re: Closing CMD Window with CMD backup command

Veeam Logoby lowlander » Thu Oct 22, 2015 4:06 pm

Thanks !

remote execution with psexec works great.
lowlander
Service Provider
 
Posts: 267
Liked: 20 times
Joined: Sun Dec 28, 2014 11:48 am

Re: Closing CMD Window with CMD backup command

Veeam Logoby Dima P. » Thu Oct 22, 2015 8:08 pm

You are welcome and I am glad to hear it just works™ :mrgreen:
Dima P.
Veeam Software
 
Posts: 6242
Liked: 440 times
Joined: Mon Feb 04, 2013 2:07 pm
Location: SPb
Full Name: Dmitry Popov

Re: Closing CMD Window with CMD backup command

Veeam Logoby Gostev » Fri Oct 23, 2015 3:20 pm

start should do it as well (as it is designed launches the application asynchronously)...
Gostev
Veeam Software
 
Posts: 21390
Liked: 2349 times
Joined: Sun Jan 01, 2006 1:01 am
Location: Baar, Switzerland

Re: Closing CMD Window with CMD backup command

Veeam Logoby lollolcctr » Wed Dec 16, 2015 2:45 pm

I've got te same(?) problem. When I launch a backup with "Veeam.EndPoint.Manager.exe /backup" under "Start / run" (with or without Batch File makes no difference),
a black commandline window is opened as long as the backup runs. Is it possible to hide this black window?
lollolcctr
Novice
 
Posts: 8
Liked: never
Joined: Thu Jan 16, 2014 8:41 am
Full Name: Torsten Rudolf

Re: Closing CMD Window with CMD backup command

Veeam Logoby PTide » Wed Dec 16, 2015 3:03 pm

Hi,

Have you tried this already?

Code: Select all
cd "C:\Program Files\Veeam\Endpoint Backup\"
start Veeam.Endpoint.Manager.exe /standalone
exit
PTide
Veeam Software
 
Posts: 3019
Liked: 246 times
Joined: Tue May 19, 2015 1:46 pm

Re: Closing CMD Window with CMD backup command

Veeam Logoby lollolcctr » Thu Dec 17, 2015 5:57 am

PTide wrote:Hi,

Have you tried this already?

Code: Select all
cd "C:\Program Files\Veeam\Endpoint Backup\"
start Veeam.Endpoint.Manager.exe /standalone
exit


Yes, i did, the behaviour is the same, only that the backup runs longer because of the full backup. The problem is not
the "starting window" but the "Veeam.Endpoint.Manager.exe window".

It looks like this:

Image

I'd really like to start it in the background as Windows Task, but the window always shows up :(
lollolcctr
Novice
 
Posts: 8
Liked: never
Joined: Thu Jan 16, 2014 8:41 am
Full Name: Torsten Rudolf

Re: Closing CMD Window with CMD backup command

Veeam Logoby PTide » Thu Dec 17, 2015 7:51 am

Ok, now I see the problem. Please try placing the following code into a .bat file and start it:

Code: Select all
cd "C:\Program Files\Veeam\Endpoint Backup\"
start Veeam.Endpoint.Manager.exe /backup
TIMEOUT /T10
taskkill /IM Veeam.Endpoint.Manager.exe
exit


The things is that endpoint manager still needs a few seconds to start the job, that's why TIMEOUT is placed there.

Thank you.
PTide
Veeam Software
 
Posts: 3019
Liked: 246 times
Joined: Tue May 19, 2015 1:46 pm

Next

Return to Veeam Agent for Windows



Who is online

Users browsing this forum: No registered users and 9 guests