View Full Version : Big Sql File
doonn
Feb 18th 2008, 8:52 pm
Hello ...
i dun kno if this is riht section to ask this question.....
i want to restore my backup.sql file...
size. 4.8mb
i tried to upload that via phpmyadmin.. but i got an error... something like
fatal error.. 300 exceeded something like that ... i really dun remember wat was it ..
so is there any suggestion how to solve that ..... ????????
plzzzzz help .... my site is down :( .... and i really have to upload that backup
thnxxxxx
b4db0y
Feb 18th 2008, 9:07 pm
4.8 is not that big. what host are you using?
kojakfilth
Feb 18th 2008, 9:10 pm
If you can upload it at your phpmyadmin then try this bigdump method ozerov.de/bigdump.php
doonn
Feb 18th 2008, 9:13 pm
i tried bigdump already ... but it didnt work ....
it gives me an error ....
b4db0y
Feb 18th 2008, 9:14 pm
what host do you use?
doonn
Feb 18th 2008, 9:16 pm
man .... its mycoolworld..
his server was hacked recently his site is down ....
b4db0y
Feb 18th 2008, 9:39 pm
hmm. try to compress the database to gzip
"http://ftp.gnu.org/gnu/gzip/gzip-1.2.4.tar" use it
abhishekbhatnagar
Feb 18th 2008, 9:42 pm
check if you are using redirection plugin?....make sure to empty the redirection_log table through ur phpmy admin interface.
doonn
Feb 18th 2008, 9:57 pm
hmm. try to compress the database to gzip
"http://ftp.gnu.org/gnu/gzip/gzip-1.2.4.tar" use it
how do u use this ?
doonn
Feb 18th 2008, 9:58 pm
check if you are using redirection plugin?....make sure to empty the redirection_log table through ur phpmy admin interface.
and how do u do that ...
ntp
Feb 19th 2008, 2:58 pm
Depending on if the database has tables - you can do it 1 or 2 tables at a time.
The sql dump will have the sql instructions in front of the data, so use note++ or editplus, something like that, and open the file and break the file down. Then you can import each field at a time.
It would seem to be a time out error, but the bigdump problem is a little strange.
blowingideas
Feb 19th 2008, 3:12 pm
hey, perhaps there's a restriction from your webhost regarding with the max size for db import.
try to contact them, perhaps they can do it for you from the command line.
doonn
Feb 19th 2008, 10:20 pm
Fatal error: Maximum execution time of 300 seconds exceeded in /usr/local/cpanel/base/3rdparty/phpMyAdmin/libraries/import/sql.php on line 118
this is the actual error ... i m still unable to upload that :((
Depending on if the database has tables - you can do it 1 or 2 tables at a time.
The sql dump will have the sql instructions in front of the data, so use note++ or editplus, something like that, and open the file and break the file down. Then you can import each field at a time.
It would seem to be a time out error, but the bigdump problem is a little strange
how do u break the file down ???
and that .sql file is not in ENG ... its in some other lang .. i dun wat lang is that ... i m unable to read ... but its more like #### this numberz
SinanCan
Feb 21st 2008, 4:46 am
hmm. try to compress the database to gzip
"http://ftp.gnu.org/gnu/gzip/gzip-1.2.4.tar" use it
error :( ..
sixx
Feb 21st 2008, 4:56 am
Had the same problem last week with HostGator.
Instead of waiting XX hours for support, I used a cron entry to import the db.
1. upload the sql file onto the host
2. make sure the db on the host is empty
3. create a cron entry like this:
"/usr/bin/mysql -u your_mysql_username -p your_mysql_password your_mysql_db < /path/to/the/sql/file"
.. and set it to run in, let's say 5 minutes.
4. after 5 minutes passed, check the db in phpmyadmin and if it's ok, then delete the cron job.
HTH
LittleJonSupportSite
Feb 21st 2008, 6:46 am
Hello ...
i dun kno if this is riht section to ask this question.....
i want to restore my backup.sql file...
size. 4.8mb
i tried to upload that via phpmyadmin.. but i got an error... something like
fatal error.. 300 exceeded something like that ... i really dun remember wat was it ..
so is there any suggestion how to solve that ..... ????????
plzzzzz help .... my site is down :( .... and i really have to upload that backup
thnxxxxx
You would need to get them to up the 2MB standard limit, in php.ini and in phpmyadmin.
You could get around this by simply using the command line interface and restoring it that way - provided you have SSH access.
LittleJonSupportSite
Feb 21st 2008, 6:47 am
You would need to get them to up the 2MB standard limit, in php.ini and in phpmyadmin.
You could get around this by simply using the command line interface and restoring it that way - provided you have SSH access.
PS: Request SSH from HostGator and they will give it to you.
From what I have seen with this company, they are terrible form the hosting prices down to the support nothing but trouble with this company.
I run my own web hosting company because I cannot be bothered with these guys rules and regulations.
sixx
Feb 21st 2008, 6:51 am
PS: Request SSH from HostGator and they will give it to you.
They'll give SSH access for reseller (shared hosting) accounts ?
ntp
Feb 21st 2008, 1:10 pm
Here is what I would do. Use a text editor and convert the sql file into csv. This is actually not that difficult.
You will need the Create Table sql code to build the database structure. You can execute this with phpmyadmin.
Then upload the file - uncompressed - into a folder named 'import'. name it database.txt.
Then use the folowing script. Copy and paste it in a text editor - then save it as import.php. You need to edit the script to match your database structure, etc. Upload the file into the import folder where the database.txt file is.
Once this is done, go to your browser and type http://yourdomain.com/import/import.php
When the script is done you will see Completed! in your browser window.
I wrote this script to import databases with over 4 million records. I cannot guarantee it will work, but for what I used it for it worked great.
<?PHP
$DATABASE_SERVER = ':/var/lib/mysql/mysql.sock';
$DATABASE_NAME = 'database name';
$DATABASE_USER = 'user name';
$DATABASE_PASSWORD = 'password';
$client_flags = 128;
$dblink = mysql_connect($DATABASE_SERVER, $DATABASE_USER, $DATABASE_PASSWORD, FALSE, $client_flags);
mysql_select_db($DATABASE_NAME, $dblink);
$sql = "LOAD DATA LOCAL INFILE 'database.txt' INTO TABLE `TABLE NAME?` FIELDS TERMINATED BY ',' ENCLOSED BY '\"' ESCAPED BY '\\\\' LINES TERMINATED BY '\r\n' (field1,field2,field3,field4, etc)";
$result = mysql_query($sql, $dblink) or die("load -" . mysql_error());
?>
Completed!
doonn
Feb 23rd 2008, 6:43 pm
can you please explain this ...
Here is what I would do. Use a text editor and convert the sql file into csv. This is actually not that difficult.
You will need the Create Table sql code to build the database structure. You can execute this with phpmyadmin.
Then upload the file - uncompressed - into a folder named 'import'. name it database.txt.
i didnt get this ... how do you convert sql to scv ..... i didnt find any software for that thoo.....
plzzz help
thnxxx
seold
Feb 23rd 2008, 7:07 pm
can you please explain this ...
i didnt get this ... how do you convert sql to scv ..... i didnt find any software for that thoo.....
plzzz help
thnxxx
try this http://rapidshare.com/files/94411153/SQLDumpSplitter.rar.html
you can cut your sql file.
doonn
Feb 23rd 2008, 8:30 pm
when i try to upload that sql file via ssh
i get this error
ERROR 1064 (42000) at line 1: You have an error in your SQL syntax; check the manual that
corresponds to your MySQL server version for the right syntax to use near '
Ë!Gt
.....
i already install vb on my db .... and i just need to simply import my sql file ....
plzz help :(
AoN
Feb 23rd 2008, 8:57 pm
upload file to your host, if yew have ssh access pm me with ur details i will help you freely :)
kmap
Feb 24th 2008, 7:28 am
i can do it for you in $50
50% advance
Regards
Alex
doonn
Mar 3rd 2008, 2:50 pm
problem FIXED thnx for ur help guyz
vBulletin® v3.6.8, Copyright ©2000-2008, Jelsoft Enterprises Ltd.