502 GitLab is taking too much time to respond after restore. (pubsub receive: EOF)

Hello,
Read related Q&A on Google but still could not fix this issue. Are you able to help me?

Symptom:
While access gitlab main page, http://192.168.1.1/, after restored a 12.9.2_gitlab_backup.tar, I got “502 GitLab is taking too much time to respond” message. Error msgs are “pubsub receive: EOF” and “dial unix /var/opt/gitlab/redis/redis.socket: connect: no such file or directory”.

Working Env:
OS: Ubuntu 16.04LTE
Gitlab version: 12.9.2-ce

– content in the gitlab.rb:
external_url ‘http://192.168.1.1
git_data_dirs({
“default” => {
“path” => “/media/GitData”
}
})

– gitlab-ctl status:
ok: run: alertmanager: (pid 8695) 0s
ok: run: gitaly: (pid 8732) 0s
ok: run: gitlab-exporter: (pid 8747) 0s
ok: run: gitlab-workhorse: (pid 8762) 1s
ok: run: grafana: (pid 8777) 0s
ok: run: logrotate: (pid 8808) 1s
ok: run: nginx: (pid 8814) 0s
ok: run: node-exporter: (pid 8826) 1s
ok: run: postgres-exporter: (pid 8832) 0s
ok: run: postgresql: (pid 8922) 0s
ok: run: prometheus: (pid 8931) 1s
ok: run: redis: (pid 8949) 0s
ok: run: redis-exporter: (pid 8956) 1s
ok: run: sidekiq: (pid 8963) 0s
ok: run: unicorn: (pid 8971) 1s

– Executed command:
sudo echo never > /sys/kernel/mm/transparent_hugepage/enabled

– Logs:

/var/log/gitlab/gitlab-workhorse/current
{“build_time”:“20200331.165837”,“level”:“info”,“msg”:“Starting”,“time”:“2023-11-03T13:53:04+08:00”,“version”:“v8.25.1”}
{“level”:“info”,“msg”:“keywatcher: starting process loop”,“time”:“2023-11-03T13:53:04+08:00”}
{“address”:“/var/opt/gitlab/redis/redis.socket”,“level”:“info”,“msg”:“redis: dialing”,“network”:“unix”,“time”:“2023-11-03T13:53:04+08:00”}
{“error”:“keywatcher: pubsub receive: EOF”,“level”:“error”,“msg”:“unknown error”,“time”:“2023-11-03T13:53:08+08:00”}
{“address”:“/var/opt/gitlab/redis/redis.socket”,“level”:“info”,“msg”:“redis: dialing”,“network”:“unix”,“time”:“2023-11-03T13:53:08+08:00”}
{“error”:“keywatcher: dial unix /var/opt/gitlab/redis/redis.socket: connect: no such file or directory”,“level”:“error”,“msg”:“unknown error”,“time”:“2023-11-03T13:53:08+08:00”}
{“address”:“/var/opt/gitlab/redis/redis.socket”,“level”:“info”,“msg”:“redis: dialing”,“network”:“unix”,“time”:“2023-11-03T13:53:08+08:00”}
{“correlation_id”:“VjvtE43P5Y7”,“duration_ms”:0,“error”:“badgateway: failed to receive response: dial unix /var/opt/gitlab/gitlab-rails/sockets/gitlab.socket: connect: connection refused”,“level”:“error”,“method”:“GET”,“msg”:“error”,“time”:“2023-11-03T13:53:58+08:00”,“uri”:“/”}
{“correlation_id”:“VjvtE43P5Y7”,“duration_ms”:0,“host”:“192.168.1.1”,“level”:“info”,“method”:“GET”,“msg”:“access”,“proto”:“HTTP/1.1”,“referrer”:“”,“remote_addr”:“127.0.0.1:0”,“remote_ip”:“127.0.0.1”,“status”:502,“system”:“http”,“time”:“2023-11-03T13:53:58+08:00”,“uri”:“/”,“user_agent”:“Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/119.0”,“written_bytes”:2940}
{“correlation_id”:“qkQFEIS8mya”,“duration_ms”:0,“error”:“badgateway: failed to receive response: dial unix /var/opt/gitlab/gitlab-rails/sockets/gitlab.socket: connect: connection refused”,“level”:“error”,“method”:“GET”,“msg”:“error”,“time”:“2023-11-03T13:54:09+08:00”,“uri”:“/”}
{“correlation_id”:“qkQFEIS8mya”,“duration_ms”:0,“host”:“192.168.1.1”,“level”:“info”,“method”:“GET”,“msg”:“access”,“proto”:“HTTP/1.1”,“referrer”:“”,“remote_addr”:“127.0.0.1:0”,“remote_ip”:“127.0.0.1”,“status”:502,“system”:“http”,“time”:“2023-11-03T13:54:09+08:00”,“uri”:“/”,“user_agent”:“Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/119.0”,“written_bytes”:2940}

/var/log/gitlab/redis/current
2023-11-03_05:53:08.31798 29547:signal-handler (1698990788) Received SIGTERM scheduling shutdown…
2023-11-03_05:53:08.35612 29547:M 03 Nov 2023 13:53:08.356 # User requested shutdown…
2023-11-03_05:53:08.35614 29547:M 03 Nov 2023 13:53:08.356 * Saving the final RDB snapshot before exiting.
2023-11-03_05:53:08.37255 29547:M 03 Nov 2023 13:53:08.372 * DB saved on disk
2023-11-03_05:53:08.37257 29547:M 03 Nov 2023 13:53:08.372 * Removing the pid file.
2023-11-03_05:53:08.37259 29547:M 03 Nov 2023 13:53:08.372 * Removing the unix socket file.
2023-11-03_05:53:08.37259 29547:M 03 Nov 2023 13:53:08.372 # Redis is now ready to exit, bye bye…
2023-11-03_05:53:08.37791 8949:C 03 Nov 2023 13:53:08.377 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
2023-11-03_05:53:08.37792 8949:C 03 Nov 2023 13:53:08.377 # Redis version=5.0.7, bits=64, commit=4891612b, modified=0, pid=8949, just started
2023-11-03_05:53:08.37793 8949:C 03 Nov 2023 13:53:08.377 # Configuration loaded
2023-11-03_05:53:08.37967 8949:M 03 Nov 2023 13:53:08.379 * Running mode=standalone, port=0.
2023-11-03_05:53:08.37968 8949:M 03 Nov 2023 13:53:08.379 # Server initialized
2023-11-03_05:53:08.38077 8949:M 03 Nov 2023 13:53:08.380 * DB loaded from disk: 0.001 seconds
2023-11-03_05:53:08.38077 8949:M 03 Nov 2023 13:53:08.380 * The server is now ready to accept connections at /var/opt/gitlab/redis/redis.socket

– File under /var/opt/gitlab/redis/
ls -al /var/opt/gitlab/redis
total 84
drwxr-x— 2 gitlab-redis git 4096 Nov 3 13:09 .
drwxr-xr-x 20 root root 4096 Nov 3 09:58 …
-rw------- 1 gitlab-redis gitlab-redis 27092 Nov 3 13:09 dump.rdb
-rw-r–r-- 1 gitlab-redis root 46927 Nov 3 09:04 redis.conf
srwxrwxrwx 1 gitlab-redis gitlab-redis 0 Nov 3 13:09 redis.socket

dpkg -r gitlab-ce and repeatly run apt-get install gitlab-ce=x till x=13.12.15, then create user/group/project from the ground up.