LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Partition for a new server (https://www.linuxquestions.org/questions/linux-newbie-8/partition-for-a-new-server-933875/)

cheerful 03-11-2012 07:12 AM

Partition for a new server
 
There are various guide on how to set up partitions for a new server. My goal is primarily for easy upgrade of OS so that the configuration and user data can be left intact. What are the necessary partitions and their size? The disk is 500 GB. The user data will go to separate disk (1 TB)

Thanks

unSpawn 03-11-2012 09:36 AM

Given your final answer here know Centos comes with standard documentation that's almost always worth checking. See the Installation Guide, 4.18. Partitioning Your System, for suggestions. A full installation requires 5 GB as "Recommended Partitioning Scheme" says but a minimal setup (install what services you need after basic hardening) requires approximately 700 to 800 MB. Since it's a server I suggest not using LVM but the old school primary and logical /boot, /, /usr, /tmp, /var, /home partitioning scheme and note /var should best be twice the amount of shared / hosted content, caches and log files you estimate you amass in a years time (or whatever you think your retention time should be):
Code:

/boot 100 MB  # over 3 kernels is overkill
/    1  GB  # only small dirs like /lib, /root, /etc, /dev and the /sys and /proc VFSes
/usr  20  GB  # would leave over 15 GB for your SW if you do a full install (which you shouldn't)
/tmp  1  GB  # way overkill
/var  10  GB  # or whatever your guesstimate would be
/home          # whatever you need
swap          # depends on how much RAM you have and how hungry your apps are

* Some will try to argue that having a swap, / and /home "is good enough" for a server. So. If you like surprises at three in the morning and your admin work to be full of the type of excitement you didn't ask for then be sure to follow those valuable suggestions ;-p

Some (post) install time suggestions:
- if you can run a local (virtualization guest?) staging server so testing things doesn't fsck up your server,
- only install software, expose and run services you need,
- do not disable SELinux but seek fixes instead,
- ensure you have a working backup scheme,
- ensure you apply every update when it is released,
- never log in as root but SSH in via an unprivileged user account with pubkey auth,
- try to avoid web-based management panels,
- properly harden your setup and audit regularly,
- read the basic RHEL, SANS and OWASP (security) documents.


All times are GMT -5. The time now is 05:45 PM.