Comments (9)
Ok now I get these but no clue why it is failing!!
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:28:00Z" level=info msg="new dump" archive= err="after 3 retries, mongodump log : exit status 1" mlog=
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:28:00Z" level=error msg="BACKUP FAILED: after 3 retries, mongodump log : exit status 1" plan=backup
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:28:00Z" level=info msg="Next run at 2024-05-08 12:30:00 +0000 UTC" plan=backup
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:30:00Z" level=info msg="Backup started" plan=backup
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:30:00Z" level=info msg="new dump" archive= err="after 3 retries, mongodump log : exit status 1" mlog=
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:30:00Z" level=error msg="BACKUP FAILED: after 3 retries, mongodump log : exit status 1" plan=backup
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:30:00Z" level=info msg="Next run at 2024-05-08 12:32:00 +0000 UTC" plan=backup
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:32:00Z" level=info msg="Backup started" plan=backup
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:32:00Z" level=info msg="new dump" archive= err="after 3 retries, mongodump log : exit status 1" mlog=
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:32:00Z" level=error msg="BACKUP FAILED: after 3 retries, mongodump log : exit status 1" plan=backup
mgob.1.mgrroaog849a@manager1 | time="2024-05-08T12:32:00Z" level=info msg="Next run at 2024-05-08 12:34:00 +0000 UTC" plan=backup
What can I do?
from mgob.
Trying maxisam/mgob:2.0.20-aws
but same issue.
from mgob.
I got it to work with this config
# mgob/config/backup.yml
#
scheduler:
cron: "*/2 * * * *" # run every day at 6:00 and 18:00 UTC
retention: 14 # Retains 14 local backups
timeout: 60 # Operation timeout: 60 minutes
target:
uri:
noGzip: false # Disable gzip compression (false means compression is enabled)
retry:
attempts: 3 # number of retries
backoffFactor: 60 # backoff factor * (2 ^ attemptCount) seconds
validation:
database:
uri:
noGzip: false
s3:
url:
bucket:
accessKey:
secretKey:
api: "S3v4"
and changing the environment variables like so
docker service create --name mgob \
-p 8090:8090 \
--mount type=bind,src=./mgob/config,dst=/config \
--mount type=bind,src=./mgob/storage,dst=/storage \
-e BACKUP__TARGET_URI=xxx \
-e BACKUP__VALIDATION_DATABASE_URI=xxx \
-e BACKUP__S3_BUCKET=xxx \
-e BACKUP__S3_ACCESSKEY=xxx \
-e BACKUP__S3_SECRETKEY=xxx \
--constraint node.labels.mongo.replica==1 \
maxisam/mgob:2.0.20-aws -LogLevel=debug
Readme uses lowercase for plan names however, the PLAN.md file suggests using all caps. So some discrepency in the docs
from mgob.
I was having some issues with the validation step, so I removed validation block completely and now I get this weird error which I can't figure out
level=error msg="BACKUP FAILED: mc config host for plan backup failed /bin/sh: mc: not found : exit status 127" plan=backup
what is mc
?
from mgob.
Can we improve documentation? It looks like there's one more issue #108 where validation isn't that clear and I couldn't find anything in the documentation about this step.
from mgob.
Looks like minioUpload
function is being called here
Line 89 in 0bf2926
which is weird because I am using s3 in my config and I am using maxisam/mgob:2.0.20-aws
image.
Should mc
be included in this image by default?
from mgob.
It looks like after including BACKUP__S3_URL
environment variable, s3Upload is called and we don't have the mc
not found error anymore.
However, now we get
level=error msg="BACKUP FAILED: S3 uploading /tmp/backup-1715193000.gz to backup/backup-mongo-staging-backups failed : exit status 1" plan=backup
for
docker service create --name mgob \
-p 8090:8090 \
--mount type=bind,src=./mgob/config,dst=/config \
--mount type=bind,src=./mgob/storage,dst=/storage \
-e BACKUP__TARGET_URI=xxx \
-e BACKUP__S3_BUCKET=xxx \
-e BACKUP__S3_ACCESSKEY=xxx \
-e BACKUP__S3_SECRETKEY=xxx \
-e BACKUP__S3_URL=https://s3.amazonaws.com \
--constraint node.labels.mongo.replica==1 \
maxisam/mgob:2.0.20-aws -LogLevel=debug
is the url supposed to be https://s3.amazonaws.com
? and can the error be any more verbose than "exit status 1"??
from mgob.
I believe two things can help me:
- Add some documentation about what the validation step is and how it's helpful
- Improve error handling and reporting. Most of the times I only get "exit status 1". What and why is not clear. In case it's failure from aws authentication perspective, those errors must be propagated and conveyed properly.
from mgob.
Digging further, the error seems to be
An error occurred (AccessDenied) when calling the CreateMultipartUpload operation: Access Denied`
When I try to execute aws s3 cp /tmp/planxxx.gz s3://bucket_name/
I get the above.
This is an issue with the configured AWS S3 bucket policy. However, in mgob, I get the output to be simply exit status 1
. It would be nice to show the actual error message.
from mgob.
Related Issues (20)
- Error running backup HOT 3
- Error sending notification email HOT 5
- support mongo dump excludeCollectionsWithPrefix or excludeCollections HOT 1
- feature request: skip move dumped file from /temp to /storage to save time HOT 4
- feature request: include more database engines HOT 1
- CVE-2023-37920 Critical 9.8 HOT 1
- how to store passwords securely HOT 4
- Configure target with connection string URI HOT 3
- Configuration via environment variables HOT 3
- Error: unable to install chart HOT 4
- feat: update helm chart to load external secrets as environment
- Issues with latest helm chart 1.8.3 HOT 5
- Environment variables injection HOT 3
- Plan name with "-" doesn't work with environment variable HOT 1
- Feature Request: Restore Collections
- Feature request: always preserve 1 version of the log HOT 1
- create Pod common-mgob-0 in StatefulSet common-mgob failed error: Pod "common-mgob-0" is invalid: spec.initContainers[0].name: Duplicate value: "init-cleanup" HOT 1
- gpg bin missing in latest image HOT 7
- how does the validation step work? HOT 3
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 mgob.