Skip to content

Commit

Permalink
mss: binary: swappiness: throw a warning if the command value is 0
Browse files Browse the repository at this point in the history
Signed-off-by: chickendrop89 <[email protected]>
  • Loading branch information
chickendrop89 committed Jul 19, 2024
1 parent c2ffff7 commit fd9ccd5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions system/bin/magiskswap
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,11 @@ case $COMMAND in

elif [ "$VALUE" -ge 0 ] && [ "$VALUE" -le 200 ];
then
if [ "$VALUE" -eq 0 ];
then
cprint "WARNING: Setting swappiness to 0 stops swapping to disk completely"
cprint "WARNING: Use this with caution, as OOM situations might occur"
fi
if [ "$VALUE" -gt 100 ];
then
cprint "WARNING: +100 swappiness is only compatible with Linux 5.7 and later"
Expand Down

0 comments on commit fd9ccd5

Please sign in to comment.