Customized Linux operating system installation
I. Why do I need to customize and install the operating system?
1. faster installation
2. Better security
3. Better Stability
4. deepen understanding of the system
Ii. Operating System installation principles
1. Use English as the installation language to avoid garbled characters.
2. Select the text installation method.
3. Use a newer stable version.
4. Try not to use the large third-party software that comes with the system, such as Apache and PHP.
5. Do not install multiple operating systems on one host in the production environment (except virtualization ).
Iii. Key requirements for operating system installation
1. Disk Partition Customization
Store important data and program data in dedicated Data Directories and separate them from System directories to enhance data security.
2. Software Package selection Customization
Install only a few necessary software packages to enhance system security and stability.
3. Language Customization
Select installation in English to avoid garbled characters.
Iv. unified regulations on the company's operating system
1. Requirements on language selection
Use English as the installation language to prevent garbled characters.
2. Time Zone selection rules
Asia/Chongqing is used as the time zone to ensure the consistency of the time zone of each server.
3. Requirements on Disk Partitions
Partition is divided into four zones in a unified manner. The specific arrangements are as follows:
Partition name |
Partition type |
Partition size |
|
Swap |
Memory 1.5 ~ 2 times. If the system memory is greater than or equal to 16 GB, the swap and memory size can be set to the same. |
/Boot |
Ext3 |
100 m |
/ |
Ext3 |
50000 m |
/Data |
Ext3 (the database is XFS) |
All remaining space |
4. Requirements on software package selection
Select only the installation packages of administration tools/development libraries/development tools/system tools/Editors/server configuration tools.
V. Operating System Installation Process
This installation guide uses centos 5.5 64bit as an Example
1. Pilot phase
Insert a 64-bit centos 5.5 disc to start the system boot phase, as shown in:
Select skip to skip the media test. Otherwise, it will take a long time.
2. Initial System Configuration
Select the language when installing the system, and select English in a unified manner to avoid garbled characters, such:
Select the keyboard. The default setting is OK.
3. Partition customization stage
Remove all partitions before partitioning. If it is an old hard disk, pay attention to whether you need to back up data. See
Create a swap partition. The swap partition is 1.5 to 2 times of the memory. If the system memory is greater than or equal to 16 GB, you can set the size of the SWAp to be the same as that of the memory. For example:
Set/boot partition to MB, as shown in:
Set the root partition to 50 GB, as shown in.
Set the data directory to allocate all the remaining space to the/Data Partition for storing logs, website data, and other data. For MySQL server, format the/data directory to XFS format, as shown in:
After the partition is complete, the conditions of each partition are as follows:
4. Advanced System Configuration
Select the default GRUB boot mode
Set the password when grub is started. Do not set it. Do not harm yourself. The default password is enough. See:
Select the start tag and partition. The default value is:
Select the disk where the boot loader is installed. The default value is:
Configure Nic information, such:
For eth0 to cancel IPv6 support, as shown in:
You can select DHCP to obtain or set a fixed IP address, for example:
Set the host name, as shown in:
Select the time zone and select the Asia/Chongqing time zone to keep the online server time zone consistent. For details, see:
We recommend that you set the root user's boot password to be more complex to meet the Password Complexity Requirements and enhance system security, for example:
5. Installation Package customization stage
Select a custom software package, as shown in:
Package Selection: select only the installation packages of administration tools/development libraries/development tools/system tools/Editors/server configuration tools.
6. Formal Installation
Select confirm to enter the formal installation phase, such:
The formal installation phase is as follows:
So far, the installation of the operating system has been completed!