Login issue, getting error or just slow


Not very technical so take it easy on me. :wink: All checks are good but it’s really slow for users to login. It was giving a timeout error 504 but back to just slow at the moment. This just started a day or so ago and all I’ve done is the required security updates on the server. I also added several new users, but the VPS should handle this small amount. Should I move the DNS over to the domain provider, would that help? Using the MIAB DNS set-up currently. Any suggestions appreciated to speed up login to roundcube. Thanks everyone!


How many users do you have on your box. What VPS provider? What specs are the VPS (how much cpu, how much memory, how much disk space)? How much disk space do you have left?

ssh in the box run the following commands and provide the output?

df -h 
top | head   
cat /proc/cpuinfo | grep "model name"
grep -E 'MemTotal|MemFree|MemAvailable' /proc/meminfo

Also assuming your running the latest version of MiaB ?
did you try re-running:

curl -s https://mailinabox.email/setup.sh | sudo -E bash

The DNS server is hardly any load.

Tried what you suggested but no one can login to email, still. It did allow a few logins after I posted here earlier but that was short lived, and emails were going through too. Everything else seems fine and I actually had about five different accounts running for a few days but added around 20 more users last night. So, one answer is around 25 users at the moment but was hopping to add many more from the community.

The VPS is 8GB, 4CPU, memory is 89% free and disk is 151.21 free out of 160. I should be good for now. There has to be an issue with roundcube allowing everyone to login, I have no clue what to do. 504 Gateway time-out, all other pages and services work fine like Calander etc.

If someone can lead me in the right direction to get the users able to login it would be greatly appreciated, hate to ditch the project. Thanks everyone.

This just now started working, been messing with it all night. If it’s what I’m hoping it was then I’ll post it here. Thanks.

The solution to this issue was to disable backups on the MIAB admin dashboard. It was full which didn’t allow users to login to email. I was head down in my VPS looking for the issue when it was a simple fix. :wink:

At best, this is should be considered a temporary solution.

When backups run the website becomes temporarily unavailable. As I understand it this is due to the services for the “box” being shutdown during the backup process in order to guarantee that a useable backup is created. I on the other hand do not use the builtin backup feature of MiaB. I run this server in a virtualized environment and I am taking backups of the entire virtual machine running. I am not sure if VPS offer this, but I believe it is commonly referred to as a ‘snapshot’. This keeps the box running at all times and relies on VM tools to quiesce the file system.

I have tested my backups and they work fine, however I’m not about to recommend something that is outside the scope of the project and therefore largely unsupported here. It at your own risk (which I guess you could argue so is running your own mail server in general).

I am more curious if your box’s time is correct. I believe the backup script is set to happen at 3AM (specific to the time zone you are in) so unless you have a bunch of people checking mail at 3am then I’m not sure how this is much of a problem.

Maybe @openletter could comment if I am correct with the 3am thought…

Next question would be maybe you set a different time zone on your box?

box$   timedatectl

Should show you everything you need to know from the CLI.

I interpreted the problem as the storage was filled and this prevented users from logging in. The disabling of the backups (an option in the dashboard) was done to free up disk space.

1 Like

That isn’t how I read this…
I read that it as he had 151GB unused out of 160GB total. so he was only using about 9GB.

I guess only @Mark409 can comment on that for clarity.

Are backups taken at 3am?

You are correct, it said full on the dashboard therefore I disabled it. I will do backups elsewhere. For newbie’s like myself I wanted to point this out as I struggled to figure out why no one could login to email. Thanks again everyone…

You might want to verify where that storage space is going with something like:

sudo du -hd 1 /home/user-data/

To at least be sure it is the mail components using up the data.

This is what returned:

601M /home/user-data/owncloud
12K /home/user-data/www
272M /home/user-data/backup
56K /home/user-data/dns
8.0K /home/user-data/owncloud-backup
8.7M /home/user-data/mail
84K /home/user-data/ssl
882M /home/user-data/

I wouldn’t know if any of the above is out of line. I enabled backups on the VPS though.