Backup & Restore sites with stsadm command
For Backup :
For site collection backup
stsadm -o backup -url <URL name> -filename <file name> [-nositelock] [-overwrite]
For Restore :
For site collection restore
stsadm -o restore -url <URL name> -filename <file name> [-hostheaderwebapplicationurl] <Web application URL> [-overwrite]
To Take Backup of Site
C:\Progra~1\Common~1\Microsoft Shared\Web Server Extensions\14\BIN> stsadm -o backup - url http://testserver/sites/sitename -filename c:\backup\bk.dat
To Restore Whole Site
C:\Progra~1\Common~1\Microsoft Shared\Web Server Extensions\14\BIN> stsadm -o restore - url http://server/sites/newsite -filename c:\backup\bk.dat
If you want to overwrite existing web site then use -overwrite .
Comments