POP3 email setting not working

73 views
Skip to first unread message

Ananda Kumar

unread,
Sep 6, 2013, 7:19:30 AM9/6/13
to erpnext-dev...@googlegroups.com
Hi
   I have hosted the ERPNext application on Azure VM Server and opened the ports for POP3S and SMTPS on the firewall and UFW also disabled. I am using my Gmail account for pulling emails using pop and the same has allowed on my gmail settings. 

  But Erpnext not pulling the emails from my Gmail account, Is there any special settings have to configure on the ERPNext and please help me to resolve 

Regards,
Anand

Rushabh Mehta

unread,
Sep 6, 2013, 8:54:31 AM9/6/13
to erpnext-dev...@googlegroups.com
Have you started the cron jobs?


W: https://erpnext.com
T: @rushabh_mehta

--
Note:
 
If you are posting an issue,
1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
 
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Ananda Kumar

unread,
Sep 10, 2013, 2:37:19 AM9/10/13
to erpnext-dev...@googlegroups.com
Hi
   Can you help me how to configure the Cron jobs? is this required python scripts or the regular linux cron jobs, else do we have any configuration settings on the erpnext portal

Regards,
Anand

Anand Doshi

unread,
Sep 10, 2013, 2:42:03 AM9/10/13
to erpnext-dev...@googlegroups.com

Ananda Kumar

unread,
Oct 1, 2013, 1:45:46 AM10/1/13
to erpnext-dev...@googlegroups.com, jagdish
Hi
   I ran the below script to setup cronjobs for pop3 email pulling, but it is not able to setting up cronjobs and also emails are not pulling over. Kindly help me to solve this issue.

def setup_cron(install_path):
erpnext_cron_entries = [
"*/3 * * * * cd %s && python lib/wnf.py --run_scheduler >> /var/log/erpnext-sch.log 2>&1" % install_path,
"0 */6 * * * cd %s && python lib/wnf.py --backup >> /var/log/erpnext-backup.log 2>&1" % install_path
]

for row in erpnext_cron_entries:
try:
existing_cron = exec_in_shell("crontab -l")
if row not in existing_cron:
exec_in_shell('{ crontab -l; echo "%s"; } | crontab' % row)
except:
exec_in_shell('echo "%s" | crontab' % row)


Regards,
Anand


You received this message because you are subscribed to a topic in the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/erpnext-developer-forum/4isx_g-jgXE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to erpnext-developer...@googlegroups.com.

Anand Doshi

unread,
Oct 1, 2013, 7:43:29 AM10/1/13
to erpnext-dev...@googlegroups.com, jagdish
Hi Ananda,

Please post the output of `crontab -l`

-Anand.

Ananda Kumar

unread,
Oct 1, 2013, 7:46:11 AM10/1/13
to erpnext-dev...@googlegroups.com, jagdish
Hi
   Herebelow the crontab result.

*/3 * * * * cd /var/www && python lib/wnf.py --run_scheduler >> /var/log/erpnext                                                                             -sch.log 2>&1
0 */6 * * * cd /var/www && python lib/wnf.py --backup >> /var/log/erpnext-backup                                                                             .log 2>&1

Regards,
Anand

Anand Doshi

unread,
Oct 1, 2013, 7:47:42 AM10/1/13
to erpnext-dev...@googlegroups.com, jagdish
Hi Anand,

Then you should check the scheduler log.

Go to ERPNext > Setup > Scheduler Error Logs and see if there are error logs in it. Check recent error log entry and you will likely be able to find the reason for the problem.

Thanks,
Anand.

Ananda Kumar

unread,
Oct 1, 2013, 8:32:51 AM10/1/13
to erpnext-dev...@googlegroups.com, jagdish
Hi
  please refer below

Traceback (innermost last):
  File "/var/www/lib/webnotes/utils/scheduler.py", line 71, in trigger
    getattr(startup.schedule_handlers, method)()
  File "app/startup/schedule_handlers.py", line 54, in execute_daily
    scheduler.report_errors()
  File "/var/www/lib/webnotes/utils/scheduler.py", line 116, in report_errors
    <p>URL: <a href="%(url)s" target="_blank">%(url)s</a></p><hr>""" % {"url":get_url()}) + "<hr>".join(errors))
  File "/var/www/lib/webnotes/utils/email_lib/__init__.py", line 19, in sendmail_to_system_managers
    get_email(get_system_managers(), None, content, subject).send()
  File "/var/www/lib/webnotes/utils/email_lib/smtp.py", line 225, in send
    raise_exception=webnotes.OutgoingEmailError)
  File "/var/www/lib/webnotes/__init__.py", line 137, in msgprint
    _raise_exception()
  File "/var/www/lib/webnotes/__init__.py", line 121, in _raise_exception
      Please rectify and try again.

Ananda Kumar

unread,
Oct 1, 2013, 8:47:50 AM10/1/13
to erpnext-dev...@googlegroups.com, jagdish
Hi
   I have fixed the issue, it was due to my postfix script cf error. I have fixed them and working fine now. Thanks for your support.

Regards,
Anand
Reply all
Reply to author
Forward
0 new messages