DEV Community

Rahul Khan
Rahul Khan

Posted on

2 2

Reset Drupal Admin Password using Drush

This article describes how to reset the Drupal administrator password using Drush. We can use the Drush command line tool to reset the administrator password (or the password of any other user).

To do this, we have to first log in with our account using SSH & enter the following commands:

C:\Users\user_name>ssh site_name.dev@site_name.ssh.dev.acquia-sites.com
site_name@dev-1234:~$ cd ..
site_name@dev-1234:/home$ cd ..
site_name@dev-1234:/$ cd var/www/html/site_name/docroot
site_name@dev-1234:/var/www/html/site_name/docroot$ drush --uri=site_name.com upwd admin --password=Password123
Changes password for admin
site_name@dev-1234:/var/www/html/site_name/docroot$ exit
logout
Connection to site_name.ssh.dev.acquia-sites.com closed.
Enter fullscreen mode Exit fullscreen mode

I did this for my project in DEV environment. I hope this is helpful & I would appreciate if any better solution is available.

Top comments (0)

Quickstart image

Django MongoDB Backend Quickstart! A Step-by-Step Tutorial

Get up and running with the new Django MongoDB Backend Python library! This tutorial covers creating a Django application, connecting it to MongoDB Atlas, performing CRUD operations, and configuring the Django admin for MongoDB.

Watch full video →

👋 Kindness is contagious

Dive into this informative piece, backed by our vibrant DEV Community

Whether you’re a novice or a pro, your perspective enriches our collective insight.

A simple “thank you” can lift someone’s spirits—share your gratitude in the comments!

On DEV, the power of shared knowledge paves a smoother path and tightens our community ties. Found value here? A quick thanks to the author makes a big impact.

Okay