Unable to start ERPNext

Hi Folks,

I downloaded the application and tested it on a test machine for a couple of days, it looks good and I wanted to give it a go for using in our retail operation. Here is what I did:

1. Installed Ubuntu 14.04 LTS 64 bit on a virtualbox guest.
2. Followed the instructions at https://github.com/frappe/erpnext/wiki/How-to-Install-ERPNext to install ERP Next, which went without any errors.
3. Executed the instructions at https://github.com/frappe/erpnext/wiki/WSGI-Production-Deployment to get the application to launch as a service on the production box. Again, there were no errors.

After step 3 was completed, I am able to see the generic NGINX html page when I go to http://serverIP which does not redirect the traffic to the ERPNext application. I did change the /path/to/ERPNext path in step 3 (both supervisor and nginx scripts) to make sure that wouldn't create a problem, rebuilt the python script as described at the end of 3 and yet again the ERPNext application is not running.

I am sure it is something trivial as I have been able to get ERPNext to run in the testing mode before. Please let me know what would the issue and any known fixes if you have.

Thanks,

Sultan



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-forum+un…@googlegroups.com.

    To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/f6968e85-c7bd-4609-9010-11f0bef32bbc%40googlegroups.com.

    For more options, visit https://groups.google.com/d/optout.

On Mon, Apr 28, 2014 at 11:12 PM, Sultan Ghaznawi
su...@gmail.com wrote:

Hi Folks,

I downloaded the application and tested it on a test machine for a couple of
days, it looks good and I wanted to give it a go for using in our retail
operation. Here is what I did:

  1. Installed Ubuntu 14.04 LTS 64 bit on a virtualbox guest.
  2. Followed the instructions at
    https://github.com/frappe/erpnext/wiki/How-to-Install-ERPNext to install ERP
    Next, which went without any errors.
  3. Executed the instructions at
    https://github.com/frappe/erpnext/wiki/WSGI-Production-Deployment to get the
    application to launch as a service on the production box. Again, there were
    no errors.

After step 3 was completed, I am able to see the generic NGINX html page
when I go to http://serverIP which does not redirect the traffic to the
ERPNext application. I did change the /path/to/ERPNext path in step 3 (both
supervisor and nginx scripts) to make sure that wouldn’t create a problem,
rebuilt the python script as described at the end of 3 and yet again the
ERPNext application is not running.

Great! All looks good. If you have replaced nginx.conf by what is in
the example conf, there is no reason for it to show the default page.
Did you reload nginx after making the changes? Also reload supervisor
if you see something like bad gateway.

I am sure it is something trivial as I have been able to get ERPNext to run
in the testing mode before. Please let me know what would the issue and any
known fixes if you have.

Thanks,

Sultan


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-forum+un...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/erpnext-developer-forum/f6968e85-c7bd-4609-9010-11f0bef32bbc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Pratik
erpnext

Hi Pratik,

Thanks for your response. I tried so many things and nothing worked, infact I broke a few things. I installed a fresh VM with exact configuration as outlined above. This time, however, I replaced all the contents of the nginx.conf (as opposed to parts of it earlier) with the example for nginx.conf that you have provided on the 3 above. I made sure that the "/path/to/erpnext" is replace with the path to the wnf.py file which is "/home/erpnext/erpnext/lib/wnf.py" in both the supervisor and the nginx configuration files.


Again, the installation went will until the very end.

Running
sudo supervisorctl restart gunicorn

says "gunicorn: ERROR (not running)" and "gunicorn: ERROR (abnormal termination)".

Since everything is the same, I am assuming that the path to erpnext is incorrect. Can you please elaborate on this?

Thanks,

Sultan


On Mon, Apr 28, 2014 at 1:54 PM, Pratik Vyas <pd...@gmail.com> wrote:
On Mon, Apr 28, 2014 at 11:12 PM, Sultan Ghaznawi
<su...@gmail.com> wrote:
> Hi Folks,
>
> I downloaded the application and tested it on a test machine for a couple of
> days, it looks good and I wanted to give it a go for using in our retail
> operation. Here is what I did:
>
> 1. Installed Ubuntu 14.04 LTS 64 bit on a virtualbox guest.
> 2. Followed the instructions at
> https://github.com/frappe/erpnext/wiki/How-to-Install-ERPNext to install ERP
> Next, which went without any errors.
> 3. Executed the instructions at
> https://github.com/frappe/erpnext/wiki/WSGI-Production-Deployment to get the
> application to launch as a service on the production box. Again, there were
> no errors.
>
> After step 3 was completed, I am able to see the generic NGINX html page
> when I go to http://serverIP which does not redirect the traffic to the
> ERPNext application. I did change the /path/to/ERPNext path in step 3 (both
> supervisor and nginx scripts) to make sure that wouldn't create a problem,
> rebuilt the python script as described at the end of 3 and yet again the
> ERPNext application is not running.

Great! All looks good. If you have replaced nginx.conf by what is in
the example conf, there is no reason for it to show the default page.
Did you reload nginx after making the changes? Also reload supervisor
if you see something like bad gateway.

>
> I am sure it is something trivial as I have been able to get ERPNext to run
> in the testing mode before. Please let me know what would the issue and any
> known fixes if you have.
>
> Thanks,
>
> Sultan
>
> --
> 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
--
Pratik
erpnext

--
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 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/QIoaDkLd9-U/unsubscribe.

To unsubscribe from this group and all its topics, send an email to erpnext-developer-forum+un…@googlegroups.com.

To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAG8U0E%3Dr%3D%2BtVspk00RFuidKHypEAVCrM3qoqh2j16%3Djfeh6PbA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.



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-forum+un…@googlegroups.com.

    To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAPg4WV-nOipwc944PVBL0cDaAhCpLO1MYwo%3D-mn8S6HvN%2BfsBw%40mail.gmail.com.

    For more options, visit https://groups.google.com/d/optout.

On Tue, Apr 29, 2014 at 5:04 AM, Sultan Ghaznawi
su...@gmail.com wrote:

Hi Pratik,

Thanks for your response. I tried so many things and nothing worked, infact
I broke a few things. I installed a fresh VM with exact configuration as
outlined above. This time, however, I replaced all the contents of the
nginx.conf (as opposed to parts of it earlier) with the example for
nginx.conf that you have provided on the 3 above. I made sure that the
“/path/to/erpnext” is replace with the path to the wnf.py file which is
“/home/erpnext/erpnext/lib/wnf.py” in both the supervisor and the nginx
configuration files.

Again, the installation went will until the very end.

Running

sudo supervisorctl restart gunicorn

says “gunicorn: ERROR (not running)” and “gunicorn: ERROR (abnormal
termination)”.

Since everything is the same, I am assuming that the path to erpnext is
incorrect. Can you please elaborate on this?

Okay, lets see why gunicorn terminated abnormally. Can you see the
logs? By default, I think they are stored in /tmp

Thanks,

Sultan


Pratik
erpnext

Hi Pratik,

Thanks for your response. Actually, I can not find any log files for gunicorn under /tmp or under /var/log directories. I do see the logs for nginx and supervisor under /var/log.

Your help is very much appreciated

Sultan


On Tue, Apr 29, 2014 at 12:28 AM, Pratik Vyas <pd...@gmail.com> wrote:
On Tue, Apr 29, 2014 at 5:04 AM, Sultan Ghaznawi
<su...@gmail.com> wrote:
> Hi Pratik,
>
> Thanks for your response. I tried so many things and nothing worked, infact
> I broke a few things. I installed a fresh VM with exact configuration as
> outlined above. This time, however, I replaced all the contents of the
> nginx.conf (as opposed to parts of it earlier) with the example for
> nginx.conf that you have provided on the 3 above. I made sure that the
> "/path/to/erpnext" is replace with the path to the wnf.py file which is
> "/home/erpnext/erpnext/lib/wnf.py" in both the supervisor and the nginx
> configuration files.
>
>
> Again, the installation went will until the very end.
>
> Running
>
> sudo supervisorctl restart gunicorn
>
> says "gunicorn: ERROR (not running)" and "gunicorn: ERROR (abnormal
> termination)".
>
>
> Since everything is the same, I am assuming that the path to erpnext is
> incorrect. Can you please elaborate on this?
>

Okay, lets see why gunicorn terminated abnormally. Can you see the
logs? By default, I think they are stored in /tmp

> Thanks,
>
> Sultan
>


--
Pratik
erpnext

--
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 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/QIoaDkLd9-U/unsubscribe.

To unsubscribe from this group and all its topics, send an email to erpnext-developer-forum+un…@googlegroups.com.

To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAG8U0EkjNwsEZRa25tcN2Hemq0Dtv5%2BSa-eJw_pLAjhbBhu0NA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.



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-forum+un…@googlegroups.com.

    To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAPg4WV-oEKQFPmUDkSgiVgVdAUvHwx_Z9DqicpcrEwnASw85vg%40mail.gmail.com.

    For more options, visit https://groups.google.com/d/optout.

Hi Sultan,

On Tue, Apr 29, 2014 at 6:47 PM, Sultan Ghaznawi
su...@gmail.com wrote:

Hi Pratik,

Thanks for your response. Actually, I can not find any log files for
gunicorn under /tmp or under /var/log directories. I do see the logs for
nginx and supervisor under /var/log.

You can set stderr_logfile
(http://supervisord.org/configuration.html#program-x-section-settings)

Or run supervisorctl tail gunicorn stderr (could be error instead of
stderr, writing from memory).

Your help is very much appreciated

Sultan

On Tue, Apr 29, 2014 at 12:28 AM, Pratik Vyas pd...@gmail.com wrote:

On Tue, Apr 29, 2014 at 5:04 AM, Sultan Ghaznawi
su...@gmail.com wrote:

Hi Pratik,

Thanks for your response. I tried so many things and nothing worked,
infact
I broke a few things. I installed a fresh VM with exact configuration as
outlined above. This time, however, I replaced all the contents of the
nginx.conf (as opposed to parts of it earlier) with the example for
nginx.conf that you have provided on the 3 above. I made sure that the
“/path/to/erpnext” is replace with the path to the wnf.py file which is
“/home/erpnext/erpnext/lib/wnf.py” in both the supervisor and the nginx
configuration files.

Again, the installation went will until the very end.

Running

sudo supervisorctl restart gunicorn

says “gunicorn: ERROR (not running)” and “gunicorn: ERROR (abnormal
termination)”.

Since everything is the same, I am assuming that the path to erpnext is
incorrect. Can you please elaborate on this?

Okay, lets see why gunicorn terminated abnormally. Can you see the
logs? By default, I think they are stored in /tmp

Thanks,

Sultan


Pratik
erpnext


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 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/QIoaDkLd9-U/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
erpnext-developer-forum+un...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/erpnext-developer-forum/CAG8U0EkjNwsEZRa25tcN2Hemq0Dtv5%2BSa-eJw_pLAjhbBhu0NA%40mail.gmail.com.

For more options, visit https://groups.google.com/d/optout.


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-forum+un...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/erpnext-developer-forum/CAPg4WV-oEKQFPmUDkSgiVgVdAUvHwx_Z9DqicpcrEwnASw85vg%40mail.gmail.com.

For more options, visit https://groups.google.com/d/optout.


Pratik
erpnext

Thanks Pratik, I am a little confused. I opened the supervisord.conf file and following the instructions in the link, I wanted to place the stderr_logfile variable inside it. But I guess I need to specify a program with which this log will be invoked. Any pointers there would be very much appreciated.

I found a couple of error log files that are gunicorn related, in the /var/log/supervisor directory and here are what they say:

gunicorn-stdout---supervisor-TBBZmP.log

supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR

--------

gunicorn-stderr---supervisor-vQN1ZW.log is empty

-----------

supervisord.log:

2014-04-28 19:19:15,013 CRIT Supervisor running as root (no user in config file)
2014-04-28 19:19:15,041 INFO RPC interface 'supervisor' initialized
2014-04-28 19:19:15,041 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2014-04-28 19:19:15,043 INFO daemonizing the supervisord process
2014-04-28 19:19:15,044 INFO supervisord started with pid 12114
2014-04-28 19:20:35,803 CRIT Supervisor running as root (no user in config file)
2014-04-28 19:20:35,803 WARN Included extra file "/etc/supervisor/conf.d/gunicorn.conf" during parsing
2014-04-28 19:20:35,803 INFO RPC interface 'supervisor' initialized
2014-04-28 19:20:35,804 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2014-04-28 19:20:35,804 INFO supervisord started with pid 12114
2014-04-28 19:20:36,807 INFO spawned: 'gunicorn' with pid 12134
2014-04-28 19:20:36,817 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:20:37,820 INFO spawned: 'gunicorn' with pid 12135
2014-04-28 19:20:37,829 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:20:39,833 INFO spawned: 'gunicorn' with pid 12136
2014-04-28 19:20:39,839 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:20:42,845 INFO spawned: 'gunicorn' with pid 12137
2014-04-28 19:20:42,851 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:20:43,852 INFO gave up: gunicorn entered FATAL state, too many start retries too quickly
2014-04-28 19:28:46,762 INFO spawned: 'gunicorn' with pid 12937
2014-04-28 19:28:46,767 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:28:47,770 INFO spawned: 'gunicorn' with pid 12938
2014-04-28 19:28:47,786 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:28:49,791 INFO spawned: 'gunicorn' with pid 12939
2014-04-28 19:28:49,801 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:28:52,808 INFO spawned: 'gunicorn' with pid 12940
2014-04-28 19:28:52,816 INFO exited: gunicorn (exit status 127; not expected)
2014-04-28 19:28:53,818 INFO gave up: gunicorn entered FATAL state, too many start retries too quickly

--------------

I hope you can help me by getting an idea from the logs. I see the errors but your opinion is highly appreciated.

Thanks,

Sultan






On Tue, Apr 29, 2014 at 9:48 AM, Pratik Vyas <pd...@gmail.com> wrote:
Hi Sultan,

On Tue, Apr 29, 2014 at 6:47 PM, Sultan Ghaznawi
<su...@gmail.com> wrote:
> Hi Pratik,
>
> Thanks for your response. Actually, I can not find any log files for
> gunicorn under /tmp or under /var/log directories. I do see the logs for
> nginx and supervisor under /var/log.
>

You can set stderr_logfile
(http://supervisord.org/configuration.html#program-x-section-settings)

Or run `supervisorctl tail gunicorn stderr` (could be error instead of
stderr, writing from memory).


> Your help is very much appreciated
>
> Sultan
>
>
> On Tue, Apr 29, 2014 at 12:28 AM, Pratik Vyas <pd...@gmail.com> wrote:
>>
>> On Tue, Apr 29, 2014 at 5:04 AM, Sultan Ghaznawi
>> <su...@gmail.com> wrote:
>> > Hi Pratik,
>> >
>> > Thanks for your response. I tried so many things and nothing worked,
>> > infact
>> > I broke a few things. I installed a fresh VM with exact configuration as
>> > outlined above. This time, however, I replaced all the contents of the
>> > nginx.conf (as opposed to parts of it earlier) with the example for
>> > nginx.conf that you have provided on the 3 above. I made sure that the
>> > "/path/to/erpnext" is replace with the path to the wnf.py file which is
>> > "/home/erpnext/erpnext/lib/wnf.py" in both the supervisor and the nginx
>> > configuration files.
>> >
>> >
>> > Again, the installation went will until the very end.
>> >
>> > Running
>> >
>> > sudo supervisorctl restart gunicorn
>> >
>> > says "gunicorn: ERROR (not running)" and "gunicorn: ERROR (abnormal
>> > termination)".
>> >
>> >
>> > Since everything is the same, I am assuming that the path to erpnext is
>> > incorrect. Can you please elaborate on this?
>> >
>>
>> Okay, lets see why gunicorn terminated abnormally. Can you see the
>> logs? By default, I think they are stored in /tmp
>>
>> > Thanks,
>> >
>> > Sultan
>> >
>>
>>
>> --
>> Pratik
>> erpnext
>>
>> --
>> 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 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/QIoaDkLd9-U/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> erpnext-developer-forum+un...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/erpnext-developer-forum/CAG8U0EkjNwsEZRa25tcN2Hemq0Dtv5%2BSa-eJw_pLAjhbBhu0NA%40mail.gmail.com.

>>

>> For more options, visit https://groups.google.com/d/optout.

>

>

> –

> 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-forum+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/erpnext-developer-forum/CAPg4WV-oEKQFPmUDkSgiVgVdAUvHwx_Z9DqicpcrEwnASw85vg%40mail.gmail.com.
>
> For more options, visit https://groups.google.com/d/optout.



--
Pratik
erpnext

--
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 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/QIoaDkLd9-U/unsubscribe.

To unsubscribe from this group and all its topics, send an email to erpnext-developer-forum+un…@googlegroups.com.

To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAG8U0Ekmz5_voVSCayHZ5EfOc7KxB8Bc1KTFAenSZne8Gp11mw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.



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-forum+un…@googlegroups.com.

    To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAPg4WV81Oy9fFSuTzU7Z1k3KKtr%2BjjN63%3DzGVmWD_6yBaSdhow%40mail.gmail.com.

    For more options, visit https://groups.google.com/d/optout.

Hi Sultan,

On Tue, Apr 29, 2014 at 7:58 PM, Sultan Ghaznawi
su...@gmail.com wrote:

Thanks Pratik, I am a little confused. I opened the supervisord.conf file
and following the instructions in the link, I wanted to place the
stderr_logfile variable inside it. But I guess I need to specify a program
with which this log will be invoked. Any pointers there would be very much
appreciated.

I found a couple of error log files that are gunicorn related, in the
/var/log/supervisor directory and here are what they say:

gunicorn-stdout—supervisor-TBBZmP.log

supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
supervisor: child process was not spawned
supervisor: couldn’t chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR


gunicorn-stderr—supervisor-vQN1ZW.log is empty


supervisord.log:

2014-04-28 19:19:15,013 CRIT Supervisor running as root (no user in config
file)
2014-04-28 19:19:15,041 INFO RPC interface ‘supervisor’ initialized
2014-04-28 19:19:15,041 CRIT Server ‘unix_http_server’ running without any
HTTP authentication checking
2014-04-28 19:19:15,043 INFO daemonizing the supervisord process
2014-04-28 19:19:15,044 INFO supervisord started with pid 12114
2014-04-28 19:20:35,803 CRIT Supervisor running as root (no user in config
file)
2014-04-28 19:20:35,803 WARN Included extra file
“/etc/supervisor/conf.d/gunicorn.conf” during parsing
2014-04-28 19:20:35,803 INFO RPC interface ‘supervisor’ initialized
2014-04-28 19:20:35,804 CRIT Server ‘unix_http_server’ running without any
HTTP authentication checking
2014-04-28 19:20:35,804 INFO supervisord started with pid 12114
2014-04-28 19:20:36,807 INFO spawned: ‘gunicorn’ with pid 12134
2014-04-28 19:20:36,817 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:20:37,820 INFO spawned: ‘gunicorn’ with pid 12135
2014-04-28 19:20:37,829 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:20:39,833 INFO spawned: ‘gunicorn’ with pid 12136
2014-04-28 19:20:39,839 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:20:42,845 INFO spawned: ‘gunicorn’ with pid 12137
2014-04-28 19:20:42,851 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:20:43,852 INFO gave up: gunicorn entered FATAL state, too many
start retries too quickly
2014-04-28 19:28:46,762 INFO spawned: ‘gunicorn’ with pid 12937
2014-04-28 19:28:46,767 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:28:47,770 INFO spawned: ‘gunicorn’ with pid 12938
2014-04-28 19:28:47,786 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:28:49,791 INFO spawned: ‘gunicorn’ with pid 12939
2014-04-28 19:28:49,801 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:28:52,808 INFO spawned: ‘gunicorn’ with pid 12940
2014-04-28 19:28:52,816 INFO exited: gunicorn (exit status 127; not
expected)
2014-04-28 19:28:53,818 INFO gave up: gunicorn entered FATAL state, too many
start retries too quickly


I hope you can help me by getting an idea from the logs. I see the errors
but your opinion is highly appreciated.

Thanks,

Sultan

Good Job with the logs! It seems that your directory variable is set
to the path of wnf.py and not the erpnext dir. From the logs, I
deduce, it should be ‘/home/erpnext/erpnext/’

Thanks,
Pratik

ERPNext

Hi Pratik,

Thank you so much for all your help. That fixed the issue with gunicorn and I don't see those errors anymore. However, when I go to the http://xxx.xxx.x.xxx which is the IP address of the box (on port 80), I get the generic nginx index page. I have reloaded both supervisor and restarted nginx and gunicorn. I also ran the build command at the bottom of the WSGI deployment page.

Any ideas?

Sultan


On Tue, Apr 29, 2014 at 12:09 PM, Pratik Vyas <pd...@gmail.com> wrote:
Hi Sultan,

On Tue, Apr 29, 2014 at 7:58 PM, Sultan Ghaznawi
<su...@gmail.com> wrote:
> Thanks Pratik, I am a little confused. I opened the supervisord.conf file
> and following the instructions in the link, I wanted to place the
> stderr_logfile variable inside it. But I guess I need to specify a program
> with which this log will be invoked. Any pointers there would be very much
> appreciated.
>
> I found a couple of error log files that are gunicorn related, in the
> /var/log/supervisor directory and here are what they say:
>
> gunicorn-stdout---supervisor-TBBZmP.log
>
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
> supervisor: child process was not spawned
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
> supervisor: child process was not spawned
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
> supervisor: child process was not spawned
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
> supervisor: child process was not spawned
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
> supervisor: child process was not spawned
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
> supervisor: child process was not spawned
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
> supervisor: child process was not spawned
> supervisor: couldn't chdir to /home/erpnext/erpnext/lib/wnf.py: ENOTDIR
>
> --------
>
> gunicorn-stderr---supervisor-vQN1ZW.log is empty
>
> -----------
>
> supervisord.log:
>
> 2014-04-28 19:19:15,013 CRIT Supervisor running as root (no user in config
> file)
> 2014-04-28 19:19:15,041 INFO RPC interface 'supervisor' initialized
> 2014-04-28 19:19:15,041 CRIT Server 'unix_http_server' running without any
> HTTP authentication checking
> 2014-04-28 19:19:15,043 INFO daemonizing the supervisord process
> 2014-04-28 19:19:15,044 INFO supervisord started with pid 12114
> 2014-04-28 19:20:35,803 CRIT Supervisor running as root (no user in config
> file)
> 2014-04-28 19:20:35,803 WARN Included extra file
> "/etc/supervisor/conf.d/gunicorn.conf" during parsing
> 2014-04-28 19:20:35,803 INFO RPC interface 'supervisor' initialized
> 2014-04-28 19:20:35,804 CRIT Server 'unix_http_server' running without any
> HTTP authentication checking
> 2014-04-28 19:20:35,804 INFO supervisord started with pid 12114
> 2014-04-28 19:20:36,807 INFO spawned: 'gunicorn' with pid 12134
> 2014-04-28 19:20:36,817 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:20:37,820 INFO spawned: 'gunicorn' with pid 12135
> 2014-04-28 19:20:37,829 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:20:39,833 INFO spawned: 'gunicorn' with pid 12136
> 2014-04-28 19:20:39,839 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:20:42,845 INFO spawned: 'gunicorn' with pid 12137
> 2014-04-28 19:20:42,851 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:20:43,852 INFO gave up: gunicorn entered FATAL state, too many
> start retries too quickly
> 2014-04-28 19:28:46,762 INFO spawned: 'gunicorn' with pid 12937
> 2014-04-28 19:28:46,767 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:28:47,770 INFO spawned: 'gunicorn' with pid 12938
> 2014-04-28 19:28:47,786 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:28:49,791 INFO spawned: 'gunicorn' with pid 12939
> 2014-04-28 19:28:49,801 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:28:52,808 INFO spawned: 'gunicorn' with pid 12940
> 2014-04-28 19:28:52,816 INFO exited: gunicorn (exit status 127; not
> expected)
> 2014-04-28 19:28:53,818 INFO gave up: gunicorn entered FATAL state, too many
> start retries too quickly
>
> --------------
>
> I hope you can help me by getting an idea from the logs. I see the errors
> but your opinion is highly appreciated.
>
> Thanks,
>
> Sultan
>
>
Good Job with the logs! It seems that your directory variable is set
to the path of wnf.py and not the erpnext dir. From the logs, I
deduce, it should be '/home/erpnext/erpnext/'


Thanks,
Pratik
--
ERPNext

--
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 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/QIoaDkLd9-U/unsubscribe.

To unsubscribe from this group and all its topics, send an email to erpnext-developer-forum+un…@googlegroups.com.

To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAG8U0E%3D6Wt9EWjo3zk3quLsL%3DEABi7XeCbY4%3DGFJbHU2%3DezttQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.



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-forum+un…@googlegroups.com.

    To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/CAPg4WV-Urjk_Whcy%3DtQkkAf%2BAuHGUt%2B09iU3Vxsyp0dt5scujg%40mail.gmail.com.

    For more options, visit https://groups.google.com/d/optout.