From c82dd14a8fa164bd58fdf715568e13fc7566e68c Mon Sep 17 00:00:00 2001 From: gau1991 Date: Wed, 5 Nov 2014 14:14:01 +0530 Subject: [PATCH] Fixed Swap file permission --- src/lib/ee_lib_swap.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/lib/ee_lib_swap.sh b/src/lib/ee_lib_swap.sh index 5f9edba0..f375afac 100644 --- a/src/lib/ee_lib_swap.sh +++ b/src/lib/ee_lib_swap.sh @@ -24,6 +24,11 @@ function ee_lib_swap() # Add entry into /etc/fstab echo "/ee-swapfile none swap sw 0 0" >> /etc/fstab \ || ee_lib_error "Unable to add entry into /etc/fstab, exit status = " $? + + # Change Permission for swapfile + chown root:root /ee-swapfile && + chmod 0600 /ee-swapfile \ + || ee_lib_error "Unable to change Swapfile permission, exit status = " $? fi fi }