The system was running fine, but all of a sudden got this error 'Database connection failed', what might be the possible issues, how can I fix this error forever. Thank you.
System Information: Ubuntu 16.04.3 x64 2 GB Memory / 50 GB Disk
I checked with 'df -h' in the terminal,
I did error log check:
2018-07-31T10:10:04.751870Z 0 [Note] /usr/sbin/mysqld: Shutdown complete
2018-07-31T10:10:34.438715Z 0 [Warning] Changed limits: max_open_files: 1024 (requested 5000)
2018-07-31T10:10:34.438807Z 0 [Warning] Changed limits: table_open_cache: 431 (requested 2000)
2018-07-31T10:10:34.613317Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2018-07-31T10:10:34.615293Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.23-0ubuntu0.16.04.1) starting as process 14674 ...
2018-07-31T10:10:34.620666Z 0 [Note] InnoDB: PUNCH HOLE support available
2018-07-31T10:10:34.620694Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2018-07-31T10:10:34.620699Z 0 [Note] InnoDB: Uses event mutexes
2018-07-31T10:10:34.620703Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2018-07-31T10:10:34.620706Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.8
2018-07-31T10:10:34.620710Z 0 [Note] InnoDB: Using Linux native AIO
2018-07-31T10:10:34.621008Z 0 [Note] InnoDB: Number of pools: 1
2018-07-31T10:10:34.621153Z 0 [Note] InnoDB: Using CPU crc32 instructions
2018-07-31T10:10:34.623069Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2018-07-31T10:10:34.634597Z 0 [Note] InnoDB: Completed initialization of buffer pool
2018-07-31T10:10:34.637277Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2018-07-31T10:10:34.647303Z 0 [Note] InnoDB: The first innodb_system data file 'ibdata1' did not exist. A new tablespace will be created!
2018-07-31T10:10:34.647393Z 0 [ERROR] InnoDB: redo log file './ib_logfile0' exists. Creating system tablespace with existing redo log files is not recommended. Please delete all redo log files before creating new system tablespace.
2018-07-31T10:10:34.647403Z 0 [ERROR] InnoDB: InnoDB Database creation was aborted with error Generic error. You may need to delete the ibdata1 file before trying to start up again.
2018-07-31T10:10:35.248139Z 0 [ERROR] Plugin 'InnoDB' init function returned error.
2018-07-31T10:10:35.248186Z 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2018-07-31T10:10:35.248195Z 0 [ERROR] Failed to initialize builtin plugins.
2018-07-31T10:10:35.248201Z 0 [ERROR] Aborting
2018-07-31T10:10:35.248222Z 0 [Note] Binlog end
2018-07-31T10:10:35.248304Z 0 [Note] Shutting down plugin 'MyISAM'
2018-07-31T10:10:35.248323Z 0 [Note] Shutting down plugin 'CSV'
2018-07-31T10:10:35.248824Z 0 [Note] /usr/sbin/mysqld: Shutdown complete