Well, both commands would result in the changing of the password for the superuser account. "su -c passwd" would run the passwd command in the context of the root user and then drop back down to your normal user context. The sudo command would pretty much do the same thing. In my opinion, sudo is what you would want to use if you were delegating admin duties to another user. Then they would be prompted to type their own password to issue the command instead of the root password that you would be prompted for with the su command. Of course, my observations are at a very high view. Someone else with deeper knowledge would have to explain the details of exactly what is functionally different between su and sudo, if that's what you're looking for.
|