ispconfig 3.1 server config mail settings

Discussion in 'Installation/Configuration' started by edwintenhaaf, Oct 23, 2016.

  1. edwintenhaaf

    edwintenhaaf New Member

    I had some problems with postfix. Did some edits in and and after that I noticed that the mail settings were missing in the ispconfig gui. This gives me several errors, even after filling in the default settings the message "Uid-mapping cannot be changed if there are already mail users." keeps coming back.

    Is there a way to get this working again ? Reset ?
    I cannot configure DKIM because the path is missing. Postfix is running ok now.

    Thanks in advance,

    Maildir Path is empty.
    Invalid maildir path.
    Homedir Path is empty.
    Invalid homedir path.
    Mailuser uid must be >= 2000
    Mailuser gid must be >= 2000
    Mailuser Name is empty.
    Invalid mailuser name.
    Mailuser Group is empty.
    Invalid mailuser group name.
    Uid-mapping cannot be changed if there are already mail users.
  2. flyboy320

    flyboy320 New Member

    I did the exact same thing and now the GUI is giving me the errors above. Can anyone post the default settings from the Server Config - Mail page? Any help would be greatly appreciated.
  3. flyboy320

    flyboy320 New Member

    I was able to find the default settings in the manual but when I try to save it, I still get the error:

    Uid-mapping cannot be changed if there are already mail users.

    I am running ISPConfig Version: 3.1.1p1 on Ubuntu 12.04 LTS

    I could not find any information online about the above error.

    Thanks in advance.
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    You enabled uid mailuser connection and this setting can not be undone after you added a mail account on the server as removing it would break the mail accounts.
  5. flyboy320

    flyboy320 New Member

    Thanks for the reply. All I did was manually add an RBL in and the GUI started giving me the errors above. I have not created any new mailboxes in over a year. Is there a way to use the GUI again for system config - mail? I only have a couple of email accounts so deleting them and recreating them is not an issue at this time.
  6. eddul

    eddul New Member

    I am also a victim of lost mail settings and couldn't save new ones because of uid-mapping check.
    Running (Debian Jessie) ISPConfig 3.1.1p1

    My problem started after fooling around with doveadm to clear out unwanted mails from a users mailbox, could be coincidence but not much other activity on this testserver.

    Looking at dbispconfig mail_user table I found that somehow that users uid and gid got changed to 0 (was 5000) and both columns maildir and homedir got emptied out. (some should-be-NULL values also got changed to empty text). This is the first mail user created on the server.
    Tried changing the values back in phpMyAdmin but no luck, they soon got messed up again.

    My reverse engineering efforts made me expect to see a section for mail settings in table 'server' column 'config' but there was none on my server.

    One dirty thought I got was to temporarily disable the uid-change validation in /usr/local/ispconfig/interface/lib/classes/ so I commented out lines 64 to 66 and was able to save some hopefully valid values!

    Checked server config column and there's now a [mail] section present, corrected the corrupted users mail_user columns and tested larching some mails to it and all seems well at time of writing!

    Now to figure out what caused this....... :confused:
    I reckon the missing [mail] section trigger the validation error whatever value you put in, but how did it go missing?

    Long time user first time poster BTW, thanks for this wonderful piece of software! :)
  7. flyboy320

    flyboy320 New Member

    Thanks for the info. My fix was a little more hammer and little less scalpel. As my server was due for an OS upgrade from 12.04 LTS to 16.04 LTS, so I just built a new server. The last time I did a Ubuntu OS upgrade from LTS to LTS, it was a catastrophic failure and I ended up rebuilding anyway so it all works in the end.
  8. Hi all,
    On a standalone server, this has just happened to me : All fields in System / server config / Mail have becomed blank.
    I took values from another working ISPConfig server and re-entered them.
    I get error :
    Uid-mapping cannot be changed if there are already mail users.
    Of course I have NOT checked the
    Use Websites Linux uid for mailbox
    I haven't added any email user.
    Server is : Ubuntu 16.04.5 LTS running ISPConfig 3.1.13
    Mail user / group are still vmail/vmail on filesystem.
    Postfix and Dovecot are still running.
    Could you please assist with this ? I'm 'a bit' afraid to reboot the server.

    Edit : log-level set to DEBUG doesn't show anything apart from casual
    07.12.2018-12:22 - DEBUG - Calling function 'check_phpini_changes' from plugin 'webserver_plugin' raised by action 'server_plugins_loaded'.
    07.12.2018-12:22 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    Attached picture is what the mail tab looks like.

    Attached Files:

    Last edited: Dec 7, 2018
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    The data is stored in .ini format in the 'server' table in mysql, the field is named 'config'. get the [mail] config part from a working server and replace the one on the broken system. You can edit the data in phpmyadmin.

    Rebooting should be no issue, this data is used when you create new mailboxes in ispconfig, that's nothing that is used in boot process. So the worst that could happen is that a new mailbox does not work.
    electronico_nc likes this.
  10. Thanks @till
    That's OK now, the complete [mail] section was deleted ...

Share This Page