reset_da_admin_password script contains error in line 98

HindrikOxilion

Verified User
Joined
Sep 23, 2011
Messages
33
Hello all,

We're just building a new VM template with DirectAdmin. After cloning this to a new instance, we change several passwords, including the 'da_admin' password for MySQL, with the provided script located in: "/usr/local/directadmin/scripts/reset_da_admin_password.sh"

However, it appears there's an error in line 98, as we get this output:

/usr/local/directadmin/scripts/reset_da_admin_password.sh: line 98: [: missing `]'

Upon inspecting this line, it appears that there's indeed a missing ']'. This is the entire line 98 from the script:

if [ -s ${SETUP_TXT}; then

This looks like an oversight, and should be remedied to:

if [ -s ${SETUP_TXT} ]; then

This must be a recent change, since it used to work some time ago (sorry for not being more accurate than that). Manually downloading the latest "update.tar.gz" archive from DirectAdmin directly still contains this error at present.

Could someone fix this script for new installs?

With kind regards,

Hindrik Deelstra
Oxilion B.V.
 
It's been fixed in pre-release, than you for the report!

To install pre-release on setup time, you may just use ./setup.sh auto beta
 
Hey Martynas,

Thanks for looking into this, and providing a quick resolution! ;)

With kind regards,

Hindrik Deelstra
Oxilion B.V.
 
Back
Top