Steps: 1) Turnoff Current Swap Device 2) Make Swap Device by fallocate and filling zeros 3) change mount permission to root only 4) swapon newly created mount. Example:- login as: root root@10.0.0.65's password: Last login: Mon Oct 4 02:29:55 2021 from mmd-12713385543 [root@ol7-19 ~]# swapoff -v /dev/mapper/ol-swap swapoff /dev/mapper/ol-swap [root@ol7-19 ~]# fallocate -l 4G /swape [root@ol7-19 ~]# dd if=/dev/zero of=/swape bs=1024 count=4194304 4194304+0 records in 4194304+0 records out 4294967296 bytes (4.3 GB) copied, 16.5165 s, 260 MB/s [root@ol7-19 ~]# ls ltr / ls: cannot access ltr: No such file or directory /: bin boot dev etc home lib lib64 media mnt opt proc root run sbin srv swape sys tmp u01 u02 usr var [root@ol7-19 ~]# ls -ltr / total 8388576 drwxr-xr-x. 2 root root ...