Access denied» error during the import process might be due to the privileges mismatch for the DEFINERs between the database exported and the database going to be imported. I faced the same situation and below command works well for me to import the database successfully.

cat db1.sql | sed -e ‘s/DEFINER[ ]*=[ ]*[^*]*\*/\*/’ | mysql -u user1 -p db1