PowerShell script exchange
Post Reply
Outlaw
Influencer
Posts: 24
Liked: 4 times
Joined: Mar 28, 2018 9:22 am
Contact:

Remove backup from disk w/o confirmation

Post by Outlaw »

Hello

I want remove backup from repository by scripts and use command

Code: Select all

$job = Get-VBRBackup -Name *test*
Remove-VBRBackup $job -FromDisk
but command request confirmation :(
In docs confirmation request with parameter -Confirm

What am I doing wrong ? :)
jorgedlcruz
Veeam Software
Posts: 1372
Liked: 619 times
Joined: Jul 17, 2015 6:54 pm
Full Name: Jorge de la Cruz
Contact:

Re: Remove backup from disk w/o confirmation

Post by jorgedlcruz » 1 person likes this post

Hello,
That flag is there for security, but if you want to delete backups without the confirmation try this:

Code: Select all

$job = Get-VBRBackup -Name *test*
Remove-VBRBackup -Backup $job -FromDisk -Confirm:$false
Please let us know
Jorge de la Cruz
Senior Product Manager | Veeam ONE @ Veeam Software

@jorgedlcruz
https://www.jorgedelacruz.es / https://jorgedelacruz.uk
vExpert 2014-2024 / InfluxAce / Grafana Champion
Outlaw
Influencer
Posts: 24
Liked: 4 times
Joined: Mar 28, 2018 9:22 am
Contact:

Re: Remove backup from disk w/o confirmation

Post by Outlaw »

Thanx !

All works fine :)
Post Reply

Who is online

Users browsing this forum: No registered users and 12 guests