Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Installation/Configuration

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 17th September 2012, 04:56
atjensen11 atjensen11 is offline
Senior Member
 
Join Date: Dec 2007
Posts: 199
Thanks: 9
Thanked 6 Times in 6 Posts
Default Broken Email Server in Multiserver Setup

I followed the multiserver setup How To for Debian.

Everything was working great until I tried to mess with it.

I originally setup the mail server with the hostname "mail1". I decided I wanted to change the hostname to "mx1".

I changed the value in the mail server's /etc/hostname and /etc/mailname files. I also went through /etc/postfix/main.cf and changed the appropriate hostnames.

I went into the ISPConfig administration panel on the primary server and changed the hostname of the mail server under System->Servers.

I then changed my mind and reverted all the changes I had made. After reverting the changes, the mail server will still send and receive emails, but it doesn't appear that they primary server can control the mail server anymore.

For example, I tried creating a new email domain of "example.com". That domain was never created under /var/vmail of the mail server.

Please help. I tried finding some log files, but the ISPConfig log file on the primary server was empty.
Reply With Quote
Sponsored Links
  #2  
Old 17th September 2012, 11:59
till till is online now
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 37,007
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

Most likely the mail server is not able to connect to the master server anymore trough mysql. The hostname of the slave servers (in this case the mail server) is part of the mysql user permissions, if you change the hostname of the mail server, it has to be changed in the /etc/hosts files of all servers in your cluster as well, then go trough all tables in the "mysql" MySQL database on the matser server, you will find the old hostname in several records, change all these records with e.g. phpmyadmin to the new hostname and then restart the mysql server on the master server.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 17th September 2012, 16:12
atjensen11 atjensen11 is offline
Senior Member
 
Join Date: Dec 2007
Posts: 199
Thanks: 9
Thanked 6 Times in 6 Posts
Default

Till,

When I was contemplating changing the hostname, I had planned to edit the entries in the database through phpmyadmin. It was at that point that I decided it was too much work and decided to revert back.

I believe I created one new user entry within phpmyadmin for the new server instead of changing the one already there.

I don't know if it helps at all, but there are some activities I can perform with the servers in the current state. For example, I can change the password of an email mailbox that was created prior to me messing with things. But as I mentioned, I cannot create a new domain.

I also found some information about debug logging in ISPConfig over at FAQForge. I did enable that and attempted both creating a new email domain and changing existing mailbox passwords. The debug messaging didn't seem to have any clues indicating a problem with the mail server.

Code:
2012-09-17 02:49	mail1.example.com	Debug	Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock	
2012-09-17 02:49	mail1.example.com	Debug	Processed datalog_id 877	
2012-09-17 02:49	mail1.example.com	Debug	Replicated from master: REPLACE INTO mail_domain (`domain_id`,`sys_userid`,`sys_groupid`,`sys_perm_user`,`sys_perm_group`,`sys_perm_other`,`server_id`,`domain`,`active`) VALUES ('16','1','0','riud','ru','','3','example.com','y')	
2012-09-17 02:49	mail1.example.com	Debug	Found 1 changes, starting update process.	
2012-09-17 02:49	mail1.example.com	Debug	Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
Code:
2012-09-17 02:51	mail1.example.com	Debug	Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock	
2012-09-17 02:51	mail1.example.com	Debug	Processed datalog_id 878	
2012-09-17 02:51	mail1.example.com	Debug	Calling function 'update' from plugin 'maildeliver_plugin' raised by event 'mail_user_update'.	
2012-09-17 02:51	mail1.example.com	Debug	Created Maildir /var/vmail/[existing domain]/[existing mailbox]/Maildir with subfolder: Junk	
2012-09-17 02:51	mail1.example.com	Debug	Created Maildir /var/vmail/[existing domain]/[existing mailbox]/Maildir with subfolder: Trash	
2012-09-17 02:51	mail1.example.com	Debug	Created Maildir /var/vmail/[existing domain]/[existing mailbox]/Maildir with subfolder: Drafts	
2012-09-17 02:51	mail1.example.com	Debug	Created Maildir /var/vmail/[existing domain]/[existing mailbox]/Maildir with subfolder: Sent	
2012-09-17 02:51	mail1.example.com	Debug	Created Directory: /var/vmail/[existing domain]	
2012-09-17 02:51	mail1.example.com	Debug	Calling function 'user_update' from plugin 'mail_plugin' raised by event 'mail_user_update'.	
2012-09-17 02:51	mail1.example.com	Debug	Replicated from master: REPLACE INTO mail_user (`mailuser_id`,`sys_userid`,`sys_groupid`,`sys_perm_user`,`sys_perm_group`,`sys_perm_other`,`server_id`,`email`,`login`,`password`,`name`,`uid`,`gid`,`maildir`,`quota`,`cc`,`homedir`,`autoresponder`,`autoresponder_start_date`,`autoresponder_end_date`,`autoresponder_text`,`move_junk`,`custom_mailfilter`,`postfix`,`access`,`disableimap`,`disablepop3`,`disabledeliver`,`disablesmtp`,`disablesieve`,`disablelda`) VALUES ('16','1','0','riud','riud','','3','[existing mailbox]','[existing mailbox]','[password]','[name]','5000','5000','/var/vmail/[existing domain]/[existing mailbox]','0','','/var/vmail','n','0000-00-00 00:00:00','0000-00-00 00:00:00','','n','[custom_mailfilter]','y','n','n','n','n','n','n','n')	
2012-09-17 02:51	mail1.example.com	Debug	Found 1 changes, starting update process.	
2012-09-17 02:51	mail1.example.com	Debug	Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock

Last edited by atjensen11; 17th September 2012 at 16:23.
Reply With Quote
  #4  
Old 17th September 2012, 17:57
till till is online now
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 37,007
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

The debug output seems to be ok. Has the maildir /var/vmail/[existing domain]/[existing mailbox]/Maildir been created?
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #5  
Old 17th September 2012, 19:07
atjensen11 atjensen11 is offline
Senior Member
 
Join Date: Dec 2007
Posts: 199
Thanks: 9
Thanked 6 Times in 6 Posts
Default

Till,

The first debug output I posted is from when I try to add a new email domain that hasn't been previously created on this server. In this case, the folders are NOT created on the mail server.

The second debug output I posted is from when I made changes to the password of an existing mailbox that was created prior to me messing things up. Therefore, the domain and mailbox folders already existed on the mail server. Furthermore, the password is actually changed so it appears that ISPConfig is performing the correct action.
Reply With Quote
  #6  
Old 19th September 2012, 04:27
atjensen11 atjensen11 is offline
Senior Member
 
Join Date: Dec 2007
Posts: 199
Thanks: 9
Thanked 6 Times in 6 Posts
Default

I did some more testing last night and today.

When I create a new email domain, I have verified that it is populated within the ISPConfig database on the master server. As I've mentioned, I no longer see the folder physically created in the /var/vmail directory on the mail server.

I have also verified that the new email domain is populated within the ISPConfig database on the mail server (not master server).

Similarly, if I delete the email domain, the domain is removed from the ISPConfig database on both servers.

I am using the mail_domain table to perform this testing.

I also created a new email mailbox for a domain that was existing prior to my changes which broke this feature. This test was successful as a new user folder was created under the /var/vmail/[existing domain]/ directory.

Therefore, I am led to believe the issue has to do with any scripts that are run after populating the database. However, I don't know ISPConfig well enough to test these scripts.

I also performed the additional troubleshooting steps from the FaqForge article. The result when I run the server.sh script is rather uneventful with no errors reported.

Code:
root@mail1:/# /usr/local/ispconfig/server/server.sh
finished.
I would appreciate any additional help on this matter.

Last edited by atjensen11; 19th September 2012 at 04:54.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
User unknown in relay recipient table Taxick Installation/Configuration 12 9th April 2013 13:31
Local mail server - final touch Alexhor Installation/Configuration 4 12th April 2012 23:33
ISPConfig3 mail doesn't work Marr General 6 1st September 2010 10:32
problem with upgrade to 2.2.34 brianetilley Installation/Configuration 14 11th November 2009 18:22
Webmail Relay Error palkat General 17 23rd April 2006 19:12


All times are GMT +2. The time now is 12:28.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.