[ubuntu-uk] Setting up a mailing system
Matthew Macdonald-Wallace
matthew at truthisfreedom.org.uk
Thu Jul 8 12:42:51 BST 2010
Quoting ian pettitt <ian.pettitt at bbsrc.ac.uk>:
> On 08/07/10 12:02, Daniel Case wrote:
>> Hi Guys,
>>
>> I have a VPS running Ubuntu 10.04 on which i need to set up a mailing
>> system, so it can send and recieve emails through PHP, however i am
>> having a little rpoblem with the way Google is telling me to do it...one
>> tutorial is from Ubuntu 8.04 and will not work...
>>
>> So if there is anyone experienced in this field, would they mind giving
>> me a hand?
>>
>> Dan
>
> I forward email from my server to my ISP smtp account to send emails
> using PHP. I can't help with receiving emails as I haven't needed to do
> that.
>
> To send emails using PHP, I first install postfix, during the
> installation you have to answer some questions.
>
> type = ‘internet site’; mail name = ‘<your isp smtp server>’
>
> You then need to set up forwarding mail so emails sent using PHP get
> forwarded through to the smtp server
>
> Forward the rootmail to your local account:
>
> * Typ: sudo vi /root/.forward
> * Typ username at localhost (your username and your localhostname!) <enter>
>
> Forward your local mail to the external account
>
> * Typ: vi /home/username/.forward
> * Typ the external email address <enter>
I'd be tempted to do this via /etc/aliases instead:
root: <user>@<host>
What is it that your PHP system does? Does it only need to send, or
does it need to receive as well?
Quite often setting up the mailserver is one of the easiest parts
(<bait>unless you use sendmail or qmail</bait>) and I tend to lean
towards Exim as it gives you far greater scope in my opinion for
future growth, although it's not quiet as "plug and play" as postfix.
The hard bit, in my experience anyway, is getting PHP to play nicely.
The best way to do this is to use PEAR or similar so that you don't
end up trying to debug direct socket connections (!!!??)...
Kind regards,
Matt
--
Matthew Macdonald-Wallace
matthew at truthisfreedom.org.uk
http://www.truthisfreedom.org.uk/
More information about the ubuntu-uk
mailing list