Thanks again to you Rajesh, and Malcom for great troubleshooting tips. Due to separate issue I discovered that I was missing the 127.0.0.1 localhost line from my /etc/hosts ... fixing that also fixed my mail issue!
- Ethan On Jul 14, 4:15 pm, Rajesh Dhawan <[EMAIL PROTECTED]> wrote: > On Jul 14, 7:02 pm, EAMiller <[EMAIL PROTECTED]> wrote: > > > > > On Jul 14, 11:57 am, Rajesh Dhawan <[EMAIL PROTECTED]> wrote: > > > > Drop into a shell (python manage.py shell) and send yourself a test > > > message using: > > > > from django.core.mail import send_mail > > > > send_mail('Subject test', 'Message test', '[EMAIL PROTECTED]', > > > ['your_email_address_here'], fail_silently=False) > > > > With fail_silently=False, you will receive some kind of an error > > > message if that email send is unsuccessful. Use that to investigate > > > further. > > > Thanks Rajesh, good suggestion. > > > Now I (sortof) know my problem... > > > File "smtplib.py", line 296, in connect > > for res in socket.getaddrinfo(host, port, 0, socket.SOCK_STREAM): > > gaierror: (-2, 'Name or service not known') > > This looks like some kind of a name server lookup failure. > > > > > Not sure what this really means. Doesn't the fact that I can use > > 'mail' to send mail from the CLI mean my postfix setup is basically > > OK? I will keep working on it. > > Yes, that would mean that your Postfix setup is OK. Try setting > EMAIL_HOST to '127.0.0.1' to see if that helps. > > Otherwise, try this in a Python shell: > > import socket > host = socket.gethostname() > print host > ip = socket.gethostbyname(host) > print ip > > If that ip= line fails, it means your server's hostname doesn't > resolve to an IP address. Just add a 127.0.0.1 entry for it in your / > etc/hosts and that should take care of it. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---