尝试导入sql时,phpMyAdmin文件太大错误 [英] PhpMyAdmin File too large error when trying to import sql

查看:83
本文介绍了尝试导入sql时,phpMyAdmin文件太大错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

伙计们,我正在尝试在客户端服务器上使用phpmy admin导入数据库(.sql)文件.

Hey folks, I am trying to import a database (.sql) file using phpmy admin on a clients server.

我收到一个文件太大的错误,甚至以为我可以将文件分成几部分,但是我仍然收到错误.上传大小为50MiB,我要导入的文件为90mb(对于数据库).

I get a file too large error even thought I have the option to break the file into pieces etc but I still get the error. The upload size is 50MiB and the file I am trying to import is 90mb (for the db.)

我在MAM中有相同的错误,并且知道可以更改maz_size_limit和类似的内容,但是我不确定在客户端服务器上要做什么.我可以访问cpanel,但看不到任何选项.

I had the same error in MAM and know I could change the maz_size_limit and similar things, but I am not sure what to do on the clients server. I have access to the cpanel but can not see any options.

即使将文件设置为64MB,我也可以在服务器上导入相同的文件,因为它可以将其切碎并导入.

I can import the same file on my server, even though its set to 64MB,as it is able to chop up and import.

我在这里有什么选择?

我尝试使用mysequal pro,因为它在我的本地计算机上可用于MAMP,但无法在此客户端服务器上使用.

I tried to use mysequal pro as it worked for MAMP on my local comp but am not able to do it for this clients server.

有什么想法吗?

推荐答案

您对客户的服务器具有哪种访问权限?

What kind of access do you have to your client's server?

如果您确实具有终端访问权限,那么以上答案将起作用.

If you do have terminal access then the above answers will work.

否则,完成此操作的非常丑陋的方法是可以创建一个.htaccess文件来更改PHP设置,以获取通过PHPmyAdmin上传的sql文件.

Otherwise, a very ugly way to get it done is that you could create an .htaccess file to change PHP settings to get the sql file uploaded through PHPmyAdmin.

在您的.htaccess文件中,您应该放置:

In your .htaccess file you would put:

php_value upload_max_filesize 80M
php_value post_max_size 80M
php_value max_execution_time 300
php_value max_input_time 300

确保完成后立即删除.htaccess文件.同样,如果您客户的服务器使用的Apache设置为不允许替代,则此方法也将不起作用.

Make sure you delete your .htaccess file as soon as you are done. Also, this will not work if your client's server is using Apache set not to allow overrides.

这篇关于尝试导入sql时,phpMyAdmin文件太大错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆