Solved

PermitRootLogin

Posted on 2009-07-16
6
350 Views
Last Modified: 2013-11-08
I'm confused about PermitRootLogin settings. It seems I need to set it off because of security reasons. But how can I reach my server with root-like permissions. I dont know how can I give root permissions to user?  I heard about "sudo" but I dont have any idea about that too.
0
Comment
Question by:middleofnowhere
  • 4
  • 2
6 Comments
 
LVL 29

Accepted Solution

by:
fosiul01 earned 500 total points
Comment Utility
Ok
its always good to use PerminRootLogin  = No
so hacker woudl not be able to login as root, incase your password is compromised

how ever, work way round is

sudo or su -

if you have sudo installed in your centos

then type

visudo

you will see a line call

## Allow root to run any commands anywhere
root    ALL=(ALL)       ALL     ------------------------------------------------------->
username  ALL=(ALL)       ALL

you just need to add username with ALL=(ALL) ALL  ( as written above)


now login to the server with username

now if you want to do any administrative task

type

sudo
it will ask for pasword, give it the password

now you will become root user


or after login to server as normal user type su -
it will ask for root password, after giving it,you will change to root user

i will sent you some other article aswell



0
 
LVL 29

Expert Comment

by:fosiul01
Comment Utility
0
 

Author Comment

by:middleofnowhere
Comment Utility
quick and precise :)
thats great now I set it. I'd like to ask that what can I do for increasing security of my server? do you have any specific suggestions or guide?
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 29

Expert Comment

by:fosiul01
Comment Utility
yes
lots of things you can do and you should do

1. use portsentry , fail2 ban ( read in google what they does)
2. dont run unnecessary service
3. tight down your server with firewall rules
4 use snort  ( read in google what it do )
0
 
LVL 29

Expert Comment

by:fosiul01
Comment Utility
0
 

Author Comment

by:middleofnowhere
Comment Utility
thats great! thanks
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

If you use Debian 6 Squeeze and you are tired of looking at the childish graphical GDM login screen that is used by default, here's an easy way to change it. If you've already tried to change it you've probably discovered that none of the old met…
1. Introduction As many people are interested in Linux but not as many are interested or knowledgeable (enough) to install Linux on their system, here is a safe way to try out Linux on your existing (Windows) system. The idea is that you insta…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now