PHP setup in ubuntu server to sendmail using postfix from server to my gmail inbox for notifications

Asked by josheeg

PHP setup in ubuntu server to sendmail using postfix from server to my gmail inbox for notifications.

I am running ubuntu server.

I have LAMP setup as the server install option allowed

I installed mail-server as the install option allowed.

I entered into it mydomain.com that I purchased. Should it be mail.mydomain.com? also when should localhost be the name and when should I use the name I provided for the computer on the network?

I just need to send notifications from my server to my gmail inbox not using gmail to forward I am running it at home with all ports nessisary open.

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
John Wilson (johnwilson) said :
#1

Think we need more info on this.. but

/etc/hostname - should have your domain name inside.

edit this file gedit or vi (vim, nano, etc) whatever you prefer

it can be mail.mydomain.com or server.mydomain.com or whatever you prefer, it doesnt have to be mail, but it you are only using this for mail, then it should be fine.

you should probably reboot after this and then test with the command:

hostname -f

now, if you are using postfix (instead of sendmail) your config file (/etc/postfix/main.cf) will contain an entry 'myhostname' - this should match whatever you put in your hostname file above. the 'mynetworks' entry in main.cf should be 127.0.0.0/8

I hope this helps or at least gives you a start.

Revision history for this message
RichardP (richardp) said :
#2

This seems similar, but might need a different thread.

Have you managed to get postfix email on ubuntu LINUX working via smtp.gmal relay?
I've been stuck for days trying to get postfix setup working (apparently gmail won't authenticate).

Revision history for this message
josheeg (josheeg) said :
#3

I have not been able to get any of that working. I think my joomla shop could send me a email. :) I doubt that helps. That was on my server I used virtuemart. It was a wile ageo I don't remember.

Revision history for this message
RichardP (richardp) said :
#4

Thanks josheeg. Starting new fresh post for the gmail relay question.

Can you help with this problem?

Provide an answer of your own, or ask josheeg for more information if necessary.

To post a message you must log in.