Posts Tagged ‘bash’

Parsing logs for TOP IPs (Potentially BOT , brutforce , etc .)

Bash File Testing

Posted: 2nd July 2014 by admin in Trick
Tags: , ,

Bash File Testing: -b filename – Block special file -c filename – Special character file -d directoryname – Check for directory existence -e filename – Check for file existence -f filename – Check for regular file existence not a directory -G filename – Check if file exists and is owned by effective group ID. -g filename – true if file exists and […]

Backup Script,Bash

Posted: 1st July 2014 by admin in code
Tags: , , , , ,

Here is bash script that do a backup of source folders(Can be multiply : ""/root" "/var"") Backups are store for 7 days, 2 weeks backup and 2 month backup and rotated as well. Change it upgrade it use it =)

bash , you are awesome!

Posted: 17th June 2014 by admin in Trick
Tags: ,

Hey sorry for Russian,I’ll try to translate this manual later.It awesome linux bash tricks! 1. Простой способ перехватить вывод и ошибки Хотите направить stdout и stderr в один файл? command &> file Может вы разбираетесь в некой программе при помощи strace, и желали бы видеть системные вызовы вместе с ошибками программы? strace badapp &> errors_and_output […]

Log Encryption Script

Posted: 15th May 2014 by admin in all
Tags: , ,

Here is simple Bash script help to Encrypt your servers log files . On this moment script can perform encryption operation only on non-live files (already rotated) So here is : #!/bin/bash #Encrytion Script for Log Files set -x while true; do #rm FILE_LIST1 # Rotation of file list changes #Lets find files that we […]