Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Merkas

Pages: [1]
1
Thanks,

I'll add the del to the batch  :smiley:

Added this to the batch file before calling the registry backup;

IF /i EXIST "%InsRegPath%\%computername%" rd /s/q "%InsRegPath%\%computername%">Nul

Works great. Thanks again

2
Thanks for the quick reply.

The "Keep at least" backups is set to 0
The "Delete Backups ___ Days or older" is set to 0
The "Only do 1 Auto Backup per Day" is checked

Here is what the settings.ini file looks like;

[main]
ChangeBackupLocation=1
BackupLocation="C:\Jobs\552\SoftController\ct\graphics\links\Registry"
CheckForUpdates=0
AutoDeleteOldBackups=1
ScheduleUser=True
ScheduleSystem=False
VSSexe=Auto Detect (Default)
FallBackMethod=1
DefaultBackupName=Manual Backup
DefaultAutoBackupName=Auto Backup
DidCloseProperly=True
AlwaysUseFallBackMethod=1
BackupsToKeep=0
Only1AutoBackupPerDay=1
AutoDeleteOldBackupsDays=0

The batch file is run from a thumb drive and the location for the register backup it determined at run time and different per PC. So the Settings.ini file is created by the batch file. Here is what the batch file looks like;

:: -----------------------------------------------------------------------------------
:: Reg Backup
:: -----------------------------------------------------------------------------------
@echo [main]>Settings.ini
for %%A in ("ChangeBackupLocation=1") do @echo %%~A>>Settings.ini
@echo BackupLocation="%InsRegPath%">>Settings.ini
for %%A in ("CheckForUpdates=0") do @echo %%~A>>Settings.ini
for %%A in ("AutoDeleteOldBackups=1") do @echo %%~A>>Settings.ini
@echo ScheduleUser=True>>Settings.ini
@echo ScheduleSystem=False>>Settings.ini
@echo VSSexe=Auto Detect (Default)>>Settings.ini
for %%A in ("FallBackMethod=1") do @echo %%~A>>Settings.ini
@echo DefaultBackupName=Manual Backup>>Settings.ini
@echo DefaultAutoBackupName=Auto Backup>>Settings.ini
@echo DidCloseProperly=True>>Settings.ini
for %%A in ("AlwaysUseFallBackMethod=1") do @echo %%~A>>Settings.ini
for %%A in ("BackupsToKeep=0") do @echo %%~A>>Settings.ini
for %%A in ("Only1AutoBackupPerDay=1") do @echo %%~A>>Settings.ini
for %%A in ("AutoDeleteOldBackupsDays=0") do @echo %%~A>>Settings.ini

TweakingRegistryBackup.exe -auto

if not errorlevel 0 goto Warning
:: -----------------------------------------------------------------------------------

Really the only thing that changes it the backup location (%InsRegPath%).

If you run TweakingRegistryBackup.exe from the GUI with these settings it does delete the old backup as you would expect. If you run it from the batch file the old backups are not deleted. I think the reason the old backups are not deleted is because the "Delete Backups ___ Days or older" seems to default back to 30 even though this is not seen in the Settings.ini file. You do see it in the GUI.

Thanks

3
Hi,

If you run TweakingRegistryBackup from the GUI and set the Delete Backups 0  Days or older in the Settings -> Auto Delete Old Backups. And then run the backup it deletes all of the old backups but the ones done today. I'm good with this.

Now if you run the TweakingRegistryBackup -auto from a batch file with the same settings (EX: AutoDeleteOldBackupsDays=0) it doesn't delete old backups at all. If you set the Delete Backups 1  Days then it at least deletes up to yesterday. I'd like to only have one backup keep if I could.

Is there a setting in the ini I'm missing?

Thanks

Pages: [1]