I tried everything purge and install many times.
sudo dpkg --configure -a
output
Setting up mysql-server-8.0 (8.0.28-0ubuntu0.20.04.3) ...
Failed to stop mysql.service: Unit mysql.service not loaded.
invoke-rc.d: initscript mysql, action "stop" failed.
Renaming removed key_buffer and myisam-recover options (if present)
mysqld will log errors to /var/log/mysql/error.log
2022-05-03T11:44:20.790604Z 0 [ERROR] [MY-010946] [Server] Failed to start mysqld daemon. Check mysqld error log.
Warning: Unable to start the server.
Failed to preset unit: File mysql.service: Link has been severed
/usr/bin/deb-systemd-helper: error: systemctl preset failed on mysql.service: No such file or directory
Failed to start mysql.service: Unit mysql.service not found.
invoke-rc.d: initscript mysql, action "start" failed.
Unit mysql.service could not be found.
dpkg: error processing package mysql-server-8.0 (--configure):
installed mysql-server-8.0 package post-installation script subprocess returned error exit status 1
I looked now at above mentioned logs
[ERROR] [MY-012930] [InnoDB] Plugin initialization aborted with error Generic error.
2022-05-03T11:36:53.787528Z 1 [ERROR] [MY-011013] [Server] Failed to initialize DD Storage Engine.
2022-05-03T11:36:53.788000Z 0 [ERROR] [MY-010020] [Server] Data Dictionary initialization failed.
2022-05-03T11:36:53.788246Z 0 [ERROR] [MY-010119] [Server] Aborting
2022-05-03T11:36:53.789640Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.28-0ubuntu0.20.04.3) (Ubuntu).
I am adding my /var/lib/mysql
var/lib/mysql# ls -la
total 119220
drwx------ 5 mysql mysql 4096 мај 3 20:42 .
drwxr-xr-x 77 root root 4096 мај 3 13:36 ..
-rw-rw---- 1 mysql mysql 16384 мај 3 13:31 aria_log.00000001
-rw-rw---- 1 mysql mysql 52 мај 3 13:31 aria_log_control
-rw-r----- 1 mysql mysql 56 мај 3 13:36 auto.cnf
-rw-r----- 1 mysql mysql 0 мај 3 13:36 binlog.index
-rw-r--r-- 1 mysql mysql 0 мај 3 13:58 debian-5.7.flag
-rw-r----- 1 mysql mysql 196608 мај 3 13:36 '#ib_16384_0.dblwr'
-rw-r----- 1 mysql mysql 8585216 мај 3 13:36 '#ib_16384_1.dblwr'
-rw-rw---- 1 mysql mysql 976 мај 3 13:31 ib_buffer_pool
-rw-rw---- 1 mysql mysql 12582912 мај 3 13:31 ibdata1
-rw-rw---- 1 mysql mysql 50331648 мај 3 13:31 ib_logfile0
-rw-rw---- 1 mysql mysql 50331648 мај 3 13:05 ib_logfile1
drwx------ 2 mysql mysql 4096 мај 3 13:05 mysql
-rw-r--r-- 1 mysql mysql 15 мај 3 13:05 mysql_upgrade_info
drwx------ 2 mysql mysql 4096 мај 3 13:05 performance_schema
drwx------ 2 mysql mysql 4096 мај 3 13:05 test
How can I look further into this issue?