Ahoy said:
for something which will at least produce an .ISO image of my computer
main c: drive (the .ISO image being saved on another partition for later
burning). Any ideas?
I am using a two piece script (makeabackup.bat and chvol.bat) which uses
tar, mkisofs and cdrecord to do a multi volume cd backup (incremental).
to start a backup use
makeabackup YYYY/MM/DD sources
example: makeabackup 2003/01/01 c:\
-> all files changed after 01.01.2003 will be written to (one or more) CDs
*the only things you have to take care of:*
get the right dev-parameter (chvol.bat) for your CDRW using
cdrecord -scanbus
put the files (tar.exe, mkisofs.exe, cdrecord.exe, cygwin1.dll,
makeabackup.bat and chvol.bat) into a directory which will NOT be
backuped, otherwise you will end up in a loop.
----- makeabackup.bat -----
@echo off
rem file MakeBackup.bat
rem author: Bernd Schmitt
rem last update: 2003/06/23
rem
rem a batch doing a backup using free software
rem TAR, MKISOFS, CDRECORD
rem put makeabackup.bat, chvol.bat, tar.exe,
rem mkisofs.exe, cdrecord.exe and cygwin1.dll
rem into the directory where the iso-file is created
rem so that all programs are written to CD
rem
rem error-checking
if "%1"=="" goto error
if "%2"=="" goto error
if not exist %2 goto errorsource
echo on
tar -cvf temp.tar -N %1 -M -L 700100 -F chvol.bat %2 %3 %4 %5 %6 %7 %8 %9
pause
chvol.bat
goto end
:errorsource
echo %2
echo does not exist
goto end
:error
echo usage:
echo makeabackup YYYY/MM/DD Source(s)
echo at least 2 parameters needed
echo you typed:
echo makeabackup %1 %2 %3 %4 %5 %6 %7 %8 %9
:end
----- chvol.bat -----
@echo off
rem file: chvol.bat
rem author: Bernd Schmitt
rem last update: 2003/06/23
rem
rem this file is part of a backup script
rem this batch waits for the user to put
rem an empty CD media into the CD-RW-drive
rem the iso-file is created and burned to CD
echo .
echo .
echo creating ISO filesystem in file temp.iso ...
echo -> mkisofs -v -o temp.iso temp.tar *.exe *.dll *.bat *.txt
mkisofs -v -o temp.iso temp.tar *.exe *.dll *.bat *.txt
echo .
echo .
echo Change madia ...
:cdempty
cdrecord dev=1,0,0 -toc >cdstatus.txt
grep -i "lba:" cdstatus.txt
if ERRORLEVEL 1 goto grep1
echo please put an empty cd media into CDRW drive
cdrecord dev=1,0,0 -eject >nul.txt
pause
cdrecord dev=1,0,0 -load >nul.txt
goto cdempty
:grep1
echo TOC seems to be empty - cd-media hopefully too
if EXIST cd-status.txt del cd-status.txt
echo Write ISO file to CD -> cdrecord -v dev=1,0,0 temp.iso
echo Please fit DEV-PARAMETERS on your PC! (cdrecord -scanbus)
cdrecord.exe -v dev=1,0,0 driveropts=burnfree temp.iso
if NOT ERRORLEVEL 0 goto cdempty