After writing the article How do I add a swap partition in Linux Centos on VPS VULTR was faced with the fact that some users are having difficulty with creating a swap file. Decided to write a little script, but rather a set of commands to fully automate the process. Automatically create swap file in […]
shell script to see occupancy swap process
#!/bin/bash echo -e ‘date +%y%m%d%H%M’ echo -e “PID\t\tSwap\t\tProc_Name” # Show all in the name of digital in/proc directory directories (the process name is the only process that other store other information such as sys,net) for pid in ‘ls -l /proc | grep ^d | awk ‘{ print $9 }’| grep -v [^0-9]’ do # Allow […]