To Root or Not To Root

Non release banter
Bogomips
Full of knowledge
Full of knowledge
Posts: 2549
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: To Root or Not To Root

Post#16 by Bogomips » 05 Sep 2016, 00:03

jssouza wrote:
Bogomips wrote:Not all instructions run as root.
Hi Bogomips,
Just for my understanding (and learning) could you give an example for this? I thought anything could be run as root.
Thanks!
Hi jssouza
Bogomips wrote:Not all instructions run as root.
Quote taken out of context. :twisted: The context was sudo with no pw requirement vs. logging in as root. So to have the same effect every CLI would have to be prefixed with sudo. Running with non-root privilege this would not be the case from a practical point of view, hence the assertion that not all instructions run as root, because of the onerous task of prefixing every single one of them with sudo. :wall:
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

jssouza
Samurai
Samurai
Posts: 180
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: To Root or Not To Root

Post#17 by jssouza » 05 Sep 2016, 07:03

Got you now. That was my misunderstanding. Sorry about that.

User avatar
wread
Module Guard
Module Guard
Posts: 1069
Joined: 09 Jan 2011, 18:48
Distribution: Porteus v3.2.5-kde5-64 bits
Location: Santo Domingo
Contact:

Re: [Solved again]To Root or Not To Root

Post#18 by wread » 05 Sep 2016, 13:58

@all
You are all affected by the illness of the Windows vulnerability......Of course, 100% of us come from that platform.

As root, you can mess Linux only if you press the wrong button in the right moment, that's all! and if you do, start all over again; it is like learning to play piano!

I bet with my first post, Porteus newbies are daring to use VirtualBox for the first time.....they were afraid to try it, because nobody told them how to use it. They are afraid to mess the system... :fool: It is like fornicating under consentment of the king with a preservative. In Windows you can get a venereal disease or generate an unwanted pregnancy, whereas in Linux only the second is the case...

Don't be afraid of fatherhood!
I have the impression, advanced users do not want newbies to become advanced, and so they eliminate competitors!

Try root, guest is for the others! Break the barrier of idiotness 8)
Porteus is proud of the FASTEST KDE ever made.....(take akonadi, nepomuk and soprano out and you will have a decent OS).
The Porteus Community never sleeps!

User avatar
brokenman
Site Admin
Site Admin
Posts: 5460
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v3.2rcX all desktops
Location: Brazil
Contact:

Re: To Root or Not To Root

Post#19 by brokenman » 05 Sep 2016, 16:13

In Windows you can get a venereal disease or generate an unwanted pregnancy, whereas in Linux only the second is the case...
:ROFL: I don't think most linux geeks any. Sex I mean.
Try root, guest is for the others!
Even better, do it in virtualbox like Wread suggests. It's like wearing protection! :shock:
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
wread
Module Guard
Module Guard
Posts: 1069
Joined: 09 Jan 2011, 18:48
Distribution: Porteus v3.2.5-kde5-64 bits
Location: Santo Domingo
Contact:

Re: To Root or Not To Root

Post#20 by wread » 05 Sep 2016, 20:16

Fine Bussiness, Jay!

In the long run, we can keep it so by guest...and,
If the newbies want really to learn, they should hack their way through Porteus!

Cheers!
Porteus is proud of the FASTEST KDE ever made.....(take akonadi, nepomuk and soprano out and you will have a decent OS).
The Porteus Community never sleeps!

Bogomips
Full of knowledge
Full of knowledge
Posts: 2549
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: To Root or Not To Root

Post#21 by Bogomips » 05 Sep 2016, 20:22

^ All very well to say to do it in virtualbox, but one should realise that quite a few of us just do not have the resources to run virtualbox. :wall:
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
wread
Module Guard
Module Guard
Posts: 1069
Joined: 09 Jan 2011, 18:48
Distribution: Porteus v3.2.5-kde5-64 bits
Location: Santo Domingo
Contact:

Re: To Root or Not To Root

Post#22 by wread » 05 Sep 2016, 22:54

@Bogomips
What do you mean by that?
All very well to say to do it in virtualbox, but one should realise that quite a few of us just do not have the resources to run virtualbox. :wall:
Resources: computer, a pendrive with Porteus, maybe an internet connection (not all the time).

Maybe one of our upstream people should write a tutorial....
Porteus is proud of the FASTEST KDE ever made.....(take akonadi, nepomuk and soprano out and you will have a decent OS).
The Porteus Community never sleeps!

Bogomips
Full of knowledge
Full of knowledge
Posts: 2549
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: To Root or Not To Root

Post#23 by Bogomips » 05 Sep 2016, 23:44

wread wrote:@Bogomips
What do you mean by that?
All very well to say to do it in virtualbox, but one should realise that quite a few of us just do not have the resources to run virtualbox. :wall:
Insufficient RAM to run virtualbox in my case. :(
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
Ed_P
Contributor
Contributor
Posts: 3164
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 3.2.2 64-bit ISO
Location: Western NY, USA

Re: To Root or Not To Root

Post#24 by Ed_P » 06 Sep 2016, 00:26

Bogomips wrote:Insufficient RAM to run virtualbox in my case. :(
Try changing your ramsize to 60%.
Bogomips wrote:Here's one I make earlier:

Code: Select all

quiet from=/dev/sda10/tmp/iso/rc5/x86_64/Porteus-CINNAMON-v3.2rc5-x86_64.iso copy2ram ramsize=30% noauto rootcopy=/dev/sda4/cin64rcp 
Ed

User avatar
brokenman
Site Admin
Site Admin
Posts: 5460
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v3.2rcX all desktops
Location: Brazil
Contact:

Re: To Root or Not To Root

Post#25 by brokenman » 06 Sep 2016, 02:01

I guess if you don't have the resources there is not much you can do. Looking at your sig though ...
MemTotal: 901760 kB MemFree: 66752 kB
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
wread
Module Guard
Module Guard
Posts: 1069
Joined: 09 Jan 2011, 18:48
Distribution: Porteus v3.2.5-kde5-64 bits
Location: Santo Domingo
Contact:

Re: To Root or Not To Root

Post#26 by wread » 06 Sep 2016, 19:49

@Bogomips
My Porteus Kde5 lives in a 8 Gb pendrive, with few applications in modules and many in optional; so my system load is about 700Mb/3.8 Gb (4Gb-ram of a Toshiba Satellite)

For VirtualBox you need only to gain space in your harddisk, say 64 Gb and format it as ext4. Use GParted for it.

Then for each OS you run, you make a module containing /root/VirtualBox Vms and /root/.config/VirtualBox. For instance myVBNemesis.xzm, myVBMate.xzm, myVBCinnamon.xzm, myVtBKde5.xzm, myVBWindowsXP.xzm, etc,etc...for this you can make your first run (for each OS in VB) normally, then make the module and move it to your new partition. These modules contain the virtual hard disks of the corresponding OSes and can grow so big that they don't pass in the pendrive...

Needless to say if you are comfortable with your changes you must always update your myVBxxxxxxx.xzm module.

Now running in AF mode as root, I have VirtuaBox in an optional folder, together with dependencies, I first activate VB's, then go to the harddisk partition (in my case /mnt/sda7) that hosts myVBxxxxxx.xzm and activate the OS I want to run..., start VB with any OS you want.

Try it!

Elemental, Watson 8)
Porteus is proud of the FASTEST KDE ever made.....(take akonadi, nepomuk and soprano out and you will have a decent OS).
The Porteus Community never sleeps!

Bogomips
Full of knowledge
Full of knowledge
Posts: 2549
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: To Root or Not To Root

Post#27 by Bogomips » 07 Sep 2016, 10:29

brokenman wrote:Also interested to know how come my sudo required a password and yours didn't and it was the password for guest not root!!
Once you enter your password it remains in memory for 15 minutes (default) which is controlled in /etc/sudoers.
This will change your timeout to 30 minutes.

Code: Select all

Defaults        env_reset,timestamp_timeout=30
This will have sudo insult you whenever you type a wrong password. Sometimes coders get bored. Go figure.

Code: Select all

Defaults insults
The sudo function should only need your guest password. That's what makes it so nice. This can be changed to ask for root password if your into that.
With all due respect I cannot for the life of me figure out the advantage of needing a guest password over no password at all for sudo. Fixed sudo to not require a password, thereby having all the advantages of login as root, without disadvantage of untrusted programs/scripts running with elevated privilege: viewtopic.php?f=48&t=6186#p48596

@wread
The last time I tried to build virtualbox I ran out of memory. However have no memory issue compiling a kernel module.
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

donald
Full of knowledge
Full of knowledge
Posts: 1162
Joined: 17 Jun 2013, 13:17
Distribution: Porteus 3.2.2 XFCE 32bit
Location: Germany

Re: To Root or Not To Root

Post#28 by donald » 07 Sep 2016, 13:31

Bogomips wrote: I cannot for the life of me figure out the advantage of needing a guest password over no password at all for sudo.
Ok, maybe it's not that relevant for porteus.
In general; asking for the guest/user password makes sure that the one calling sudo is the same person originally logged in.
(Not someone else, misusing your client/PC while you go to get a coffee. etc.)
You will not believe how many people do not lock the screen while they go away.

User avatar
brokenman
Site Admin
Site Admin
Posts: 5460
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v3.2rcX all desktops
Location: Brazil
Contact:

Re: To Root or Not To Root

Post#29 by brokenman » 07 Sep 2016, 18:07

Also, you probably don't want someone looking over your shoulder to find out your root password because you are a one finger typist. I am not so paranoid that I wear a laptop sock and play music while typing a root password, but if I am ssh'ing into a server I prefer not to have to type my root password whenever possible.
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
francois
Contributor
Contributor
Posts: 4946
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: To Root or Not To Root

Post#30 by francois » 11 Sep 2016, 16:18

Here is an interesting discussion about su, sudo, root and the rest:
http://unix.stackexchange.com/questions ... u-or-login

It depends on how you are experienced and on what sensitive data you have on your computer. In my case, there is not much. And my bank and credit card institutions care about security, but seems to be quite satisfied with their own measures.

Personally, I leave my sensitive data on usb, as I do not have tons of it 8 gig is actually more than I need. And there an external hdd for these photograph that I accumulate.

Recently, I had to redo partitioning on the laptop, I just did it and reinstall anew.
Voltaire: Le mieux est l'ennemi du bien.

Post Reply