I'm trying to copy files via SSH from one website to another (I use cpanel) using the following command once I'm logged in: cp /home/user/public_html/*.* /home/user/public_html (of course replacing 'user' with the actual user name) This only copies the files that are in public_html, not the folders.What command do I use to copy all files AND folders via SSH? Also, I'm using putty, and it prompts me to overwrite files that already exist (for each file, which can be kind of annoying). Is there a way to write the command so it overwrites what is already there?
Actually you are not doing this via SSH you are doing this VIA the shell, just an FYI.. To copy the directories you need to use the -r option so like this cp -r /home/user/public_html/*.* /home/user/public_html/ If you are being promoted for the overwrite then that means that the server administrator has setup cp as a command alias, simply type unalias cp before you use your cp command.
Use scp for copying from server to server scp -r /home/user/public_html/*.* user@desserverip:/home/user/public_html/ this will prompt you for password , enter it and there you go
I don't suppose you can use 'shell' to copy DBs can you? That would complete everything for me almost haha.