# Step 1: Installing and Configuring OS and TiDB prerequisites

__*TiDB deployment steps*__
__*TiDB precheck*__
__*zz-BGL*__
__*zz-Jeff*__


+ Create file system for `TiKV`
+ Disable system `swap`
+ Turn off the firewall
+ Install `NTP`
+ Set `OS` parameters
+ Configure the `SSH` access
+ Install `numactl`
-------------------------------------------------------------
Before deploying `TiDB`. The following steps are ordered by priorities.

1. Mount the data disk `ext4` filesystem with options on the target machines that deploy `TiKV`.
2. Check and disable system `swap`.
  - TiDB needs sufficient memory space for operation. When memory is insufficient, using swap as a buffer might degrade performance. Therefore, it is recommended to disable the system swap permanently.
3. Check and stop the firewall service of target machines.
4. Check and install the `NTP` service.
  - Network Time Protocol (NTP) is a networking protocol for clock synchronization between computer systems. The latest versions of Amazon Linux 2 and Amazon Linux AMIs synchronize with the Amazon Time Sync Service by default.  
5. Check and configure the optimal parameters of the operating system.
6. Manually configure the `password-free` SSH mutual trust and sudo without password.
7. Install the `numactl` tool.
  - `numactl` runs processes with a specific NUMA scheduling or memory placement policy. 

For detailed and up-to-date guide for step 1, go to https://docs.pingcap.com/tidb/stable/check-before-deployment.