Solved

Postfix Access table issue, New account emails are not being recorded in the acccess table running Exchange 2003

Posted on 2010-09-04
16
398 Views
Last Modified: 2012-05-10
Dear Experts,

Over past two weeks, new email address are not being recorded in the access.db. I am running exchange 2003 enterprise and running postfix as mail relay and normally when we create new email account, the email address gets recorded in postfix access table which enables it to relay emails externally and receive emails from external users.

but if I email that account from my gmail account, the email gets bounced back stating rejected.

Can you please let me know, when can we do to resolve this. There was some kind of tool that runs on exchange that scans ad for new emails and updates  postfix, not sure but that not running anymore.

Please help, experts.

0
Comment
Question by:mshaikh22
  • 11
  • 5
16 Comments
 
LVL 14

Assisted Solution

by:svgmuc
svgmuc earned 500 total points
ID: 33602661
Are you running postmap on the access file?
0
 

Author Comment

by:mshaikh22
ID: 33602739
i run that command manually postmap access
its still doesnt do anything
the email address dont exist in the access table
tried adding them manually by doing nano access.db
entered the email address manually and save the access.db file restarted postfix.

Worked a few times and after that stopped working
looks the email addresses i put disppear afterward now it doesnt save at all.
0
 

Author Comment

by:mshaikh22
ID: 33604487
Hello Experts,


Just wanted to see if anyone has experience this issue before caz im still wondering how to solve this riddle.
Please let me know as soon as you can,

0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 

Author Comment

by:mshaikh22
ID: 33722504
Need help with this. I keep manually entering email address in the access.db table. But it disappears after a few days
0
 

Author Comment

by:mshaikh22
ID: 34036471
Can you please tell why do the email address that I enter in the database access.db disappear.
0
 
LVL 14

Assisted Solution

by:svgmuc
svgmuc earned 500 total points
ID: 34036532
Either something is overwriting your access.db file or your access file is changed and remapped. Check the system for cron jobs.
0
 

Author Comment

by:mshaikh22
ID: 34037905
Thank you for that svgmuc. Could you please tell me know where can i look for the cron jobs.
Am I suppose to enter email address manually in the access.db or does the cron job run and does update the emails for me.

0
 
LVL 14

Assisted Solution

by:svgmuc
svgmuc earned 500 total points
ID: 34037995
You can run the command

crontab -l

as the user root or the user postfix is running as.
This will list all cron jobs.

A cron job can be any kind of command or script. It may modify data which includes your access.db file. I have no idea though, what is on your mail server.
0
 

Author Comment

by:mshaikh22
ID: 34038265
this is what i see


0 0,6,12,18,21 * * *       /usr/bin/freshclam
0 0 * * *       /usr/bin/sa-update
0,10,30,50 * * * * /usr/local/bin/exchange-email-push
0 23 * * * find /home/quarantine/ -mtime +10 -exec rm -f {} \;
0
 

Author Comment

by:mshaikh22
ID: 34038503
0,10,30,50 * * * * /usr/local/bin/exchange-email-push

how does this work

exchange-email-push
Connected to ex0svr
220 Microsoft FTP Service
500 'AUTH GSSAPI': command not understood
500 'AUTH KERBEROS_V4': command not understood
KERBEROS_V4 rejected as an authentication type
331 Anonymous access allowed, send identity (e-mail name) as password.
230 Anonymous user logged in.
Local directory now /etc/postfix
local: public.emails remote: public.emails
227 Entering Passive Mode (10,168,1,35,134,203).
125 Data connection already open; Transfer starting.
226 Transfer complete.
313123 bytes received in 0.016 seconds (2e+04 Kbytes/s)
local: users.emails remote: users.emails
227 Entering Passive Mode (10,168,1,35,134,206).
125 Data connection already open; Transfer starting.
226 Transfer complete.
334851 bytes received in 0.018 seconds (1.9e+04 Kbytes/s)
221
0
 

Author Comment

by:mshaikh22
ID: 34073178
can i get some help on this please.
0
 

Author Comment

by:mshaikh22
ID: 34116737
help please

0,10,30,50 * * * * /usr/local/bin/exchange-email-push

how does this work

exchange-email-push
Connected to ex0svr
220 Microsoft FTP Service
500 'AUTH GSSAPI': command not understood
500 'AUTH KERBEROS_V4': command not understood
KERBEROS_V4 rejected as an authentication type
331 Anonymous access allowed, send identity (e-mail name) as password.
230 Anonymous user logged in.
Local directory now /etc/postfix
local: public.emails remote: public.emails
227 Entering Passive Mode (10,168,1,35,134,203).
125 Data connection already open; Transfer starting.
226 Transfer complete.
313123 bytes received in 0.016 seconds (2e+04 Kbytes/s)
local: users.emails remote: users.emails
227 Entering Passive Mode (10,168,1,35,134,206).
125 Data connection already open; Transfer starting.
226 Transfer complete.
334851 bytes received in 0.018 seconds (1.9e+04 Kbytes/s)
221
0
 
LVL 14

Expert Comment

by:svgmuc
ID: 34118018
This is just the output of a script.
According to the crontab line, it is run at the full hour, at 10min after the full hour, at 30min after the full hour and 10min to the full hour. (Strange schedule)

It transfers 2 files via FTP, public.emails and users.emails from the server to the postfix server.

I cannot see any other information from this output.
0
 

Author Comment

by:mshaikh22
ID: 34310557
Apologies for getting back you  on this.

Could you please help me with this, im thinking whenever this script runs it remove the manually entered email address in access db. Now there something missing in exhcange that prevents the script from running. What could that be.

thank you./


This is the is the script

#!/bin/bash

EXCHANGE=exchange2003
USER=anonymous
NACCESS=access.new
TMP=access.tmp

ftp -v -n "$EXCHANGE" << EOF
user "$USER" sysadmin
lcd /etc/postfix/
get public.emails
get users.emails
quit
EOF
if [ "$?" -ne 0 ]; then
        echo "FTP Exchange push failed to grab new files"
        exit 1
fi


cd /etc/postfix/
# make a copy of the current
cp -f access access.old
cat access.header > "$NACCESS"
cat /dev/null > "$TMP"
/bin/egrep -o '(smtp|SMTP):(.*)' users.emails | sed 's/^smtp://' | sed 's/^SMTP://' | awk '{ print $0"\tOK"; }' >> "$TMP"
/bin/egrep -o '(smtp|SMTP):(.*)' public.emails | sed 's/^smtp://' | sed 's/^SMTP://' | awk '{ print $0"\tOK"; }' >> "$TMP"
sort -u "$TMP" >> "$NACCESS"
mv "$NACCESS" access

#--- update the system
postmap /etc/postfix/access
postfix reload

0
 
LVL 14

Accepted Solution

by:
svgmuc earned 500 total points
ID: 34311017
Okay, run that script manually, then look at the log.

/var/log/messages and /var/log/mail should be the places to look.

Can you see anything unusual?
0
 

Author Closing Comment

by:mshaikh22
ID: 34548836
Good troubleshooting steps
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Learn to move / copy / export exchange contacts to iPhone without using any software. Also see the issues in configuration of exchange with iPhone to migrate contacts.
Read this checklist to learn more about the 15 things you should never include in an email signature.
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
To show how to generate a certificate request in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.:  First we need to log into the Exchange Admin Center. Navigate to the Servers >> Certificates…

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question