In addition to Weibo, there is also WeChat
Please pay attention

WeChat public account
Shulou
2025-11-10 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
1. Modify / etc/sudoers, find the following line, and add an ordinary user, such as user abc, under root (provided that the abc user already exists and the password is set):
Allow root to run any commands anywhere
Root ALL= (ALL) ALL
Abc ALL= (ALL) ALL
2. It means that the user is allowed to be given the same permission as root to execute any command anywhere.
3. Edit the configuration file of ssh, find the following line, change yes to no, and prohibit root users from logging in:
Vi / etc/ssh/sshd_config
# PermitRootLogin yes
PermitRootLogin no
4. After the above simple configuration, you can disable root login. After logging in to the machine with ordinary user abc, if you want to switch to root, then use the su command to switch to root:
Su root
Then enter the corresponding password according to the prompt
5. It is recommended to disable root login in ssh to avoid being cracked; in addition, modify the default port 22 of ssh, or add ssh whitelist to protect the server.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope





About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.