Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.
#!/bin/bash UPLOAD_DIR=/home/usera/*.csv for FILE in `find $UPLOAD_DIR -maxdepth 1 -type f -mmin -10` # find the file created in past 10 minutes do echo $FILE lsof $FILE # check if the file still lock by any process LOCK=$? if [ "$LOCK" -ne "0" ] # if the file is free then cp $FILE /var/lib/mysql/test/$FILE #copy the file to another folder fi done
is evaluating as this:
cp $FILE /var/lib/mysql/test/$FILE
cp /home/usera/Import2SQL.csv /var/lib/mysql/test//home/usera/Import2SQL.csv
|Exchange 2010 get-mailbox and get-mailboxstatistics||10||160|
|PHP/REGEX: Where file names do not have underscore with glob||8||45|
|create a gui in perl||3||42|
|Split string on commas but not when enclosed in parentheses||7||23|
Join the community of 500,000 technology professionals and ask your questions.
Connect with top rated Experts
13 Experts available now in Live!