Coder Social home page Coder Social logo

Comments (7)

asifbacchus avatar asifbacchus commented on May 29, 2024

Anything in your docker logs? Are the containers stopped? Can you start them manually without errors?

You can check logs with

docker logs containername

And you can manually start them with

cd /your/mailcow/directory
docker-compose start containername

Has the script run in the past or is this the first time you are running it? Also, have you manually named your containers or are you using the defaults?

Finally, could you please give me the exact command you are using to invoke the script?

from mailcowbackup.

Ry3nlNaToR avatar Ry3nlNaToR commented on May 29, 2024

The first time I've used this script to backup the script dose manage to stop and start the containers it just returns a false error saying it couldn't since the output is also mentioning docker inspect" requires at least 1 argument.

The issue is probably caused by this line

dockerResultState="$(docker inspect -f '{{ .State.Running }}' $containerName)"
that check if the container is running.

The command I used to run is /root/backup/backup.sh -m "/root/mailcow/mailcow.conf" all the containers are the default name.

The script dose manage backup and start and stop everything I could just add >/dev/null 2>&1 to cronjob line to hide the output.

from mailcowbackup.

asifbacchus avatar asifbacchus commented on May 29, 2024

First of all, I would always run a cronjob with > /dev/null 2>&1 regardless, good call on that.

Give me a day to spin up the latest mailcow on a test server and have a look. I haven't updated in a few months so maybe something has changed in how the containers are named or something and that is causing the script to generate false errors.

Out of interest, if you run the script normally as root at the console do you get any errors? If you are only getting errors when running as a cronjob I have a whole different idea of why that could be happening -- let me know?

I'm glad it's at least getting your backups done! Thx for letting me know about this issue.

from mailcowbackup.

asifbacchus avatar asifbacchus commented on May 29, 2024

Just an update -- I managed to duplicate the error you are finding and it is indeed only on newer versions of mailcow. I'll track the issue down, just wanted to give you a heads up, haven't forgotten about you, @Ry3nlNaToR :-)

from mailcowbackup.

asifbacchus avatar asifbacchus commented on May 29, 2024

Ok, I was wrong, it was actually just a sloppy mistake I never noticed before. I was checking names of only running containers and, obviously, postfix and dovecot would not be running after they were stopped! Should be resolved now.

commit: 04bc748

from mailcowbackup.

asifbacchus avatar asifbacchus commented on May 29, 2024

New minor release Version 1.5.1 includes this fix. Just noting for anyone that finds this issue.

@Ry3nlNaToR please confirm this fixes your issue and I'll close this. Thanks again!

from mailcowbackup.

Ry3nlNaToR avatar Ry3nlNaToR commented on May 29, 2024

Just tested error now gone.

Thanks.

from mailcowbackup.

Related Issues (13)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.