MySQL failing to start under Cent OS - centos

I'm trying to start mysqld on a CentOS box running Plesk as it is failing to start on its own.
Issuing the 'service mysqld start' command consistently fails. The /var/log/mysqld.log contains the following log output that I have so far been unable to diagnose:
140812 11:02:06 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
140812 11:02:06 [Note] libgovernor.so not found
140812 11:02:06 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
140812 11:02:06 [Note] Plugin 'FEDERATED' is disabled.
140812 11:02:06 InnoDB: The InnoDB memory heap is disabled
140812 11:02:06 InnoDB: Mutexes and rw_locks use GCC atomic builtins
140812 11:02:06 InnoDB: Compressed tables use zlib 1.2.3
140812 11:02:06 InnoDB: Using Linux native AIO
140812 11:02:06 InnoDB: Initializing buffer pool, size = 1.5G
140812 11:02:06 InnoDB: Completed initialization of buffer pool
140812 11:02:06 InnoDB: highest supported file format is Barracuda.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
140812 11:02:06 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...
140812 11:02:06 InnoDB: ERROR: We were only able to scan the log up to
InnoDB: 521620455936, but a checkpoint was at 521620456252.
InnoDB: It is possible that the database is now corrupt!
140812 11:02:06 InnoDB: Error: page 5 log sequence number 521796960861
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 311359 log sequence number 521812034102
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 604 log sequence number 521733589779
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 262172 log sequence number 521916027574
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 226339 log sequence number 521733589779
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 393217 log sequence number 521650203404
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 393230 log sequence number 521672783155
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 409641 log sequence number 521858248765
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: for more information.
140812 11:02:06 InnoDB: Error: page 227012 log sequence number 521815629412
InnoDB: is in the future! Current system log sequence number 521620456252.
InnoDB: Your database may be corrupt or you may have copied the InnoDB
InnoDB: tablespace but not the InnoDB log files. See
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: End of page dump
140812 11:02:06 InnoDB: Page checksum 1035077618, prior-to-4.0.14-form checksum 3964970138
InnoDB: stored checksum 1035077618, prior-to-4.0.14-form stored checksum 3867662893
InnoDB: Page lsn 121 2063969088, low 4 bytes of lsn at page end 2169240268
InnoDB: Page number (if stored to page already) 426042,
InnoDB: space id (if created with >= MySQL-4.1.1 and stored already) 0
InnoDB: Page may be an insert undo log page
InnoDB: Database page corruption on disk or a failed
InnoDB: file read of page 426042.
InnoDB: You may have to recover from a backup.
InnoDB: It is also possible that your operating
InnoDB: system has corrupted its own file cache
InnoDB: and rebooting your computer removes the
InnoDB: error.
InnoDB: If the corrupt page is an index page
InnoDB: you can also try to fix the corruption
InnoDB: by dumping, dropping, and reimporting
InnoDB: the corrupt table. You can use CHECK
InnoDB: TABLE to scan your table for corruption.
InnoDB: See also http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
InnoDB: Ending processing because of a corrupt database page.
140812 11:02:06 InnoDB: Assertion failure in thread 140632717436896 in file buf0buf.c line 3619
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:02:06 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=268435456
read_buffer_size=131072
max_used_connections=0
max_threads=300
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 = 918492 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 0x40000
/usr/libexec/mysqld(my_print_stacktrace+0x2e)[0x79275e]
/usr/libexec/mysqld(handle_fatal_signal+0x493)[0x67ab83]
/lib64/libpthread.so.0(+0xf710)[0x7fe79ae8e710]
/lib64/libc.so.6(gsignal+0x35)[0x7fe7992d6925]
/lib64/libc.so.6(abort+0x175)[0x7fe7992d8105]
/usr/libexec/mysqld[0x8101df]
/usr/libexec/mysqld[0x81dc38]
/usr/libexec/mysqld[0x81e3ea]
/usr/libexec/mysqld[0x8133b5]
/usr/libexec/mysqld[0x7edf14]
/usr/libexec/mysqld[0x7e3141]
/usr/libexec/mysqld[0x7e3558]
/usr/libexec/mysqld[0x7e6323]
/usr/libexec/mysqld[0x7d233c]
/usr/libexec/mysqld[0x79ddc0]
/usr/libexec/mysqld(_Z24ha_initialize_handlertonP13st_plugin_int+0x41)[0x67d8b1]
/usr/libexec/mysqld[0x590a68]
/usr/libexec/mysqld(_Z11plugin_initPiPPci+0x8c8)[0x594348]
/usr/libexec/mysqld[0x51a668]
/usr/libexec/mysqld(_Z11mysqld_mainiPPc+0x3fd)[0x51d28d]
/lib64/libc.so.6(__libc_start_main+0xfd)[0x7fe7992c2d1d]
/usr/libexec/mysqld[0x512915]
Edit: my MySQL configuration file:
[mysqld]
bind-address=127.0.0.1
local-infile=0
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
innodb_buffer_pool_size = 1536M
key_buffer = 256M
query_cache_size = 128M
query_cache_limit = 2M
thread_cache_size = 12
max_connections = 300
innodb_lock_wait_timeout = 100
table_cache = 1600
table_definition_cache = 800
open_files_limit = 2600
innodb_flush_log_at_trx_commit = 2
join_buffer_size = 2M
innodb_thread_concurrency = 8
tmp_table_size = 6M
max_heap_table_size = 6M
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
[root#s17111944 ~]# free -m
total used free shared buffers cached
Mem: 3927 470 3456 0 33 231
-/+ buffers/cache: 206 3721
Swap: 2055 0 2055

Related

How to launch mysql persistent on openshift OKD?

I am unable to launch mysql deployment with persistent storage, the ephemeral one works fine. I am getting the following error.
I tried launching deployment from cli and web console as well. In both cases I get the following error.
=> sourcing http://20-validate-variables.sh ...
=> sourcing http://25-validate-replication-variables.sh ...
=> sourcing http://30-base-config.sh ...
---> 01:27:23 Processing basic MySQL configuration files ...
=> sourcing http://60-replication-config.sh ...
=> sourcing http://70-s2i-config.sh ...
---> 01:27:23 Processing additional arbitrary MySQL configuration provided by s2i ...
=> sourcing 10-mysql57.cnf ...
=> sourcing 40-paas.cnf ...
=> sourcing 50-my-tuning.cnf ...
---> 01:27:23 Initializing database ...
---> 01:27:24 Running /opt/rh/rh-mysql57/root/usr/libexec/mysqld --initialize --datadir=/var/lib/mysql/data --ignore-db-dir=lost+found
---> 01:27:24 Starting MySQL server with disabled networking ...
---> 01:27:24 Waiting for MySQL to start ...
2019-03-30T01:27:24.466755Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2019-03-30T01:27:24.584395Z 0 [Note] /opt/rh/rh-mysql57/root/usr/libexec/mysqld (mysqld 5.7.24) starting as process 40 ...
2019-03-30T01:27:24.774993Z 0 [Note] InnoDB: PUNCH HOLE support available
2019-03-30T01:27:24.775057Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2019-03-30T01:27:24.775068Z 0 [Note] InnoDB: Uses event mutexes
2019-03-30T01:27:24.775075Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2019-03-30T01:27:24.775761Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.7
2019-03-30T01:27:24.775809Z 0 [Note] InnoDB: Using Linux native AIO
2019-03-30T01:27:24.777416Z 0 [Note] InnoDB: Number of pools: 1
2019-03-30T01:27:24.778012Z 0 [Note] InnoDB: Not using CPU crc32 instructions
2019-03-30T01:27:24.784562Z 0 [Note] InnoDB: Initializing buffer pool, total size = 256M, instances = 1, chunk size = 128M
2019-03-30T01:27:24.841105Z 0 [Note] InnoDB: Completed initialization of buffer pool
2019-03-30T01:27:24.852695Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2019-03-30T01:27:25.019343Z 0 [ERROR] InnoDB: Header page consists of zero bytes in datafile: ./ibdata1, Space ID:0, Flags: 0. Please refer to http://dev.mysql.com/doc/refman/5.7/en/innodb-troubleshooting-datadict.html … for how to resolve the issue.
2019-03-30T01:27:25.019422Z 0 [ERROR] InnoDB: Corrupted page [page id: space=0, page number=0] of datafile './ibdata1' could not be found in the doublewrite buffer.
2019-03-30T01:27:25.019473Z 0 [ERROR] InnoDB: Plugin initialization aborted with error Data structure corruption
---> 01:27:25 Waiting for MySQL to start ...
2019-03-30T01:27:25.520693Z 0 [ERROR] Plugin 'InnoDB' init function returned error.
2019-03-30T01:27:25.520749Z 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2019-03-30T01:27:25.520763Z 0 [ERROR] Failed to initialize builtin plugins.
2019-03-30T01:27:25.520772Z 0 [ERROR] Aborting
2019-03-30T01:27:25.521120Z 0 [Note] Binlog end
2019-03-30T01:27:25.521862Z 0 [Note] Shutting down plugin 'CSV'
2019-03-30T01:27:25.530469Z 0 [Note] /opt/rh/rh-mysql57/root/usr/libexec/mysqld: Shutdown complete

wal-e backup-push not terminating (waiting for required WAL segments to be archived)

Trying to setup wal-e for postgres.
Following various tutorials and I'm at a point to finally do a first backup of a clean 9.6 postgres install.
Followed some tutorials and finally read to do an initial wal-e backup-push, as follows:
sudo -u postgres -i
envdir /etc/wal-e.d/env wal-e backup-push /var/lib/postgresql/9.6/main
I'd expect the command to terminate rather quickly, since it's an empty database.
However it seems to wait indefinitely. Showing waiting for required WAL segments to be archived
postgres#postgres:~$ envdir /etc/wal-e.d/env wal-e backup-push /var/lib/postgresql/9.6/main
wal_e.main INFO MSG: starting WAL-E
DETAIL: The subcommand is "backup-push".
STRUCTURED: time=2017-05-26T11:45:52.138889-00 pid=10426
wal_e.operator.backup INFO MSG: start upload postgres version metadata
DETAIL: Uploading to s3://xxxxxx/basebackups_005/base_000000010000000000000060_00000040/extended_version.txt.
STRUCTURED: time=2017-05-26T11:45:52.719220-00 pid=10426
wal_e.operator.backup INFO MSG: postgres version metadata upload complete
STRUCTURED: time=2017-05-26T11:45:52.929696-00 pid=10426
wal_e.worker.upload INFO MSG: beginning volume compression
DETAIL: Building volume 0.
STRUCTURED: time=2017-05-26T11:45:53.075771-00 pid=10426
wal_e.worker.upload INFO MSG: begin uploading a base backup volume
DETAIL: Uploading to "s3://xxxxxx/basebackups_005/base_000000010000000000000060_00000040/tar_partitions/part_00000000.tar.lzo".
STRUCTURED: time=2017-05-26T11:45:53.752390-00 pid=10426
wal_e.worker.upload INFO MSG: finish uploading a base backup volume
DETAIL: Uploading to "s3://xxxxxx/basebackups_005/base_000000010000000000000060_00000040/tar_partitions/part_00000000.tar.lzo" complete at 9106.47KiB/s.
STRUCTURED: time=2017-05-26T11:45:54.327037-00 pid=10426
NOTICE: pg_stop_backup cleanup done, waiting for required WAL segments to be archived
WARNING: pg_stop_backup still waiting for all required WAL segments to be archived (60 seconds elapsed)
HINT: Check that your archive_command is executing properly. pg_stop_backup can be canceled safely, but the database backup will not be usable without all the WAL segments.
WARNING: pg_stop_backup still waiting for all required WAL segments to be archived (120 seconds elapsed)
HINT: Check that your archive_command is executing properly. pg_stop_backup can be canceled safely, but the database backup will not be usable without all the WAL segments.
To be honest I'm a bit out of my depth here. Afaik, the above should do an initial backup, but not wait for WAL-files which are obviously continuously updated. (I've got archive_mode=on in my postgres config and set archive_command = 'envdir /etc/wal-e.d/env wal-e wal-push %p' which should do the incremental pushes. Again afaik.).
How can I get this initial backup command to finish?

Postgresql - could not create shared memory segment: Cannot allocate memory

This question has been asked many times, but the response given / worked for most is not working for me. So, I am suspicious that something else is missing.
OS: $ cat /proc/version
Linux version 2.6.32-431.29.2.el6.x86_64 (mockbuild#x86-026.build.eng.bos.redhat.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-4) (GCC) ) #1 SMP Sun Jul 27 15:55:46 EDT 2014
When I try to start PostGreSQL, I get the following error :
[reportadmin /opt/birt/modules/BIRTiHub]$ ./startPostgreSQL.sh
Starting startpostgresql at Fri 05/15/2015 08:03:29
AC_SERVER_HOME=/opt/BIRTiHubFType/modules/BIRTiHub/iHub
2015-05-15 12:03:30 UTC 27379 LOG: loaded library "pg_stat_statements"
2015-05-15 12:03:30 UTC 27379 FATAL: could not create shared memory segment: Cannot allocate memory
2015-05-15 12:03:30 UTC 27379 DETAIL: Failed system call was shmget(key=8433001, size=290635776, 03600).
2015-05-15 12:03:30 UTC 27379 HINT: This error usually means that PostgreSQL's request for a shared memory segment exceeded available memory or swap space, or exceeded your kernel's SHMALL parameter. You can either reduce the request size or reconfigure the kernel with larger SHMALL. To reduce the request size (currently 290635776 bytes), reduce PostgreSQL's shared memory usage, perhaps by reducing shared_buffers or max_connections.
The PostgreSQL documentation contains more information about shared memory configuration.
pg_ctl: could not start server
Examine the log output.
Also, I have adjusted the shmmax and shmall values to be greater than and less than (respect) the requested value.
[root /opt/birt]$ sysctl -p
....
kernel.msgmnb = 65536
kernel.msgmax = 65536
kernel.shmmax = 68719476736
kernel.shmall = 134217728
In other words:
shmall =134217728
Requested =290635776
shmmax =68719476736
Any idea what could be wrong ?
D

Mysql failed to start

I have installed mysql-5.6.14 from source pack
trying to start:
vaio1#vaio1-VPCEA3S1E:mysqld
2013-11-17 13:22:18 0 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
2013-11-17 13:22:18 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2013-11-17 13:22:18 1777 [ERROR] Can't find messagefile '/usr/share/mysql/errmsg.sys'
2013-11-17 13:22:18 1777 [Warning] One can only use the --user switch if running as root
2013-11-17 13:22:18 1777 [Warning] Buffered warning: Changed limits: max_open_files: 1024 (requested 5000)
2013-11-17 13:22:18 1777 [Warning] Buffered warning: Changed limits: table_cache: 431 (requested 2000)
2013-11-17 13:22:18 1777 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead.
2013-11-17 13:22:18 1777 [Note] Plugin 'FEDERATED' is disabled.mysqld: Unknown error 1146
2013-11-17 13:22:18 1777 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
2013-11-17 13:22:18 1777 [Note] InnoDB: The InnoDB memory heap is disabled
2013-11-17 13:22:18 1777 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2013-11-17 13:22:18 1777 [Note] InnoDB: Compressed tables use zlib 1.2.3
2013-11-17 13:22:18 1777 [Note] InnoDB: Using CPU crc32 instructions
2013-11-17 13:22:18 1777 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2013-11-17 13:22:18 1777 [Note] InnoDB: Completed initialization of buffer pool
2013-11-17 13:22:18 1777 [Note] InnoDB: Highest supported file format is Barracuda.
2013-11-17 13:22:19 1777 [Note] InnoDB: 128 rollback segment(s) are active.
2013-11-17 13:22:19 1777 [Note] InnoDB: Waiting for purge to start
2013-11-17 13:22:19 1777 [Note] InnoDB: 5.6.14 started; log sequence number 1600677
2013-11-17 13:22:19 1777 [ERROR] Aborting
Open the terminal and run this command for starting mysql service:
$ sudo mysqld_safe --skip-grant-tables
while mysql service is running, then open other terminal and run:
$ sudo mysql_upgrade -u root -p
mysqld reads this standard configuration file and can not read the 5.5 message file in
5.6, leading to this error.
Solutions :
1. pass your configuration file to mysql_install_db
./scripts/mysql_install_db --defaults-file=my.cnf
2. use --no-defaults, not to read other configuration files
./scripts/mysql_install_db --no-defaults --basedir=/home/praveen/mysql-5.6.10-linux-x86_65
--datadir=/home/praveen/data
Maybe, you got the MySQL 5.6 binary but my.cnf and data file is older version.
have you read MySQL upgrade Manual?
main reason MySQL has dead is :
Unknown error 1146 2013-11-17 13:22:18 1777 [ERROR] Can't open the mysql.plugin table.
Please run mysql_upgrade to create it
see Manual how to use mysql_upgrade. most of error message is related to deprecated options.
I have compiled from the sourceforge zip :mysql-5.6.14
Trying to mysql_upgrade:
vaio1#vaio1-VPCEA3S1E:~/Téléchargements/mysql-5.6.14$ mysql_upgrade
Looking for 'mysql' as: mysql
Looking for 'mysqlcheck' as: mysqlcheck
FATAL ERROR: Upgrade failed
vaio1#vaio1-VPCEA3S1E:~/Téléchargements/mysql-5.6.14$ mysqlcheck
Variables (--variable-name=value)
and boolean options {FALSE|TRUE} Value (after reading options)
--------------------------------- ----------------------------------------
all-databases FALSE
all-in-1 FALSE
auto-repair FALSE
bind-address (No default value)
character-sets-dir (No default value)
compress FALSE
databases FALSE
debug-check FALSE
debug-info FALSE
default-character-set (No default value)
default-auth (No default value)
fast FALSE
fix-db-names FALSE
fix-table-names FALSE
force FALSE
extended FALSE
host (No default value)
write-binlog TRUE
plugin-dir (No default value)
port 0
quick FALSE
silent FALSE
skip-database (No default value)
socket (No default value)
ssl FALSE
ssl-ca (No default value)
ssl-capath (No default value)
ssl-cert (No default value)
ssl-cipher (No default value)
ssl-key (No default value)
ssl-crl (No default value)
ssl-crlpath (No default value)
ssl-verify-server-cert FALSE
use-frm FALSE
user (No default value)
I don't understand why
user (No default value)
In my file: /etc/mysql/my.cnf
user = mysql
vaio1#vaio1-VPCEA3S1E:~/Téléchargements/mysql-5.6.14$ mysqld_safe --skip-grant-tables
131118 10:10:04 mysqld_safe Logging to '/var/log/mysql/error.log'.
touch: impossible de faire un touch «/var/log/mysql/error.log»: Permission non accordée
chmod: impossible d'accéder à «/var/log/mysql/error.log»: Aucun fichier ou dossier de ce type ## No files or directory
131118 10:10:04 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
/usr/local/mysql/bin/mysqld_safe: 129: /usr/local/mysql/bin/mysqld_safe: cannot create /var/log/mysql/error.log: Permission denied
/usr/local/mysql/bin/mysqld_safe: 1: eval: cannot create /var/log/mysql/error.log: Permission denied
touch: impossible de faire un touch «/var/log/mysql/error.log»: Permission non accordée
chown: impossible d'accéder à «/var/log/mysql/error.log»: Aucun fichier ou dossier de ce type ## No files or directory
chmod: impossible d'accéder à «/var/log/mysql/error.log»: Aucun fichier ou dossier de ce type
131118 10:10:04 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
/usr/local/mysql/bin/mysqld_safe: 129: /usr/local/mysql/bin/mysqld_safe: cannot create /var/log/mysql/error.log: Permission denied
...$ mysqlcheck --all-databases --check-upgrade --auto-repair
mysqlcheck: Got error: 2002: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) when trying to connect
Trying this: sudo chown -R mysql /var/lib/mysql
also .. chown..var/log/mysql/
.. change nothing
YES! maybe problem from default user;
sudo cmod 777 var/log/mysql/ ## just test lol
Trying mysqld
vaio1#vaio1-VPCEA3S1E:~/Téléchargements/mysql-5.6.14$ mysqld
2013-11-18 11:36:36 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2013-11-18 11:36:36 24679 [ERROR] Can't find messagefile '/usr/share/mysql/errmsg.sys'
2013-11-18 11:36:36 24679 [Warning] One can only use the --user switch if running as root
2013-11-18 11:36:36 24679 [ERROR] Can't find messagefile '/usr/share/mysql/errmsg.sys'
Coping errmsg.sys
sudo cp /usr/local/mysql/share/english/errmsg.sys /usr/share/errmsg.sys
sudo chown mysql /usr/share/errmsg.sys
Resolve /usr/share/mysql/errmsg.sys
Whatever the list of MySQL "ini" files are present in : "MySQL\MySQL Server 5.2\" folder, replace them from your frined.
I wasted so much time and still dont know the root cause of the problem.
Do check ".err" file present in "data" folder for errors if any.
Now start the service & Done.
Its just makes entry somewhere & u try to debug for the problem soluton, instead this was faster approach.
Just ran into the same issue as mentioned in this question and tried lot of solutions, at last I figured out what was wrong. The issue came with the server upgrading. Files from mysql-libs-5.1.73-5.el6_6.x86_64 replaced those in MySQL-server-5.6.15-1.el6.x86_64, so after reinstalling, the server comes back. Here is what I did for a furture reference.
$ rpm -qf /usr/share/mysql/english/errmsg.sys
MySQL-server-5.6.15-1.el6.x86_64
mysql-libs-5.1.73-5.el6_6.x86_64
$ rpm -e mysql-libs-5.1.73-5.el6_6.x86_64
$ rpm -ivh --replacepkgs MySQL-*

Mariadb init script

I installed MAriadb form sources on debian.
I used the init script mysql.server.
I have that error when run it :
Starting MySQL
.Manager of pid-file quit without updating file. ... failed!
There is no mysqld.pid anywhere, there is no mysqld executed.
.err file :
110209 17:04:55 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
110209 17:04:55 [ERROR] Can't find messagefile '/usr/share/mysql/english/errmsg.sys'
110209 17:04:55 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
110209 17:04:55 [Note] PrimeBase XT (PBXT) Engine 1.0.11-7 Pre-GA loaded...
110209 17:04:55 [Note] Paul McCullagh, PrimeBase Technologies GmbH, http://www.primebase.org
InnoDB: The InnoDB memory heap is disabled
InnoDB: Mutexes and rw_locks use GCC atomic builtins
InnoDB: Compressed tables use zlib 1.2.3.4
110209 17:04:55 InnoDB: highest supported file format is Barracuda.
110209 17:04:55 Percona XtraDB (http://www.percona.com) 1.0.13-11.6 started; log sequence number 45356
110209 17:04:55 [ERROR] Aborting
110209 17:04:55 InnoDB: Starting shutdown...
110209 17:04:55 InnoDB: Shutdown completed; log sequence number 45356
110209 17:04:55 [Note] PrimeBase XT Engine shutdown...
110209 17:04:55 [Note]
110209 17:04:55 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
Any idea ?
Thanks
Actually there is a debian package with normally will work ;-)
This normaly means that you've just upgraded to a new version but the tables haven't been upgraded yet. Start mysql with --skip-networking and --skip-grant-tables. Then run mysql_upgrade. Now stop and restart the mysql server without those extra options.