Estou completamente perplexo agora, embora não seja um usuário avançado, conheço o Ubuntu e, por isso, tentei investigar as coisas com a ajuda de determinados tópicos do fórum.
O problema:
Hoje, muito aleatoriamente, o mysql parou de funcionar no meu laptop local. Não consegui mais que o serviço fosse iniciado
$ sudo mysql start
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (111
Então, depois de muita pesquisa e verificação de permissões de arquivos, como outros posts sugeriram, eu decidi que era o suficiente e fui para a reinstalação completa do mysql. Isso também não funcionou. E assim eu encontrei este post para ir para uma limpeza completa: "Falha ao spawn mysql main process: não foi possível executar: Nenhum arquivo ou diretório "
Mais uma vez sem sorte, e muitas outras postagens que encontrei têm soluções que não funcionaram para mim ou que não têm solução alguma. Não tenho certeza do que tentar em seguida, ou se isso é um problema comum que outros estão tendo. Qualquer sugestão sobre testes que eu possa executar seria muito apreciada para resolver isso, como eu poderia fazer com o mysql voltando e trabalhando novamente.
Os erros atuais que recebo quando vou reinstalar o mysql são:
Setting up mysql-client-5.5 (5.5.31-0ubuntu0.13.04.1) ...
Setting up mysql-server-5.5 (5.5.31-0ubuntu0.13.04.1) ...
start: Job failed to start
invoke-rc.d: initscript mysql, action "start" failed.
dpkg: error processing mysql-server-5.5 (--configure):
subprocess installed post-installation script returned error exit status 1
Processing triggers for libc-bin ...
No apport report written because MaxReports has already been reached
ldconfig deferred processing now taking place
Errors were encountered while processing:
mysql-server-5.5
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install. Trying to recover:
Setting up mysql-server-5.5 (5.5.31-0ubuntu0.13.04.1) ...
start: Job failed to start
invoke-rc.d: initscript mysql, action "start" failed.
dpkg: error processing mysql-server-5.5 (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
mysql-server-5.5
Então, isso está implicando em um problema com o mysql-server-5.5, mas não é certo o que ou por que, já que isso deve ser completamente novo.
Obrigado por qualquer momento e / ou conselhos que você possa dar,
Dan
Update1
Encontrou um novo post com uma nova ideia, sem sorte, mas com mais informações de erro para ajudar a depurar isso
$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up mysql-server-5.5 (5.5.31-0ubuntu0.13.04.1) ...
start: Job failed to start
invoke-rc.d: initscript mysql, action "start" failed.
dpkg: error processing mysql-server-5.5 (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
mysql-server-5.5
E: Sub-process /usr/bin/dpkg returned an error code (1)
Update2
Resultados do error.log no mysql
$ tail /var/log/mysql/error.log
/usr/sbin/mysqld(+0x59043a)[0xb745943a]
/usr/sbin/mysqld(+0x590cd3)[0xb7459cd3]
/usr/sbin/mysqld(+0x585fea)[0xb744efea]
/usr/sbin/mysqld(+0x4c57b9)[0xb738e7b9]
/usr/sbin/mysqld(+0x4b785e)[0xb738085e]
/usr/sbin/mysqld(+0x4ba8f1)[0xb73838f1]
/lib/i386-linux-gnu/libpthread.so.0(+0x6d78)[0xb6e78d78]
/lib/i386-linux-gnu/libc.so.6(clone+0x5e)[0xb6c083de]
The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.
retrobadger@Laptop-Badger:~$ tail -n50 /var/log/mysql/error.log
InnoDB: Please refer to
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
130509 11:30:18 InnoDB: Assertion failure in thread 2792295232 in file fsp0fsp.c line 3309
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to http://bugs.mysql.com.
InnoDB: If you get repeated assertion failures or crashes, even
InnoDB: immediately after the mysqld startup, there may be
InnoDB: corruption in the InnoDB tablespace. Please refer to
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
10:30:18 UTC - mysqld got signal 6 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help
diagnose the problem, but since we have already crashed,
something is definitely wrong and this may fail.
key_buffer_size=16777216
read_buffer_size=131072
max_used_connections=0
max_threads=151
thread_count=0
connection_count=0
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 346064 K bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
Thread pointer: 0x0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 0 thread_stack 0x30000
/usr/sbin/mysqld(my_print_stacktrace+0x33)[0xb72ea683]
/usr/sbin/mysqld(handle_fatal_signal+0x48c)[0xb71af2fc]
[0xb6ea6400]
/usr/sbin/mysqld(+0x53c7da)[0xb74057da]
/usr/sbin/mysqld(+0x4ee825)[0xb73b7825]
/usr/sbin/mysqld(+0x4eefcc)[0xb73b7fcc]
/usr/sbin/mysqld(+0x59043a)[0xb745943a]
/usr/sbin/mysqld(+0x590cd3)[0xb7459cd3]
/usr/sbin/mysqld(+0x585fea)[0xb744efea]
/usr/sbin/mysqld(+0x4c57b9)[0xb738e7b9]
/usr/sbin/mysqld(+0x4b785e)[0xb738085e]
/usr/sbin/mysqld(+0x4ba8f1)[0xb73838f1]
/lib/i386-linux-gnu/libpthread.so.0(+0x6d78)[0xb6e78d78]
/lib/i386-linux-gnu/libc.so.6(clone+0x5e)[0xb6c083de]
The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.
Update3
May 9 09:51:11 Laptop-Badger mysqld_safe[4193]: 130509 9:51:11 InnoDB: Error: page 11444 log sequence number 7800613976
May 9 09:51:11 Laptop-Badger mysqld_safe[4193]: InnoDB: is in the future! Current system log sequence number 7672896206.
May 9 09:51:11 Laptop-Badger mysqld_safe[4193]: InnoDB: Your database may be corrupt or you may have copied the InnoDB
May 9 09:51:11 Laptop-Badger mysqld_safe[4193]: InnoDB: tablespace but not the InnoDB log files. See
May 9 09:51:11 Laptop-Badger mysqld_safe[4193]: InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
May 9 09:51:11 Laptop-Badger mysqld_safe[4193]: InnoDB: for more information.