There are multiple ways to import database dumps in MySQL/MariaDB. First way to import databases it to use mysqldump utility, like
LinuxShell> mysql database_name < backup-file.sql
Mind the < direction.
If you have a huge Database then use source command of MySQL. Before that you must set autocommit = false which is true in its default sate. This drastically increase performance.
mysql> use database_name;
mysql> SET autocommit=0 ;
mysql> source /FULL/PATH/TO/SQL/FILE.sql ; COMMIT ;