LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-29-2010, 12:44 AM   #1
sachin gupta
LQ Newbie
 
Registered: Jun 2010
Location: DELHI
Distribution: Open source
Posts: 9

Rep: Reputation: 0
root login problem


hi ,
i am redhat linux5 user.i want to do that whenever root is logged in he can not get GUI mode,he only get text mode or virtual console mode.
 
Old 06-29-2010, 12:55 AM   #2
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Q: Why?
 
Old 06-29-2010, 01:21 AM   #3
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
Have not tried it myself but you could try. Edit the file /etc/pam.d/gdm and add the line:

Code:
auth required pam_succeed_if.so user != root quiet
But I would still ask, WHY? RH is supposedly your server and you would login to your server only for administrative tasks, complete them and logout. And you would require root for the purpose. su and sudo are there but they are more oftenly meant to be used for taking permissions for certain time and give them up. More likely on desktops.
 
Old 06-29-2010, 01:31 AM   #4
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
Q: Why you don't want to do that?
A: see e.g. this thread from 2005


Last edited by Wim Sturkenboom; 06-29-2010 at 01:33 AM.
 
1 members found this post helpful.
Old 06-29-2010, 03:10 AM   #5
16pide
Member
 
Registered: Jan 2010
Posts: 418

Rep: Reputation: 83
on a server /etc/inittab should be set to level 3, so no gnome, x11, gdm, etc ...
just a login prompt, and a shell below it.

One reason is that you don't want to be running lots of processes as root. For admin purpose, a bash shell should be enough.
Another reason is that if there is a security hole in one of the processes of a gnome session, then you are exposing it a lot by logging in as root!
 
Old 06-29-2010, 03:18 AM   #6
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
I do agree with both of you. But if its a server disabling root user will not solve purpose. I do not remember logging into server for web browsing or checking emails. When I log in into server, its for the administrative purposes and no more. And for those purposes, root access is necessary. And in that case X should not be running in the first place. But if it is, disabling root would not completely solve the issue as he would anyhow need to login using root in console.
It would not be true for desktop though for not all desktop users are used to it.
 
Old 06-30-2010, 04:08 AM   #7
16pide
Member
 
Registered: Jan 2010
Posts: 418

Rep: Reputation: 83
Logging on a server in xwindow means launching lots of processes. If just one has a security problem, and you log as root, then you can compromise the whole server.

logging on a server in text mode just launches the shell process. This way, you have less chance of compromising your server.

I know some administrators are smart enough to not browse the Internet as root, etc ... but for admin activity I've never needed to launch an xwindow session.
NB: you still have the possibility to log in as a normal user, then use su to become root, and launch the graphic application that you desperately need.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Root Login Problem shan_nathan Linux - Desktop 2 09-07-2007 10:14 AM
Problem with root login ! eeeboy Ubuntu 10 05-18-2007 04:39 PM
Problem with root login ibshar Linux - Newbie 2 09-26-2006 06:55 AM
Root Login Problem ... boborano Linux - Security 6 08-16-2006 02:48 AM
Problem Login As Root, Help!!!!! abulafiar Linux - Newbie 4 08-15-2004 03:54 PM


All times are GMT -5. The time now is 01:28 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration