Can not import SQL dump file into Google Cloud SQL.

453 views
Skip to first unread message

Abhishek Pandey

unread,
Oct 7, 2013, 12:38:14 PM10/7/13
to google-cloud...@googlegroups.com
Hi guys.

I want to migrate that database on google cloud sql.
Things I've done so far is: 

 - Created a bucket on google cloud storage via gsutil
 - Uploaded the sql dump in the bucket.
 
Error:
 - When I am trying to upload it to the Google cloud sql, it throws an error!

while importing into Cloud SQL,   I wrote: gs://mybucket/abc.sql while database name was left blank.

database name: abc.sql
bucket name: mybucket
Used 'uses db_name' at the start of my database.



cloud.jpg

Amit Mondal

unread,
Oct 7, 2013, 12:48:34 PM10/7/13
to google-cloud...@googlegroups.com
Did you follow the instruction for import to cloud sql here?



How did you generate the dump file?

Common mistakes are:
1) Forget to create or specify the data base to use?
2) Database already contains tables, and there is conflict with the import, etc.





--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/c5e2b0e2-8406-468c-82ac-71e4cc623663%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Abhishek Pandey

unread,
Oct 7, 2013, 12:54:15 PM10/7/13
to google-cloud...@googlegroups.com
Thanks for replying amit.
Yes I followed what is mentioned in the tutorial/ intructions.
I have mentioned which database to use in the sql file.

I exported the dump file using a xamp server. Is that the right way?

Amit Mondal

unread,
Oct 7, 2013, 12:59:31 PM10/7/13
to google-cloud...@googlegroups.com
Not sure about the xamp server. As long as it is doing something silimilar to

mysqldump --databases database_name [-u username -p password] --hex-blob > database_file.sql


it should be fine. What is your instance name?




--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.

Abhishek Pandey

unread,
Oct 7, 2013, 1:11:09 PM10/7/13
to google-cloud...@googlegroups.com
I have mysql installed on my machine but when I tired to generate it through the command prompt, it was generating an error.
Hence I used xamp instead.
Can you tell me the steps to generate the SQL dump ?
instance name is :xz-vocal-camera-e:testcom
 
P.S- I used example terms in the first post.
Thanks.

On Monday, October 7, 2013 10:08:14 PM UTC+5:30, Abhishek Pandey wrote:

Abhishek Pandey

unread,
Oct 8, 2013, 10:17:30 AM10/8/13
to google-cloud...@googlegroups.com
Got that issue solved.
Generated the dump again using mysqldump.
I was missing the commas on the uses command.
USE 'abc'

abc-databasename
Reply all
Reply to author
Forward
0 new messages