Replace http://sites/site with your site name and filename with the required filename you want. The switch overwrite will overwrite the file if the name you specified already exist. For getting the complete help of export, try the following command

stsadm –help export

If the exporting runs without error, you will get the following message

For importing you can use the import statement with stsadm.

stsadm –o import –url http://newsites/site –filename filename.cab

On success you will get a similar screen with the message “Operation completed successfully” at the end.