---

Understanding the difference between sudo and su

In this article, we will discuss in detail the ‘su’ command as well as how it differs from the ‘sudo’ command. The main work of the su command is to let you switch to some other user during a login session. In other words, the tool lets you assume the identity of some other user without having to logout and then login (as that user).

Get the Free Newsletter!

Subscribe to Developer Insider for top news, trends, & analysis