Using Telnet or SSH to delete file If you have a command-line login (telnet or ssh), you can enter the following commands to make backup copies of the files you need to keep and to delete ONLY the wordpress files in your directory (plus .htaccess). If you’ve customized other files (like
index.php) not included by the
cp commands below, copy them as well:
cp wp-config.php .htaccess backup
cp -R wp-content backup
rm wp*.php .htaccess license.txt readme.html xmlrpc.php
rm -rf wp-admin wp-includes
cp backup/wp-config.php .
After you have finished with the upgrade, you can restore any customizations to your templates or plugins from your backup directory. For example, use
cp backup/index.php . to restore
Alternatively, using SSH, you could copy
wp-config.php, .htaccess, and any content files you’ve added or altered into the newwordpress directory. Then, rename the old one (to archive it), and move the new one into its place.