LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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


Reply
  Search this Thread
Old 08-04-2010, 02:31 AM   #121
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,631

Rep: Reputation: Disabled

Is this the nameserver from your ISP? If it is, it is not able to resolve the domains. Instead of this, use the global 4.2.2.2 DNS and see if you can resolve.
 
Old 08-04-2010, 02:33 AM   #122
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Quote:
Originally Posted by Xanios View Post
Hi,

i typed

Code:
sudo vi /etc/resolv.conf
and this is the output i got:

Code:
# Generated by NetworkManager
domain localdomain
search localdomain
nameserver 192.168.142.2
Hi,

Those values need to change. Set search to google.com and nameserver to 8.8.8.8 (Google's own DNS) or the one linuxlover.chaitanya indicated. I assume you don't have your own DNS server set up or do you? The 142.2 address is that your router?

Kind regards,

Eric
 
Old 08-04-2010, 02:44 AM   #123
Xanios
Member
 
Registered: Jul 2010
Posts: 216

Original Poster
Rep: Reputation: 30
Hi,

I changed already but i still get:

Code:
Aug  4 00:48:02 ubuntu postfix/smtp[28853]: 45C0340CCE: to=<xanios@server.com>, relay=none, delay=20, delays=0.01/0/20/0, dsn=4.3.5, status=deferred (unable to look up host smtp.gmail.com: No address associated with hostname)
Ya i don't have own DNS setup. That address is the address of another windows server.
 
Old 08-04-2010, 03:21 AM   #124
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Hi,

Can you open a terminal, run the following and post the output:
Code:
ifconfig
Kind regards,

Eric
 
Old 08-04-2010, 03:23 AM   #125
Xanios
Member
 
Registered: Jul 2010
Posts: 216

Original Poster
Rep: Reputation: 30
Hi,

Code:
xanios@ubuntu:~$ ifconfig
eth0      Link encap:Ethernet  HWaddr 00:0c:29:4b:73:24  
          inet addr:192.168.142.155  Bcast:192.168.142.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe4b:7324/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:27 errors:0 dropped:0 overruns:0 frame:0
          TX packets:49 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:4451 (4.4 KB)  TX bytes:6921 (6.9 KB)
          Interrupt:19 Base address:0x2000 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:51 errors:0 dropped:0 overruns:0 frame:0
          TX packets:51 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:3796 (3.7 KB)  TX bytes:3796 (3.7 KB)
i tried to ping to google.com now and it works:

Code:
xanios@ubuntu:~$ ping google.com
PING google.com (72.14.254.104) 56(84) bytes of data.
64 bytes from 72.14.254.104: icmp_seq=1 ttl=128 time=3.37 ms
64 bytes from 72.14.254.104: icmp_seq=2 ttl=128 time=3.18 ms
64 bytes from 72.14.254.104: icmp_seq=3 ttl=128 time=10.0 ms
^C64 bytes from 72.14.254.104: icmp_seq=4 ttl=128 time=18.8 ms

--- google.com ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 15063ms
rtt min/avg/max/mdev = 3.188/8.877/18.894/6.410 ms

Last edited by Xanios; 08-04-2010 at 03:25 AM.
 
Old 08-04-2010, 03:28 AM   #126
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Hi,

Can you try the nslookup command and post the output, send a mail and check the log and post the last 20 lines?

Kind regards,

Eric
 
Old 08-04-2010, 03:31 AM   #127
Xanios
Member
 
Registered: Jul 2010
Posts: 216

Original Poster
Rep: Reputation: 30
Hi,

this is the output:

Code:
xanios@ubuntu:~$ nslookup smtp.gmail.com
Server:		192.168.142.2
Address:	192.168.142.2#53

Non-authoritative answer:
smtp.gmail.com	canonical name = gmail-smtp-msa.l.google.com.
Name:	gmail-smtp-msa.l.google.com
Address: 72.14.213.109
log mail:

Code:
xanios@ubuntu:~$ mail -s "test mail" -v xanios@gmail.com321
Cc: 
Mail Delivery Status Report will be mailed to <xanios>.
xanios@ubuntu:~$ tail -n 20 /var/log/mail.log
Aug  4 01:33:41 ubuntu postfix/error[2713]: 4217D40CAF: to=<xanios@gmail.com>, relay=none, delay=4718, delays=4718/0.05/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 2E34240CA9: from=<nagios@server.com>, size=552, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2716]: 4B07340CE4: to=<xanios@gmail.com>, relay=none, delay=2280, delays=2280/0.02/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 271D540CB6: from=<nagios@server.com>, size=573, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 37B2440CD9: from=<nagios@server.com>, size=520, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2715]: 221C740CD7: to=<layleng91@gmail.com>, relay=none, delay=2291, delays=2290/0.02/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 3A0B640CAB: from=<nagios@server.com>, size=550, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2713]: 2E34240CA9: to=<xanios@gmail.com>, relay=none, delay=4718, delays=4718/0.02/0/0, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 3F30240CDD: from=<nagios@server.com>, size=540, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2718]: 271D540CB6: to=<xanios@gmail.com>, relay=none, delay=4668, delays=4668/0.01/0/0, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 1C8AE40CB2: from=<nagios@server.com>, size=585, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2716]: 37B2440CD9: to=<layleng91@gmail.com>, relay=none, delay=2290, delays=2290/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/error[2719]: 3A0B640CAB: to=<layleng91@gmail.com>, relay=none, delay=4718, delays=4718/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/error[2713]: 3F30240CDD: to=<xanios@gmail.com>, relay=none, delay=2290, delays=2290/0/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 1939040CD3: from=<nagios@server.com>, size=552, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2718]: 1939040CD3: to=<xanios@gmail.com>, relay=none, delay=2291, delays=2291/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/error[2715]: 1C8AE40CB2: to=<xanios@gmail.com>, relay=none, delay=4669, delays=4669/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:36:43 ubuntu postfix/pickup[2381]: 199D241463: uid=1000 from=<layleng>
Aug  4 01:36:43 ubuntu postfix/cleanup[2757]: 199D241463: message-id=<20100804083643.199D241463@ubuntu>
Aug  4 01:36:43 ubuntu postfix/qmgr[2382]: 199D241463: from=<xanios@server.com>, size=285, nrcpt=1 (queue active)
It takes a while to process and see the status whether it's deferred or not =/:

Code:
xanios@ubuntu:~$ tail -n 20 /var/log/mail.log
Aug  4 01:33:41 ubuntu postfix/error[2713]: 2E34240CA9: to=<xanios@gmail.com>, relay=none, delay=4718, delays=4718/0.02/0/0, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 3F30240CDD: from=<nagios@server.com>, size=540, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2718]: 271D540CB6: to=<xanios@gmail.com>, relay=none, delay=4668, delays=4668/0.01/0/0, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 1C8AE40CB2: from=<nagios@server.com>, size=585, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2716]: 37B2440CD9: to=<xanios@gmail.com>, relay=none, delay=2290, delays=2290/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/error[2719]: 3A0B640CAB: to=<xanios@gmail.com>, relay=none, delay=4718, delays=4718/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/error[2713]: 3F30240CDD: to=<xanios@gmail.com>, relay=none, delay=2290, delays=2290/0/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/qmgr[2382]: 1939040CD3: from=<nagios@server.com>, size=552, nrcpt=1 (queue active)
Aug  4 01:33:41 ubuntu postfix/error[2718]: 1939040CD3: to=<xanios@gmail.com>, relay=none, delay=2291, delays=2291/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:33:41 ubuntu postfix/error[2715]: 1C8AE40CB2: to=<xanios@gmail.com>, relay=none, delay=4669, delays=4669/0.01/0/0.01, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to smtp.gmail.com[72.14.213.109]:25: Connection refused)
Aug  4 01:36:43 ubuntu postfix/pickup[2381]: 199D241463: uid=1000 from=<layleng>
Aug  4 01:36:43 ubuntu postfix/cleanup[2757]: 199D241463: message-id=<20100804083643.199D241463@ubuntu>
Aug  4 01:36:43 ubuntu postfix/qmgr[2382]: 199D241463: from=<xanios@server.com>, size=285, nrcpt=1 (queue active)
Aug  4 01:37:04 ubuntu postfix/smtp[2759]: connect to smtp.gmail.com[74.125.127.109]:25: Connection refused
Aug  4 01:37:04 ubuntu postfix/smtp[2759]: 199D241463: to=<xanios@gmail.com>, relay=none, delay=21, delays=0.07/0.01/21/0, dsn=4.4.1, status=deferred (connect to smtp.gmail.com[74.125.127.109]:25: Connection refused)
Aug  4 01:37:04 ubuntu postfix/cleanup[2757]: 21C1B41465: message-id=<20100804083704.21C1B41465@ubuntu>
Aug  4 01:37:04 ubuntu postfix/bounce[2764]: 199D241463: sender delivery status notification: 21C1B41465
Aug  4 01:37:04 ubuntu postfix/qmgr[2382]: 21C1B41465: from=<>, size=1748, nrcpt=1 (queue active)
Aug  4 01:37:25 ubuntu postfix/smtp[2759]: connect to smtp.gmail.com[74.125.127.109]:25: Connection refused
Aug  4 01:37:25 ubuntu postfix/smtp[2759]: 21C1B41465: to=<xanios@server.com>, relay=none, delay=21, delays=0.01/0/21/0, dsn=4.4.1, status=deferred (connect to smtp.gmail.com[74.125.127.109]:25: Connection refused)

Last edited by Xanios; 08-04-2010 at 03:38 AM.
 
Old 08-04-2010, 03:40 AM   #128
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,631

Rep: Reputation: Disabled
It is still refusing connections. Did you do the changes I gave you? Use canonical name for smtp.gmail.com instead and then see.
 
Old 08-04-2010, 03:44 AM   #129
Xanios
Member
 
Registered: Jul 2010
Posts: 216

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by linuxlover.chaitanya View Post
It is still refusing connections. Did you do the changes I gave you? Use canonical name for smtp.gmail.com instead and then see.
Hi,

change that in main.cf for relayhost to relayhost=gmail-smtp-msa.l.google.com you mean?(:
 
Old 08-04-2010, 03:46 AM   #130
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,631

Rep: Reputation: Disabled
Yes and then use your user and password for your gmail account and put that in sasl_password file. Make sure you use smtp.gmail.com in sasl_password file and set smtp_cname_overrides_servername=no as well. You also need to enable tls authentication for gmail. Have noanonymous, noplaintext as security options.
 
Old 08-04-2010, 03:49 AM   #131
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Hi,

Don't forget to follow the correct way as indicated by Postfix on their site.
Code:
relayhost (default: empty)
The next-hop destination of non-local mail; overrides non-local domains in recipient addresses. This information is overruled with relay_transport, sender_dependent_default_transport_maps, default_transport, sender_dependent_relayhost_maps and with the transport(5) table.

On an intranet, specify the organizational domain name. If your internal DNS uses no MX records, specify the name of the intranet gateway host instead.

In the case of SMTP, specify a domain name, hostname, hostname:port, [hostname]:port, [hostaddress] or [hostaddress]:port. The form [hostname] turns off MX lookups.

If you're connected via UUCP, see the UUCP_README file for useful information.

Examples:

relayhost = $mydomain
relayhost = [gateway.example.com]
relayhost = uucphost
relayhost = [an.ip.add.ress]
In short, put the domain name between [ ] as mentioned before.

Kind regards,

Eric
 
Old 08-04-2010, 03:57 AM   #132
Xanios
Member
 
Registered: Jul 2010
Posts: 216

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by linuxlover.chaitanya View Post
Yes and then use your user and password for your gmail account and put that in sasl_password file. Make sure you use smtp.gmail.com in sasl_password file and set smtp_cname_overrides_servername=no as well. You also need to enable tls authentication for gmail. Have noanonymous, noplaintext as security options.
Sorry, a bit confusing.
Hmm, in sasl_passwd file, i had this:

Code:
[smtp.gmail.com]:587             xanios@gmail.com:p@55w0rd
So the email (xanios@gmail.com) and password 'p@55w0rd' must be the real gmail which i want to use right. the password cannot be a random one which i typed in in here but does not exist for my gmail?

this smtp_cname_overrides_servername=no is put in main.cf?

and regarding authenticating tls for gmail, is it this line:

Code:
smtpd_use_tls = yes

Last edited by Xanios; 08-04-2010 at 04:16 AM.
 
Old 08-04-2010, 04:01 AM   #133
Xanios
Member
 
Registered: Jul 2010
Posts: 216

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by EricTRA View Post
Hi,

Don't forget to follow the correct way as indicated by Postfix on their site.
Code:
relayhost (default: empty)
The next-hop destination of non-local mail; overrides non-local domains in recipient addresses. This information is overruled with relay_transport, sender_dependent_default_transport_maps, default_transport, sender_dependent_relayhost_maps and with the transport(5) table.

On an intranet, specify the organizational domain name. If your internal DNS uses no MX records, specify the name of the intranet gateway host instead.

In the case of SMTP, specify a domain name, hostname, hostname:port, [hostname]:port, [hostaddress] or [hostaddress]:port. The form [hostname] turns off MX lookups.

If you're connected via UUCP, see the UUCP_README file for useful information.

Examples:

relayhost = $mydomain
relayhost = [gateway.example.com]
relayhost = uucphost
relayhost = [an.ip.add.ress]
In short, put the domain name between [ ] as mentioned before.

Kind regards,

Eric
Hi,

So, i have to put all these in main.cf

Code:
relayhost = $mydomain
relayhost = [mydomainname.com]
relayhost = uucphost
relayhost = [127.0.0.1]< my ubuntu server ip address?
Sorry i just want to confirm (:
 
Old 08-04-2010, 04:54 AM   #134
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,631

Rep: Reputation: Disabled
No. Not all. You may want to use relayhost=gmail-smtp-msa.l.google.com
 
Old 08-04-2010, 04:55 AM   #135
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,631

Rep: Reputation: Disabled
Take the reference from this wiki. This is for Zimbra but most of it will apply to you too as Zimbra suite has postfix as SMTP server.
http://wiki.zimbra.com/wiki/Outgoing...Authentication
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Migration Assistant In Ubuntu 9.04 LXer Syndicated Linux News 0 01-08-2009 01:40 PM
not throws evolution setup assistant dissident_goodchild Linux - Software 0 11-16-2007 09:00 PM
Evolution pppoe setup in Ubuntu won't work with dsl Thane Ubuntu 1 08-16-2006 01:11 PM
evolution mail setup hariiyer Linux - Networking 1 03-03-2006 07:41 AM
Evolution - problems after first setup jburford Linux - Software 2 09-08-2002 04:14 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:22 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration