#!/bin/bash

aramatarama ()
{
	local mesaj="$1"
	local port="$2"
	sayac=0
	while (( ${#list[@]} > sayac ))
	do
		if (( $(jobs -p | wc -l) > 150 ))
		then
			sleep 5s
			continue
		fi
		echo -n $mesaj |  nc -w 5 ${list[sayac]} $port &
		let "sayac = sayac + 1"
	done
}


list=(192.168.1.{1..255})
list=(192.168.{1..255}.{1..255})
aramatarama "Merhaba Beni BUL adim GARAVEL" "6677"

exit
Categories: Bash language

1 Comment

rich89bet · 14/01/2025 at 06:55

… [Trackback]

[…] Read More Information here on that Topic: durukanbal.com/2022/04/14/bash-send-message-ip-range/ […]

Leave a Reply

Avatar placeholder