zenky Posted June 3, 2017 Share Posted June 3, 2017 (edited) Buen día compañeros. Como dice el títlo de tema, antes tenía php 5.3 y lo actualice a 5.6 para que hubiera mayor rendimiento mi tienda prestashop, y resulta que empezó a dar problemas. A veces que estoy navegando en mi tienda y me marca los siguientes errores: "Enlace para la base de datos no puede ser establecido: SQLSTATE[HY000] [2002] Connection refused" "Enlace para la base de datos no puede ser establecido: SQLSTATE[HY000] [2002] No such file or directory" Simplemente doy F5 y sigue funcionando. Este error es intermitente y no entiendo el porqué. Antes no sucedía, solo empezó a suceder desde que actualicé a php 5.6. Cualquier comentario es bienvenido. Muchas gracias y saludos. Edited June 3, 2017 by zenky (see edit history) Link to comment Share on other sites More sharing options...
jmginer Posted June 4, 2017 Share Posted June 4, 2017 Actualiza Prestashop también. Link to comment Share on other sites More sharing options...
zenky Posted June 9, 2017 Author Share Posted June 9, 2017 (edited) Ya lo hice, incluso hice una instalación de prestashop nueva y marca los mismos errores Alguna otra idea de ¿cuál puede ser el problema? Edited June 9, 2017 by zenky (see edit history) Link to comment Share on other sites More sharing options...
Soy.es Posted June 10, 2017 Share Posted June 10, 2017 El problema lo tienes en el mysql por alguna razón esa versión de PHP 5.6 no esta trabajando bien. ¿Qué hosting es? ¿Has hablado con ellos? Saludos Link to comment Share on other sites More sharing options...
zenky Posted June 10, 2017 Author Share Posted June 10, 2017 Estoy utilizando hostgator un vps. Estuve revisando el log de mysql, y cuando sucede este error, me muestra el siguiente log: 170610 15:01:19 [Note] Plugin 'FEDERATED' is disabled. 170610 15:01:19 InnoDB: The InnoDB memory heap is disabled 170610 15:01:19 InnoDB: Mutexes and rw_locks use GCC atomic builtins 170610 15:01:19 InnoDB: Compressed tables use zlib 1.2.3 170610 15:01:19 InnoDB: Using Linux native AIO 170610 15:01:19 InnoDB: Initializing buffer pool, size = 128.0M 170610 15:01:19 InnoDB: Completed initialization of buffer pool 170610 15:01:19 InnoDB: highest supported file format is Barracuda. InnoDB: Log scan progressed past the checkpoint lsn 23297358 170610 15:01:19 InnoDB: Database was not shut down normally! InnoDB: Starting crash recovery. InnoDB: Reading tablespace information from the .ibd files... InnoDB: Restoring possible half-written data pages from the doublewrite InnoDB: buffer... InnoDB: Doing recovery: scanned up to log sequence number 23297368 170610 15:01:19 InnoDB: Waiting for the background threads to start 170610 15:01:20 InnoDB: 5.5.56 started; log sequence number 23297368 170610 15:01:20 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306 170610 15:01:20 [Note] - '0.0.0.0' resolves to '0.0.0.0'; 170610 15:01:20 [Note] Server socket created on IP: '0.0.0.0'. 170610 15:01:20 [Note] Event Scheduler: Loaded 0 events 170610 15:01:20 [Note] /usr/libexec/mysqld: ready for connections. Version: '5.5.56' socket: '/var/lib/mysql/mysql.sock' port: 3306 MySQL Community Server (GPL) by Remi estuve leyendo leyendo y segun puede ser una tabla o base de datos corrupta, pero seguí los pasos que mencionan en otras páginas pero sigue igual La guía que seguí es la siguiente: https://serverfault.com/questions/592793/mysql-crashed-and-wont-start-up Link to comment Share on other sites More sharing options...
genweb Posted June 11, 2017 Share Posted June 11, 2017 Tiene mala pinta. Si te sucede también con una instalación nueva, no debe ser problema de las tablas corruptas sino más bien de configuración o disponibilidad del servidor. Yo abriría un ticket en hostgator (si es que tienes soporte) porque no es normal que te rechace la conexión MySQL aleatoriamente. Link to comment Share on other sites More sharing options...
Soy.es Posted June 12, 2017 Share Posted June 12, 2017 COmo te dice genweb, es cosa del servidor, no tiene ningún sentido que haga eso. Habla con ellos y nos cuentas. Y si no tiene soporte, cambiate de hosting, para las tiendas online es muy importante el hosting y la velocidad del mismo. Saludos Link to comment Share on other sites More sharing options...
zenky Posted June 13, 2017 Author Share Posted June 13, 2017 Ya instale php 7.0, php 7.1, php 5.6 y php 5.3.3 y sigue saliendo el mismo error. Lo que veo en el log de mysql es lo siguiente: 170613 9:45:04 [Note] Plugin 'FEDERATED' is disabled. 170613 9:45:04 InnoDB: The InnoDB memory heap is disabled 170613 9:45:04 InnoDB: Mutexes and rw_locks use GCC atomic builtins 170613 9:45:04 InnoDB: Compressed tables use zlib 1.2.3 170613 9:45:04 InnoDB: Using Linux native AIO 170613 9:45:05 InnoDB: Initializing buffer pool, size = 128.0M 170613 9:45:05 InnoDB: Completed initialization of buffer pool 170613 9:45:05 InnoDB: highest supported file format is Barracuda. InnoDB: Log scan progressed past the checkpoint lsn 46980400 170613 9:45:05 InnoDB: Database was not shut down normally! InnoDB: Starting crash recovery. InnoDB: Reading tablespace information from the .ibd files... InnoDB: Restoring possible half-written data pages from the doublewrite InnoDB: buffer... InnoDB: Doing recovery: scanned up to log sequence number 46983137 170613 9:45:05 InnoDB: Starting an apply batch of log records to the database... InnoDB: Progress in percents: 87 88 89 90 91 92 93 94 95 96 97 98 99 InnoDB: Apply batch completed 170613 9:45:05 InnoDB: Waiting for the background threads to start 170613 9:45:06 InnoDB: 5.5.56 started; log sequence number 46983137 170613 9:45:06 [Note] Server hostname (bind-address): '127.0.0.1'; port: 3306 170613 9:45:06 [Note] - '127.0.0.1' resolves to '127.0.0.1'; 170613 9:45:06 [Note] Server socket created on IP: '127.0.0.1'. 170613 9:45:06 [Note] Event Scheduler: Loaded 0 events 170613 9:45:06 [Note] /usr/libexec/mysqld: ready for connections. Version: '5.5.56' socket: '/var/lib/mysql/mysql.sock' port: 3306 MySQL Community Server (GPL) by Remi Este error se graba en el log cada que me marca el error del primer post. Link to comment Share on other sites More sharing options...
zenky Posted June 28, 2017 Author Share Posted June 28, 2017 Compañeros vengo a comentarles que ya di con el problema que tenia. Resulta que cuando la página tenia algo de uso se consumia la poca ram que tenia el servidor, por tema de mala configuración en el apache. Investigué como optimizar los recursos consumidos por apache y mysql, pero de todas formas resulto dando el mismo problema. Como el VPS no tiene unidad swap, debido a que no está permitida instalarla, pasaba que la memoria ram se acaba y existe un daemon llamado oom killer, que selcciona el proceso que está consumiendo mayor cantidad de ram y lo mata con un kill. Debido a eso es que el mysql se caia de vez en cuando y me marcaba este error. Lo que tuve que hacer fue aumentar la memoria ram a mi vps y listo, el error se ha ido. Espero que mi experiencia les sirva a algunos compañeros que tengan el mismo problema. Doy el tema por resuelto, por otro lado se agradece la ayuda de todos Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now