Import/Export DB via SSH
A short note found on the Internet on the import / export of the database via SSH
DB import
mysql -u dbuser -p dbname < dbdumpfile
DB export (backup)
mysqldump -u dbuser -p dbname > filename
upd. In case the host starts to swear
mysqldump: Error: 'Access denied; you need (at least one of) the PROCESS privilege(s) for this operation' when trying to dump tablespaces
We run the same command but with the argument --no-tablespaces
mysqldump --no-tablespaces -u dbuser -p dbname > filename