Create a backup of your website files with tar, backup database with phpmyadmin
Step
Create website backup using tar
SSH into your server then use the following format to backup your site folder
tar -czf bkup.tar.gz foldertobackup
Now download that file from your server. I use ftp to do that
backup database from phpmyadmin
- go to phpmyadmin site from cpanel or however you normally get there.
- click on the name of your database on the left
- click on the export tab at the top
- click go
- now move that sql file to the folder location you are keeping your backup(Desktop)
Alternatively you can save your database through the command line like you used tar if you have access to mysqldump with your username
mysqldump -u database_username --password="database_password" --databases database_name1 database_name2 > database_backup_file.sql