How-to upload database via SSH?

xprotect

Verified User
Joined
Feb 10, 2006
Messages
72
One of my users have big db (80MB) and he wanna to upload it but php have 8mb limit.
I have this on server hdd how to upload it via SSH?
# mysql SOMETHING - i mean this. (should i first unpack db file?)
 
Doing it through ssh has been covered on these forums. Basically you upload the file through some other means, for example, ftp. Then through ssh you would simply import the database. The exact command is floating around it goes something like the following, but not exactly:
Code:
mysql -u[b]Username[/b] -p[b]Password[/b] [b]existing_database[/b] < [b]database.sql[/b]
 
xprotect said:
# mysql SOMETHING - i mean this. (should i first unpack db file?)

If it already has a .sql extension then you don't need to. If it doesn't and it has a standard compression extension (.tar.gz and whatnot), then you do need to extract it before importing the sql.
 
Back
Top