Saturday, May 3, 2025

Resetting the DirectAdmin Password via SSH:

 Resetting the Password via SSH:

  1. Access the server as root: Use an SSH program like PuTTY to connect to your server as the root user. 
  2. Reset the password: Execute the command passwd <username> (replace <username> with your DirectAdmin username, often admin or your server username). 
  3. Follow the prompts: You'll be prompted to enter a new password twice. 
  4. Verify the change: Once successful, you'll see a message confirming the password change. 
  5. Restart DirectAdmin (optional): You may need to restart the DirectAdmin service using the command service directadmin restart. 

SQL to delete all WooCommerce products except those with "draft" status

 -- Disable foreign key checks (important for InnoDB) SET     FOREIGN_KEY_CHECKS = 0;     -- Delete product meta DELETE     pm FROM     wp_p...