Saturday, April 27, 2024
13
rated 0 times [  13] [ 0]  / answers: 1 / hits: 15383  / 1 Year ago, fri, november 18, 2022, 2:45:04

I don't want to type sudo and my password everytime.I think it is really annoying.Is there any command or option which will consider you root user when you open terminal,everytime When you open terminal.


More From » command-line

 Answers
6

I am really against root being used as a default login. This is a really really really BAD idea.



However, in cases where I'm working on something that requires a root terminal session with lots of sudo commands again and again it can get tiring to type sudo.



You can create a root session using the sudo -i command and enter your password once. When you are finished with whatever operations require root you can then exit and get back to a user level account.



mcgarrah@localhost:~$ sudo -i
root@localhost:~# id
uid=0(root) gid=0(root) groups=0(root)
root@localhost:~#


Again, running as root at all times is a really bad idea. Root allows for more access than a standard user needs and many of the features that make Linux more secure are no longer working for you. One example is running a web browser as root is insane.


[#26441] Saturday, November 19, 2022, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
ardtry

Total Points: 254
Total Questions: 99
Total Answers: 114

Location: Finland
Member since Fri, Oct 21, 2022
2 Years ago
;