Solved: My Backup PC is out of room.

Status
This thread has been Locked and is not open to further replies. Please start a New Thread if you're having a similar issue. View our Welcome Guide to learn how to use this site.

stomp

Thread Starter
Joined
Jul 27, 2006
Messages
108
I have a PC set aside to just back up a server. Its faster for me to recover from the PC then tapes. Anyway I want just one folder to have the back up in and I want the back up to keep over writing the old data every 4 hours. But my batch is creating a new folder for every back up and I am now out of space. So my question is how should I modify my batch to overwrite?

Code:
@echo off
:: variables
set drive=c:\Backup
set folder=%date:~7,2%
set backupcmd=xcopy /s /c /d /e /h /i /r /k /y

echo ### Backing up directory...
%backupcmd% "G:\" "%drive%\%folder%"

echo Backup Complete!
@pause
 

JohnWill

Retired Moderator
Joined
Oct 19, 2002
Messages
106,425
Personally, I'd use a real backup utility. Cobian Backup can be scheduled to run as often as you like, and it automatically limits the number of copies it keeps, does full, differential, and incremental backups.
 

stomp

Thread Starter
Joined
Jul 27, 2006
Messages
108
Got it I just removed "set folder=%date:~7,2%" so now it will not make a folder every time. Oh and this is a real backup utility now and with task scheduler it backs up every 12 hours. And look how small it is.

@echo off
:: variables
set drive=c:\Backup
set backupcmd=xcopy /s /c /d /e /h /i /r /k /y

echo ### Backing up directory...
%backupcmd% "G:\" "%drive%\"

echo Backup Complete!
@pause
 
Status
This thread has been Locked and is not open to further replies. Please start a New Thread if you're having a similar issue. View our Welcome Guide to learn how to use this site.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 807,865 other people just like you!

Latest posts

Staff online

Members online

Top