It wont let me open the flash drive to get the files I need. Anyone know the line of code I need to put me as root. I would like to stay root.
Asked
Active
Viewed 4,303 times
-2
1 Answers
0
Ubuntu is designed so you don't need to be root; instead you do
sudo -i
inside a terminal emulator window which bestows the rights of root.
However, it's safer to use
sudo *commmandtoexecute*
as needed; for example, if you want to open the file manager in Ubuntu with the rights of root, do
sudo nautilus
A good explanation of the options available with sudo, can be found in the answers at What are the differences between "su", "sudo -s", "sudo -i", "sudo su"?
And, this is done for user safety and administrator sanity. root is just too powerful and it's far too easy to break a system and/or destroy data to be in root all the time.

K7AAY
- 17,202
-
2Please advice
sudo -i
oversudo su
. The 1st will log events as the user and not as root. – Rinzwind May 23 '18 at 17:16 -
i want to stay root forever is there a line of code that can make me root forever? – oof off May 23 '18 at 17:59
-
2"Stay root forever" == "I will NEVER make a mistake or typo". 50 years – waltinator May 23 '18 at 20:00
sudo su
will keep you as root. Use with caution. – stumblebee May 23 '18 at 17:07sudo su root
will make you the root user on command line. However, I'm guessing you probably just need to change the owner of the mounted flash drive, which should be located under /media/username/drivename. In the cli from /media/username you can runsudo chown -R username drivename
which should make it accessible to you from the Ubuntu GUI. – phandolin May 23 '18 at 17:08