Bug 1296943 - Django quickstart can't bind address
Summary: Django quickstart can't bind address
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Templates
Version: 2.x
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: ---
Assignee: Vu Dinh
QA Contact: XiuJuan Wang
URL:
Whiteboard:
Depends On:
Blocks: 1308722
TreeView+ depends on / blocked
 
Reported: 2016-01-08 14:09 UTC by Joao Goncalves
Modified: 2019-09-12 09:42 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1308722 (view as bug list)
Environment:
Last Closed: 2017-05-31 18:22:11 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Joao Goncalves 2016-01-08 14:09:33 UTC
Description of problem:
The django quickstart found on https://github.com/openshift/django-example does not work both on scaled and non-scaled apps, the logs read:

    Address already in use: make_sock: could not bind to address 127.3.201.1:8080


Version-Release number of selected component:
464680f (https://github.com/openshift/django-example/commit/464680f411b2aadf301d54db62c64e2728589cce)


Additional info:
Currently using https://github.com/jsvgoncalves/django-openshift as an alternative for users who want to click their way through creating a django application.

Comment 1 Vu Dinh 2016-01-08 14:57:29 UTC
Hi,

I would like to ask if you can provide the steps that you have done when this issue occurs as I'm currently unable to reproduce the issue.

I have tried two different ways to deploy Django app:

1. rhc app create test1 python-3.3 --from-code=https://github.com/openshift/django-example.git

2. Follow instruction on django-quickstart github

With both ways, I've been able to create the app just fine without any errors. Also, I would like to ask which log you are referring to as I have checked /var/log/openshift/broker/development.log and didn't see the error message that you mentioned above.

Thanks in advance for the help.

Comment 2 Joao Goncalves 2016-01-08 15:08:19 UTC
Hi, 

I get the issue when trying to create a Django app via the openshift web console (https://openshift.redhat.com/app/console/application_type/quickstart!72), and the logfile is located at /var/lib/openshift/568fc00126/app-root/logs/python.log

I've checked for the installed python version and it appears to default to 2.7.8; didn't check if the same happens with version 3.3.

Comment 3 Corey Daley 2016-01-15 21:05:16 UTC
Can we get an update on this issue? It's something that we have had multiple customers complain about.

Comment 4 Vu Dinh 2016-01-15 22:42:13 UTC
Hi Corey,

I'm still currently (and actively) working on this bug. It's a bit more complicated to trace down the root cause than I originally thought. Hopefully, early next week, I can give you guys a more detailed update.

Comment 8 Vu Dinh 2016-01-18 19:32:08 UTC
Hi,

Just FYI, since the issue is still in process to be resolved, if any customers need to deploy any quickstarts such as django, wordpress and etc, I would recommend them to use rhc command to deploy those apps using 2 steps just as mentioned in https://github.com/openshift/django-example.git in README.

Essentially, customers need to create app with the required cartridges first and do a git push for the repo later. That would be the work-around solution for the time being.

Thanks,
Vu

Comment 9 Vu Dinh 2016-01-22 22:28:51 UTC
Just FYI,

There is a PR currently in review to fix this issue. Hopefully, we can finally resolve it sometime next week.

Vu

Comment 10 Eric Jones 2016-01-29 16:22:02 UTC
Hi,

As it has now been a week since the recent update mentioning a PR, has there been any progress on that?

I will be working to provide the temporary workaround to a customer but there still seems to be a problem.

Thanks

Comment 11 Vu Dinh 2016-01-29 16:27:08 UTC
Hi Eric,

The PR is currently in preview as it solves this issue at hand but causing some failures on Jenkins test so we haven't been able to merge it yet until the issue with Jenkins is fully resolved. We try to avoid merge the PR too quickly and then cause regression issues later on.

On comment #8, I did provide the workaround solution. I wonder if there is a problem with workaround solution?

Vu

Comment 12 Eric Jones 2016-01-29 16:34:24 UTC
Hi Vu,

Thank you for that status update! I am attempting to get a customer to try using the workaround now so I will let you know, but I am not 100% certain he is experiencing the same issue.

Eric

Comment 13 Andy Grimm 2016-01-29 21:01:02 UTC
The PR doesn't seem to be mentioned anywhere above.  It's here:

https://github.com/openshift/origin-server/pull/6351

Comment 14 openshift-github-bot 2016-02-05 16:33:06 UTC
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/ad66e2cba684c832cead4a0ae26bc3864f1935b3
Bug 1296943: Quickstart deployment via git fails to bind address

When quickstart is deployed with rhc --from-code, there is a start process
(from control script) called during post_receive step which starts the gear and
apache processes. However, in the next step, the cartridge is started as well.
As a result, there are two consecutive start processes leading to the second one
fails due to the fact apache (httpd) process is already started and currently
in use.

This commit adds a check of current state of the gear before starting the cartridge.
If the gear is already started, the restart cartridge process is triggered instead.
Otherwise, the start process is striggered as expected. This fix only change the
behavior initial build of cartridge during git deployment and it's operating within
the local gear. Therefore, it doesn't impact any other gears that are running in
the same node.

Bug 1296943
Link <https://bugzilla.redhat.com/show_bug.cgi?id=1296943>

Signed-off-by: Vu Dinh <vdinh>

Comment 15 XiuJuan Wang 2016-02-14 09:05:49 UTC
Can't reproduce this bug in devenv-5770
1. Create scale and non-scale django apps with python-3.3 from webconsole without errors  in app-root/logs/python.log
2.Create scale and non-scale django apps with python-3.3 from cli without  errors in app-root/logs/python.log

Comment 16 Eric Paris 2017-05-31 18:22:11 UTC
We apologize, however, we do not plan to address this report at this time. The majority of our active development is for the v3 version of OpenShift. If you would like for Red Hat to reconsider this decision, please reach out to your support representative. We are very sorry for any inconvenience this may cause.


Note You need to log in before you can comment on or make changes to this bug.