# Cert exited too quickly

**URL:** <https://discuss.openedx.org/t/cert-exited-too-quickly/4700>\
**Category:** Site Operations Help\
**Tags:** how-to, juniper, koa\
**Created:** [April 7, 2021, 10:13am UTC](https://discuss.openedx.org/t/cert-exited-too-quickly/4700 "2021-04-07T10:13:56Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![BanuSoppan](https://avatars.discourse-cdn.com/v4/letter/b/8baadc/32.png) [@BanuSoppan](https://discuss.openedx.org/u/BanuSoppan)\
**Post date:** [April 7, 2021, 10:13am UTC](https://discuss.openedx.org/t/cert-exited-too-quickly/4700/1 "2021-04-07T10:13:56Z")

</div>

After migrating from juniper to koa , I am getting Cert excited too quickly  
supervisor cert error log

/edx/app/certs/certificates/settings.py:149: YAMLLoadWarning: calling yaml.load() without Loader=… is deprecated, as the default Loader is unsafe. Please read [https://msg.pyyaml.org/load](https://msg.pyyaml.org/load) for full details.  
CERT\_DATA = yaml.load(f.read())  
PdfReadWarning: Xref table not zero-indexed. ID numbers for objects will be corrected. [pdf.py:1736]  
Traceback (most recent call last):  
File “/edx/app/certs/certificates/certificate\_agent.py”, line 184, in   
main()  
File “/edx/app/certs/certificates/certificate\_agent.py”, line 52, in main  
manager = XQueuePullManager(settings.QUEUE\_URL, settings.QUEUE\_NAME,  
File “/edx/app/certs/certificates/openedx\_certificates/queue\_xqueue.py”, line 28, in **init**  
self.\_login()  
File “/edx/app/certs/certificates/openedx\_certificates/queue\_xqueue.py”, line 43, in \_login  
raise Exception(“Invalid return code in reply resp:{0}”.format(  
Exception: Invalid return code in reply resp:{‘return\_code’: 1, ‘content’: ‘Incorrect login credentials’}

---

<div class="post-metadata">

**Author:** ![pkulkark](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/pkulkark/32/3623_2.png) [@pkulkark](https://discuss.openedx.org/u/pkulkark)\
**Post date:** [April 19, 2021, 8:31am UTC](https://discuss.openedx.org/t/cert-exited-too-quickly/4700/2 "2021-04-19T08:31:10Z")

</div>

As the error message indicates, there seems to be something wrong with the credentials being used to login to the xqueue server. Please check the values of `QUEUE_AUTH_USER` and `QUEUE_AUTH_PASS` environment variables.

---

<div class="post-metadata">

**Author:** ![mahyard](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/mahyard/32/54_2.png) [@mahyard](https://discuss.openedx.org/u/mahyard)\
**Post date:** [May 20, 2021, 4:03pm UTC](https://discuss.openedx.org/t/cert-exited-too-quickly/4700/3 "2021-05-20T16:03:36Z")

</div>

Hey @pkulkark,  
I have the same issue with an instance of Juniper release itself.  
Could you tell me how to check QUEUE\_AUTH\_USER?  
I changed my user to certs, though there is no service\_env file under its home directory like other services, and that variable didn’t have a value initialed.  
Thanks in advance

---

<div class="post-metadata">

**Author:** ![mahyard](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/mahyard/32/54_2.png) [@mahyard](https://discuss.openedx.org/u/mahyard)\
**Post date:** [May 20, 2021, 5:10pm UTC](https://discuss.openedx.org/t/cert-exited-too-quickly/4700/4 "2021-05-20T17:10:17Z")

</div>

I found that QUEUE\_AUTH\_PASS, QUEUE\_AUTH\_USER, QUEUE\_USER, QUEUE\_PASS have all been set within ~certs/auth.json.  
Is that enough?  
for more clarification, I can see the following error in /edx/var/log/supervisor/xqueue-stderr.log regularly:

```auto
2021-05-20 13:00:55 [11221] [INFO] POST /xqueue/login/
2021-05-20 13:00:58 [11238] [INFO] POST /xqueue/login/
2021-05-20 13:01:00 [11229] [INFO] POST /xqueue/login/

```

all databases have been moved and migrated from an ironwood instance.

---

<div class="post-metadata">

**Author:** ![mahyard](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/mahyard/32/54_2.png) [@mahyard](https://discuss.openedx.org/u/mahyard)\
**Post date:** [May 20, 2021, 7:47pm UTC](https://discuss.openedx.org/t/cert-exited-too-quickly/4700/5 "2021-05-20T19:47:00Z")

</div>

For anyone else who might have a similar issue, this was my problem and how I solved it.  
During Open edX installation, an xqueue user is being created that later will be used by certs service to make connections to xqueue APIs. prior to juniper, that user’s password was hard-coded as **password**. but now it will be generated and stored in my-passwords.yml. thus if you have your own database that has been migrated from former edX releases, you need to update the new password manually for xqueue. these commands helped me to do so:

```bash
sudo -u xqueue -H bash
cd ~/xqueue/
source ~/xqueue_env 
python manage.py shell

```

now inside the django shell environment:

```python
from django.contrib.auth.models import User
user = User.objects.get(username='lms')
user.set_password('COMMON_XQUEUE_LMS_PASSWORD')
user.save()

```

You cand find COMMON\_XQUEUE\_LMS\_PASSWORD in my-passwords.yml.

---

<div class="post-metadata">

**Author:** ![eugenechabanov](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/eugenechabanov/32/3018_2.png) [@eugenechabanov](https://discuss.openedx.org/u/eugenechabanov)\
**Post date:** [November 12, 2021, 6:04pm UTC](https://discuss.openedx.org/t/cert-exited-too-quickly/4700/6 "2021-11-12T18:04:29Z")

</div>

@mahyard Thank you for your last message. I found the solution thanks to it. But in my case it was to change the password in /edx/app/certs/auth.json.  
Changed QUEUE\_PASS to ‘password’ and it did the trick.
