Better guard around update mysql root password

`ping` always returns 0; `version` does not