Comments (9)
Scheduled backup is a crontab task for the user git
. You are setting GITLAB_BACKUP_DIR
to /backup/
and it means the backup will be about to created in /backup/
(top level directory of filesystem) that causes permission error.
Just set GITLAB_BACKUP_DIR
to the directory where the user git
have write permission, or just remove it to use default value $GITLAB_DATA_DIR/backup
(will be expanded to /home/git/data/backup
).
from docker-gitlab.
I have added 777 permissions here, but it still doesn't seem to work. Let me remove GITLAB_BACKUP_DIR and give it a try.
from docker-gitlab.
But it seems that the backup is still not triggered. How can I check the log?
from docker-gitlab.
The filename for backup is /var/log/gitlab/gitlab/backup_json.log
.
Logs are stored in $GITLAB_LOG_DIR
(/var/log/gitlab/gitlab
. /home/git/gitlab/log
is symlink for the directory. In /var/log/gitlab/
, there are logs for other middleware like gitaly, gitlab-shell, nginx and supervisor.
Also, you may want to refer #2790 . If your problem is related to this ticket and I was mistaken, you should be able to use the original GITLAB_BACKUP_DIR
configuration as they are chown
ed automatically.
from docker-gitlab.
Logfile created on 2024-02-18 19:00:24 +0800 by logger.rb/v1.5.0
{"severity":"INFO","time":"2024-02-18T11:00:24.692Z","correlation_id":null,"message":"Dumping database ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.299Z","correlation_id":null,"message":"Dumping database ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.299Z","correlation_id":null,"message":"Dumping repositories ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.730Z","correlation_id":null,"message":"Dumping repositories ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.730Z","correlation_id":null,"message":"Dumping uploads ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.739Z","correlation_id":null,"message":"Dumping uploads ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.739Z","correlation_id":null,"message":"Dumping builds ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.742Z","correlation_id":null,"message":"Dumping builds ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.742Z","correlation_id":null,"message":"Dumping artifacts ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.751Z","correlation_id":null,"message":"Dumping artifacts ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.751Z","correlation_id":null,"message":"Dumping pages ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.754Z","correlation_id":null,"message":"Dumping pages ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.754Z","correlation_id":null,"message":"Dumping lfs objects ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.756Z","correlation_id":null,"message":"Dumping lfs objects ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.756Z","correlation_id":null,"message":"Dumping terraform states ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.766Z","correlation_id":null,"message":"Dumping terraform states ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.766Z","correlation_id":null,"message":"Dumping container registry images ... [DISABLED]"}
{"severity":"INFO","time":"2024-02-18T11:00:29.766Z","correlation_id":null,"message":"Dumping packages ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.769Z","correlation_id":null,"message":"Dumping packages ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.769Z","correlation_id":null,"message":"Dumping ci secure files ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.769Z","correlation_id":null,"message":"Deleting tar staging files ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.770Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/db"}
{"severity":"INFO","time":"2024-02-18T11:00:29.770Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/repositories"}
{"severity":"INFO","time":"2024-02-18T11:00:29.772Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/uploads.tar.gz"}
{"severity":"INFO","time":"2024-02-18T11:00:29.772Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/builds.tar.gz"}
{"severity":"INFO","time":"2024-02-18T11:00:29.773Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/artifacts.tar.gz"}
{"severity":"INFO","time":"2024-02-18T11:00:29.773Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/pages.tar.gz"}
{"severity":"INFO","time":"2024-02-18T11:00:29.773Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/lfs.tar.gz"}
{"severity":"INFO","time":"2024-02-18T11:00:29.773Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/terraform_state.tar.gz"}
{"severity":"INFO","time":"2024-02-18T11:00:29.774Z","correlation_id":null,"message":"Cleaning up /home/git/data/backups/packages.tar.gz"}
{"severity":"INFO","time":"2024-02-18T11:00:29.774Z","correlation_id":null,"message":"Deleting tar staging files ... done"}
{"severity":"INFO","time":"2024-02-18T11:00:29.774Z","correlation_id":null,"message":"Deleting backups/tmp ... "}
{"severity":"INFO","time":"2024-02-18T11:00:29.774Z","correlation_id":null,"message":"Deleting backups/tmp ... done"}
from docker-gitlab.
Hmm, it seems that backup operation is triggered correctly but aborted after the line Dumping ci_secure_files
. Could you check crontab log /var/log/gitlab/gitlba/gitlab-backup.log
? It contains exact log of rake task gitlab:backup:create
.
from docker-gitlab.
2024-02-18 19:00:24 +0800 -- Dumping database ...
Dumping PostgreSQL database gitlab_production ... [DONE]
2024-02-18 19:00:29 +0800 -- Dumping database ... done
2024-02-18 19:00:29 +0800 -- Dumping repositories ...
{"command":"create","gl_project_path":"root/ci-test","level":"info","msg":"started create","pid":1881,"relative_path":"@hashed/6b/86/6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b.git","storage_name":"default","time":"2024-02-18T11:00:29.538Z"}
{"command":"create","gl_project_path":"root/ci-test","level":"info","msg":"completed create","pid":1881,"relative_path":"@hashed/6b/86/6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b.git","storage_name":"default","time":"2024-02-18T11:00:29.571Z"}
{"command":"create","gl_project_path":"root/ci-test.wiki","level":"info","msg":"started create","pid":1881,"relative_path":"@hashed/6b/86/6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b.wiki.git","storage_name":"default","time":"2024-02-18T11:00:29.613Z"}
{"command":"create","gl_project_path":"apipost/be/apipost-work","level":"info","msg":"started create","pid":1881,"relative_path":"@hashed/4e/07/4e07408562bedb8b60ce05c1decfe3ad16b72230967de01f640b7e4729b49fce.git","storage_name":"default","time":"2024-02-18T11:00:29.619Z"}
{"command":"create","gl_project_path":"root/ci-test.wiki","level":"info","msg":"completed create","pid":1881,"relative_path":"@hashed/6b/86/6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b.wiki.git","storage_name":"default","time":"2024-02-18T11:00:29.622Z"}
{"command":"create","gl_project_path":"apipost/be/apipost-work","level":"info","msg":"completed create","pid":1881,"relative_path":"@hashed/4e/07/4e07408562bedb8b60ce05c1decfe3ad16b72230967de01f640b7e4729b49fce.git","storage_name":"default","time":"2024-02-18T11:00:29.641Z"}
{"command":"create","gl_project_path":"apipost/be/apipost-work.wiki","level":"info","msg":"started create","pid":1881,"relative_path":"@hashed/4e/07/4e07408562bedb8b60ce05c1decfe3ad16b72230967de01f640b7e4729b49fce.wiki.git","storage_name":"default","time":"2024-02-18T11:00:29.694Z"}
{"command":"create","gl_project_path":"apipost/be/apipost-work.wiki","level":"info","msg":"completed create","pid":1881,"relative_path":"@hashed/4e/07/4e07408562bedb8b60ce05c1decfe3ad16b72230967de01f640b7e4729b49fce.wiki.git","storage_name":"default","time":"2024-02-18T11:00:29.704Z"}
2024-02-18 19:00:29 +0800 -- Dumping repositories ... done
2024-02-18 19:00:29 +0800 -- Dumping uploads ...
2024-02-18 19:00:29 +0800 -- Dumping uploads ... done
2024-02-18 19:00:29 +0800 -- Dumping builds ...
2024-02-18 19:00:29 +0800 -- Dumping builds ... done
2024-02-18 19:00:29 +0800 -- Dumping artifacts ...
2024-02-18 19:00:29 +0800 -- Dumping artifacts ... done
2024-02-18 19:00:29 +0800 -- Dumping pages ...
2024-02-18 19:00:29 +0800 -- Dumping pages ... done
2024-02-18 19:00:29 +0800 -- Dumping lfs objects ...
2024-02-18 19:00:29 +0800 -- Dumping lfs objects ... done
2024-02-18 19:00:29 +0800 -- Dumping terraform states ...
2024-02-18 19:00:29 +0800 -- Dumping terraform states ... done
2024-02-18 19:00:29 +0800 -- Dumping container registry images ... [DISABLED]
2024-02-18 19:00:29 +0800 -- Dumping packages ...
2024-02-18 19:00:29 +0800 -- Dumping packages ... done
2024-02-18 19:00:29 +0800 -- Dumping ci secure files ...
rake aborted!
Errno::ENOENT: No such file or directory @ rb_check_realpath_internal - /home/git/data/shared/ci_secure_files
/home/git/gitlab/lib/backup/files.rb:156:in realpath' /home/git/gitlab/lib/backup/files.rb:156:in
app_files_realpath'
/home/git/gitlab/lib/backup/files.rb:46:in dump' /home/git/gitlab/lib/backup/manager.rb:71:in
run_create_task'
/home/git/gitlab/lib/backup/manager.rb:227:in block in run_all_create_tasks' /home/git/gitlab/lib/backup/manager.rb:226:in
each_key'
/home/git/gitlab/lib/backup/manager.rb:226:in run_all_create_tasks' /home/git/gitlab/lib/backup/manager.rb:47:in
create'
/home/git/gitlab/lib/tasks/gitlab/backup.rake:13:in block in create_backup' /home/git/gitlab/lib/tasks/gitlab/backup.rake:62:in
lock_backup'
/home/git/gitlab/lib/tasks/gitlab/backup.rake:10:in create_backup' /home/git/gitlab/lib/tasks/gitlab/backup.rake:101:in
block (3 levels) in <top (required)>'
/home/git/gitlab/vendor/bundle/ruby/3.1.0/gems/sentry-ruby-5.10.0/lib/sentry/rake.rb:26:in execute' /home/git/gitlab/vendor/bundle/ruby/3.1.0/gems/rake-13.0.6/exe/rake:27:in
<top (required)>'
/usr/local/bin/bundle:25:in load' /usr/local/bin/bundle:25:in
Tasks: TOP => gitlab:backup:create
(See full trace by running task with --trace)
2024-02-18 19:00:29 +0800 -- Deleting tar staging files ...
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/db
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/repositories
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/uploads.tar.gz
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/builds.tar.gz
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/artifacts.tar.gz
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/pages.tar.gz
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/lfs.tar.gz
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/terraform_state.tar.gz
2024-02-18 19:00:29 +0800 -- Cleaning up /home/git/data/backups/packages.tar.gz
2024-02-18 19:00:29 +0800 -- Deleting tar staging files ... done
2024-02-18 19:00:29 +0800 -- Deleting backups/tmp ...
2024-02-18 19:00:29 +0800 -- Deleting backups/tmp ... done
2024-02-18 19:00:29 +0800 -- Deleting backup and restore PID file ... done
from docker-gitlab.
What is ci_secure_files and how do I deal with it
I look #2790
from docker-gitlab.
I've solved it, thank you
from docker-gitlab.
Related Issues (20)
- ENOENT: No such file or directory HOT 4
- problem deleting image or tag 16.6.1 HOT 13
- 16.7.0: Rake aborts launch with "failed to get urandom" HOT 36
- Migrate gitlab 11.10.4 to gitlab 16.6.2 with mysql to postgresql
- Error fetching repo data HOT 1
- CVE-2023-7028 HOT 3
- Upgrade Ruby to 3.2.x to remove bug introduced on Ruby 3.1.x HOT 3
- Unable to fetch commit when using --depth 1 mode
- GitLab Critical Security Release: 16.8.1, 16.7.4, 16.6.6, 16.5.8 HOT 1
- How to backup GitLab in Kubernetes? Do you have any good ideas, templates, or documentation? I'm not very familiar with Kubernetes, so please help me. HOT 2
- Backups not functioning in v16.8.1 HOT 3
- [Question] How to change the clone link from localhost to my domain? HOT 2
- Support setting `global_time_tracking_report` HOT 1
- How is openid_connect_signing_key handled? HOT 1
- level=error correlation_id= duration_ms=0 error="badgateway: failed to receive response: dial unix /home/git/gitlab/tmp/sockets/gitlab.socket: connect: no such file or directory
- Please support pages namespace_in_path
- Web log-in broken HOT 2
- missing 16.1.6 and 16.3.7 version needed for upgrade path HOT 10
- postgres (PostgreSQL) 15.1 (Debian 15.1-1.pgdg110+1) image no longer exists HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docker-gitlab.