I've created a database in the remote machine. Currently, the database is empty and I need to import using a backup(
.sql) file. The backup file is in my local machine, it is a
40gb file. And the remote machine has an empty space of about
So, if I try to upload the backup file into the remote machine, then it will be impossible to import into the database(remote machine will be running out of space). The only possible solution looks like, pointing the server to use the location of the local machine's backup file and to import. Is there any command to work on this?
I have tried the following commands
bash > mysql -h hostname -u user -pPassword databasename < /Users/path/to/file/backup.sql > update.log
But, it returns an error saying
bash: no such file or directory.
I'm sure the file is present within my local machine.
Does any one have any idea on how to import sql file. Or is there any alternate ways to do this?
Local machine is running on
Remote machine is
I'm using SSH to connect with remote machine.