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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
02-06-2017, 06:42 AM
|
#1
|
LQ Newbie
Registered: May 2016
Posts: 8
Rep:
|
Centos 7 Installation Best Practices
I would like to know the best practices on how to install Centos 7, e.g. the amount of swap file, how to effectively partition the disk and the hardening part.
|
|
|
02-06-2017, 06:50 AM
|
#2
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7 / 8
Posts: 3,529
|
Quote:
Originally Posted by superkulit
I would like to know the best practices on how to install Centos 7, e.g. the amount of swap file, how to effectively partition the disk and the hardening part.
|
- Swap is generally personal preference, I tend to go with 4Gb and that's served me well.
- Partitions, start with the default partition scheme and adjust depending on your needs. If you need a big "/home" then adjust accordingly. If you need a big "/var/www" then adjust or partition accordingly.
- Hardening, https://benchmarks.cisecurity.org/do...s.linux.centos is a good start point.
|
|
|
02-06-2017, 07:25 AM
|
#3
|
LQ Newbie
Registered: May 2016
Posts: 8
Original Poster
Rep:
|
Consider the log partition sizes, does it needs to be in a separate partition as well, if log files consume your disk rapidly and it is located in the same partition where your systems are located, it will make your system unstable right?
|
|
|
02-06-2017, 07:39 AM
|
#4
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7 / 8
Posts: 3,529
|
Quote:
Originally Posted by superkulit
Consider the log partition sizes, does it needs to be in a separate partition as well, if log files consume your disk rapidly and it is located in the same partition where your systems are located, it will make your system unstable right?
|
Consider the advice in the CIS guide:
Quote:
1.1.2 Ensure separate partition exists for /tmp
1.1.6 Ensure separate partition exists for /var (Scored)
1.1.7 Ensure separate partition exists for /var/tmp (Scored)
1.1.11 Ensure separate partition exists for /var/log (Scored)
1.1.12 Ensure separate partition exists for /var/log/audit (Scored)
1.1.13 Ensure separate partition exists for /home (Scored)
|
|
|
|
02-06-2017, 07:47 AM
|
#5
|
LQ Newbie
Registered: May 2016
Posts: 8
Original Poster
Rep:
|
Thanks a lot for the guide, apologize for not checking first the link you sent. Again, I really appreciate your quick response.
|
|
|
02-06-2017, 08:30 AM
|
#6
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7 / 8
Posts: 3,529
|
You're welcome. There are many, many, many examples of what people consider "best practice" when it comes to swap and partitioning, stick 4 linux guys in a room and they'll fight about it forever.
|
|
|
02-06-2017, 09:02 AM
|
#7
|
LQ Newbie
Registered: May 2016
Posts: 8
Original Poster
Rep:
|
, Thanks again!
|
|
|
02-06-2017, 01:11 PM
|
#8
|
LQ Veteran
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Salix
Posts: 6,191
|
Remember that it depends on what you are installing it on. Partitions for /var and /tmp may be very important on a server, but they are a waste of time on a desktop or laptop. If you let CentOS use LVM (also more suited to a server) or you have EFI, then you need /boot. If you have a modern computer with plenty of memory, you may not need swap. The only thing that's definite is that you need root and home partitions. I have 10GB for root, but I don't have vast amounts of software. See the CentOS and Red Hat documentation for more advice.
CentOS will have the firewall and SEL enabled by default, so it's pretty secure.
|
|
1 members found this post helpful.
|
02-07-2017, 08:42 AM
|
#9
|
LQ Newbie
Registered: May 2016
Posts: 8
Original Poster
Rep:
|
Thanks David McCann! Also, does anyone knows if joining Linux to WIndows domain has advantages over standalone configurations. If so, could anyone provide any available guide of getting Centos server join to Winodws Domain
|
|
|
02-07-2017, 08:48 AM
|
#10
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7 / 8
Posts: 3,529
|
Quote:
Originally Posted by superkulit
does anyone knows if joining Linux to WIndows domain has advantages over standalone configurations.
|
Depends on why you'd want it on the domain. Without your use-case scenario it's hard to tell.
|
|
|
02-07-2017, 08:57 AM
|
#11
|
LQ Newbie
Registered: May 2016
Posts: 8
Original Poster
Rep:
|
Hadoop environment
|
|
|
02-07-2017, 09:18 AM
|
#12
|
LQ Newbie
Registered: May 2016
Posts: 8
Original Poster
Rep:
|
My use case is Hadoop environment cluster running latest version of Centos OS,
|
|
|
02-07-2017, 09:21 AM
|
#13
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7 / 8
Posts: 3,529
|
Tells us nothing about why you think it should be part of a Windows domain.
|
|
|
02-07-2017, 04:36 PM
|
#14
|
LQ Newbie
Registered: May 2016
Posts: 8
Original Poster
Rep:
|
Ease of User management, security and audit purposes.
|
|
|
02-07-2017, 05:53 PM
|
#15
|
LQ Guru
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573
|
Quote:
Originally Posted by DavidMcCann
The only thing that's definite is that you need root and home partitions.
|
Not at all, /home is perfectly happy living on the root partition. All you need is / (and /boot if EFI), everything else is optional.
|
|
|
All times are GMT -5. The time now is 06:26 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|