Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm new to linux/postfix, and would like some help with relaying/forwarding mail from a linux standalone server to our corporate mail environment (exchange 2003).
I installed vmware server on a standalone linux server (Centos 5.2), and wrote a shell script to make backups of the virtual machines. The script makes a tar file from a virtual machine, which is transfered to our backup server. The script includes a procedure to send a mail about the result of that file transfer to a corporate mailaddress (exchange).
I made the following change on the linux server:
-stop sendmail from starting automatically
-install postfix and configure it to start at level 2,3,4 and 5
-adjust main.cf from postfix:
mydomain = companyname.org
myhostname = myservername
mynetworks = xx.xx.xx.0/24, 127.0.0.0/8
relayhost = [ipadress exchange server]
-adjust transport file:
add the line: * smtp:ipaddress exchange server
-configure exchange to allow relaying from the linux server
I have been reading several pages about this topic on the web, but sofar the mail is not relayed/forwarded to the corporate mailaddress.
On the other server have you allowed the ip address of that machine to be allowed to forward? normally you have to say I allow machine w.x.y.z to relay email to me.
Yes, in exchange 2003 the linux server is granted the relay right.
Sorry about that I just reread your post and seen that you have that in there. Hmmm... Ok a couple of things to run. First run
Code:
postmap transport
and then restart postfix. Also try to telnet from your postfix box to the mail server and send an email from the command line. Just helps to start taking somethings out of the equation. I remember I had troubles on my debian postfix box and I think this was the same problem. Also forgot to mention did you create a transport file?
Last edited by jstephens84; 02-04-2009 at 08:15 AM.
I ran "postmap transport" and restarted postfix. In my case the transport file was create by the installation of postfix. I already made the following entry in the transport file: * smtp:ipaddress exchange server. I was succesful to send a mail to my own mailacount by using the telnet method.
However, to send a mail by a script still does not work.
I'm new to linux/postfix, and would like some help with relaying/forwarding mail from a linux standalone server to our corporate mail environment (exchange 2003).
While not a newbie myself to Linux or Windows or Exchange 2003, I seem to be having an issue.
I have a CentOS 5.3 server set up as you described in your posting. Mail gets forwarded to the Exchange box like it should with one exception. Mail from one domain apparently gets delivered to the Exchange Server machine ok after being scanned by amavis-new, but when I go to log into a certain mailbox on the Exchange server, the message is not in the inbox folder, nor is there any logging of the connection attempt. It seems that emails from other domains get relayed fine (with the exclusion of spam and virii). If anyone has any experience with this issue and has a possible solution, I would be thankful for any assistance I can get with this.
I remember that i solved my problem, because i accidentally found some emails in the mailbox on linux describing the reason why the message could not be delivered. I my case that were the missing nameservers.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.