rmoff's random ramblings
about talks

Reset Hue password

Published Jul 5, 2016 by in Hue, Django, Python, Cdh at https://rmoff.net/2016/07/05/reset-hue-password/

(Ref)

The bit that caught me out was this kept failing with

Error: Password not present	

and a Python stack trace that ended with

subprocess.CalledProcessError: Command '/var/run/cloudera-scm-agent/process/78-hue-HUE_SERVER/altscript.sh sec-1-secret_key' returned non-zero exit status 1

The answer (it seems) is to ensure that HUE_SECRET_KEY is set (to any value!)

Launch shell:

export HUE_SECRET_KEY=foobar
/opt/cloudera/parcels/CDH-5.7.1-1.cdh5.7.1.p0.11/lib/hue/build/env/bin/hue shell

Reset password for hue, activate account and make it superuser

from django.contrib.auth.models import User
user = User.objects.get(username='hue')
user.is_active=True
user.save()
user.is_superuser=True
user.save()
user.set_password('hue')
user.save()

Robin Moffatt

Robin Moffatt works on the DevRel team at Confluent. He likes writing about himself in the third person, eating good breakfasts, and drinking good beer.

Story logo

© 2025