FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora Laptop

 
 
LinkBack Thread Tools
 
Old 09-10-2008, 10:29 AM
"Gopal Ghosh"
 
Default Privilege factors

Dear All,
could any one help me with Privilege available to
root /su/ sudo
and also the difference between the above three

************************************************** *************
[gopalghosh@localhost ~]$ whoami
gopalghosh
[gopalghosh@localhost ~]$ login

login: root
Password:
Login incorrect {why it is saying Login incorrect as I am typing the correct password}

[gopalghosh@localhost ~]$ login
login: root
Password:

Login incorrect

[gopalghosh@localhost ~]$ su

Password:******* {when I logged as su it accepted the same password}
[root@localhost gopalghosh]# sudo ls

Desktop* Documents*Download* Music* Pictures*Public* Templates* Videos

[root@localhost gopalghosh]# exit

exit

[gopalghosh@localhost ~]$ sudo nano
We trust you have received the usual lecture from the local System

Administrator. It usually boils down to these three things:
*** #1) Respect the privacy of others.

*** #2) Think before you type.
*** #3) With great power comes great responsibility.

[sudo] password for gopalghosh:
gopalghosh is not in the sudoers
file.* This incident will be reported. {how to add my local login in*sudoers file}
[gopalghosh@localhost ~]$
************************************************** ****

Thanksregards


_______________________________________________
Fedora-laptop-list mailing list
Fedora-laptop-list@redhat.com
http://www.redhat.com/mailman/listinfo/fedora-laptop-list
 
Old 09-10-2008, 11:23 AM
Kae Verens
 
Default Privilege factors

Gopal Ghosh wrote:
Dear All, could any one help me with Privilege available to *root /su/
sudo and also the difference between the above three *


"root" is a username
"su" is a command which switches who you are logged in as ("substitute user")
"sudo" allows you to run a command as if you were another user (a pun on the word "pseudo")



************************************************** *************

[gopalghosh@localhost ~]$ whoami

gopalghosh

[gopalghosh@localhost ~]$ login

login: root

Password:

Login incorrect {why it is saying Login incorrect as I am typing the
correct password}


I've never seen the command "login" used in a shell before... most people use su.

check "man login" for details of login if you really want to use it. Otherwise I presume su is sufficient (I've never
needed to use "login" myself).



[gopalghosh@localhost ~]$ login

login: root

Password:

Login incorrect

[gopalghosh@localhost ~]$ su

Password: {when I logged as su it accepted the same password}

[root@localhost gopalghosh]# sudo ls


there is no point doing "sudo ls" as root, as that command basically says "run 'ls' as root".


Desktop Documents Download Music Pictures Public Templates Videos

[root@localhost gopalghosh]# exit exit

[gopalghosh@localhost ~]$ sudo nano

We trust you have received the usual lecture from the local System

Administrator. It usually boils down to these three things:

#1) Respect the privacy of others.

#2) Think before you type.

#3) With great power comes great responsibility.

[sudo] password for gopalghosh:

gopalghosh is not in the sudoers file. This incident will be reported.
{how to add my local login in sudoers file}


check your /etc/sudoers file

for general use, there is no real need for sudo. You might need it in a multi-user environment where you want someone to
have access to some higher-level functions but not to know the root password.


however, in a one-user environment (a laptop is usually single-user), there's no real point using sudo.

personally, I either su to root, or run something like this:
su -c ls

this is just my opinion - perhaps other people have good reasons to use it.

kae

_______________________________________________
Fedora-laptop-list mailing list
Fedora-laptop-list@redhat.com
http://www.redhat.com/mailman/listinfo/fedora-laptop-list
 

Thread Tools




All times are GMT. The time now is 07:07 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org