Title: Ran WP CLI as root (help)
Last modified: June 19, 2021

---

# Ran WP CLI as root (help)

 *  [mdotk](https://wordpress.org/support/users/mdotk/)
 * (@mdotk)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/ran-wp-cli-as-root-help/)
 * Hi, I encountered some issues and ran WP CLI as root, ignoring the warnings.
 * My DB appeared to be down, and I ran the DB repair command. It turns out the 
   initial problem was something else (old CDN cache).
 * Now I am paranoid that I have opened my site up to attackers.
 * I have run Wordfence and got no messages
 * Does:
 * (1) the “root access for 3rd party plugins etc” last forever as soon as I ran
   WP CLI as root
    OR (2) does the malicous script (so I would have already needed
   to be compromised?) need to be constantly trying to run some command that could
   only be executed as root, hoping that I would at some stage indeed run WPI CLI
   as root?
 * Thanks
    -  This topic was modified 4 years, 10 months ago by [mdotk](https://wordpress.org/support/users/mdotk/).
    -  This topic was modified 4 years, 10 months ago by [mdotk](https://wordpress.org/support/users/mdotk/).
    -  This topic was modified 4 years, 10 months ago by [mdotk](https://wordpress.org/support/users/mdotk/).
    -  This topic was modified 4 years, 10 months ago by [mdotk](https://wordpress.org/support/users/mdotk/).

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Liew Cheon-Fong](https://wordpress.org/support/users/lcf/)
 * (@lcf)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/ran-wp-cli-as-root-help/#post-14573323)
 * 1. no
    2. no
 * make sure the wp-cli command you run is safe.
 *  Thread Starter [mdotk](https://wordpress.org/support/users/mdotk/)
 * (@mdotk)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/ran-wp-cli-as-root-help/#post-14573348)
 * Command was:
 * wp db repair

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Ran WP CLI as root (help)’ is closed to new replies.

## Tags

 * [wp-cli](https://wordpress.org/support/topic-tag/wp-cli/)
 * [wpcli](https://wordpress.org/support/topic-tag/wpcli/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [mdotk](https://wordpress.org/support/users/mdotk/)
 * Last activity: [4 years, 10 months ago](https://wordpress.org/support/topic/ran-wp-cli-as-root-help/#post-14573348)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
