Real root account.

Questions about applications and software
Forum rules
Before you post please read how to get help
Post Reply
weedeater64
Level 1
Level 1
Posts: 6
Joined: Mon Jun 08, 2015 6:23 pm

Real root account.

Post by weedeater64 » Sun Aug 21, 2016 2:42 am

How do you enable a real root login?

I know you can do

Code: Select all

sudo su
, but how do you go about actually logging into the root account?

Followed by, how do you remove the sudo program without taking half the system with it?

Code: Select all

aptitude purge sudo
Wants to take out apturl casper cinnamon gdebi gksu lupin-casper mdm mint-meta-cinnamon mint-meta-core mintwelcome nemo-share ubuntu-minimal.

That is insane, and obviously not necessary. Rather an example of the sometimes retarded behavior from apt.

I'm assume this is similar to the problem of installing dokuwiki with lighttpd instead of apache. To do that you have to install php5 and something else, I can't remember what, to prevent apt installing apache.

Surely this is something similar, just need to purge some other program first, to prevent apt from raping your system senselessly.

User avatar
Pjotr
Level 20
Level 20
Posts: 12377
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland)
Contact:

Re: Real root account.

Post by Pjotr » Sun Aug 21, 2016 4:36 am

What you're wanting to do, is very unwise. And that's the understatement of the year. :shock:

Why do you want this?
Tip: 10 things to do after installing Linux Mint 19.1 Tessa
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.

Cosmo.
Level 23
Level 23
Posts: 17827
Joined: Sat Dec 06, 2014 7:34 am

Re: Real root account.

Post by Cosmo. » Sun Aug 21, 2016 4:47 am

weedeater64 wrote:How do you enable a real root login?
Wrong question.
What you try has been named - unwillingly - by yourself:
weedeater64 wrote:That is insane

User avatar
karlchen
Level 20
Level 20
Posts: 10673
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Real root account.

Post by karlchen » Sun Aug 21, 2016 6:17 am

Hello, weedeater64.

The fact that root cannot directly login at all is a Ubuntu decision which the Ubuntu creators have made to enhance security.
The Mint makers have adopted this approach, with one change: On Ubuntu based Mint root can login directly on the console monitors (tty1 to tty6). If you have read the LinuxMint user guide* carefully you will know already.
On Mint root cannot login to the graphical desktop environment. This enhances system security.
Preventing root from logging in is achieved by system settings which can be changed. It is absolutely unrelated to the commands sudo and su. Hence removing any of the corresponding software packages is absolutely unnecessary and strongly discouraged.

Please, start by reading this Ubuntu article on Root Sudo in order to understand the security concept and how it can be changed without wrecking your system.

The answer to your question below
weedeater64 wrote:Followed by, how do you remove the sudo program without taking half the system with it?
clearly is: you cannot do so. You should not even try to do so. There is absolutely no point in uninstalling sudo.

Best regards,
Karl
--
* bottom of page 20
Image
Linux Mint 18.1 64-bit Cinnamon Desktop, Total Commander 9.22a 64-bit
Ubuntu 18.04.2 32-bit Mate Desktop, Total Commander 9.22a 32-bit
Windows? - 1 window in every room

Mute Ant
Level 14
Level 14
Posts: 5135
Joined: Tue Sep 03, 2013 7:45 pm
Location: Norfolk UK

Re: Real root account.

Post by Mute Ant » Sun Aug 21, 2016 7:46 am

Without removing any package, you can prevent the real sudo from running by pre-empting it with a local dummy version. You need to log out and back in for this to be noticed...

Code: Select all

### Give shells looking for the sudo binary a placebo.
mkdir -p ~/bin  &&  echo bin >> ~/.hidden  &&  cp /bin/false ~/bin/sudo
You might want to reverse this...just delete the placebo...

Code: Select all

### Remove the placebo sudo command.
[ -e ~/bin/sudo ]  &&  rm ~/bin/sudo

"How do you enable a real root login?" I don't. For a Twenty-Minuter[*]...
Control Centre ... Login Window ... Options ... Allow root login
...would be the box to tick.

[*]...because the 20 minutes is the life expectancy of a new pilot...https://en.wikipedia.org/wiki/Private_Plane
Last edited by Mute Ant on Sun Aug 21, 2016 9:03 am, edited 1 time in total.
While you're waiting, read the free novel we sent you. It's a Spanish story about a guy named "manual".

Hoser Rob
Level 14
Level 14
Posts: 5151
Joined: Sat Dec 15, 2012 8:57 am

Re: Real root account.

Post by Hoser Rob » Sun Aug 21, 2016 9:00 am

weedeater64 wrote:How do you enable a real root login?

I know you can do

Code: Select all

sudo su
, but how do you go about actually logging into the root account?

Followed by, how do you remove the sudo program without taking half the system with it?

Code: Select all

aptitude purge sudo
Wants to take out apturl casper cinnamon gdebi gksu lupin-casper mdm mint-meta-cinnamon mint-meta-core mintwelcome nemo-share ubuntu-minimal.

That is insane, and obviously not necessary. Rather an example of the sometimes retarded behavior from apt....
It's not apt that's being retarded. As mentioned what you're doing is nuts.

When you're at the root permission level linux/unix assumes you know EXACTLY what you're doing. And you don't. This is why noobs are discouraged from using root level access. It's a good way to break your system.

You want to play and break things, fine. Just do it on a spare machine you don't need. Totally breaking an OS and then having to fix it is one of the best ways to learn. But that only really works in systems where you can't reinstall everthing.

User avatar
Flemur
Level 16
Level 16
Posts: 6847
Joined: Mon Aug 20, 2012 9:41 pm
Location: Potemkin Village

Re: Real root account.

Post by Flemur » Sun Aug 21, 2016 11:59 am

Code: Select all

$ login root
login: Cannot possibly work without effective root
$ sudo -i
[sudo] password for XXX: 
# whoami
root
# pwd
/root
# 
IIRC, "login root" works on some distros (Arch?)
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?
Mint 19.1 Xfce/fluxbox
Manjaro openbox/fluxbox

User avatar
JohnBobSmith
Level 4
Level 4
Posts: 338
Joined: Wed Nov 06, 2013 5:42 pm
Location: Canada

Re: Real root account.

Post by JohnBobSmith » Sun Aug 21, 2016 3:39 pm

Flemur, that is correct. I can log in without a hitch as real root when using Arch Linux. Although logging in as a real root user, for any length of time, is stupid. Polluting /root with random files *will* break something. Running xorg (graphical environment) as root is a massive security hole, and has not been required for a very long time. Mistakes while using the root user are permanent. You are less protected from bad remove commands. Or quite frankly, ANY command. Even when setting up sudo, never use sudo nano /etc/sudoers... you should be using visudo, or for ease of use, EDITOR=nano visduo <whatever>.

My point is: Being a real root user, for any length of time, is a terrible idea which will cause breakages independent of Linux distribution. Sudo is safer. And I find it to be more convenient. :)
Image
If you want to change the world, start by changing yourself.
Success is often 1% inspiration and 99% perspiration.
You get one shot at life, so live to the maximum, not the minimum.

Post Reply

Return to “Software & Applications”