Re-created the check_mem.sh script to make it RHEL6-compatible