#!/bin/bash
#reading data from a file
count=1
cat ip.txt | while read line
do
echo "Line $count: $line"
line=${line%/*}
ip=${line#*/}
count=$[ $count + 1 ]
cat url.txt | while read line2
do
echo "$line2"
count=$[ $count + 1]
#curl -l "$line2" -d ""
echo "http://"$ip":8081/"$line $line2
done
done
echo finished processing the file
#!/bin/bash
url="https://www.baidu.com/s?wd="
for i in $(cat pro.txt); do
echo $i >> output.txt
content=$(curl $url$i)
for(( j=0; j< 100; j++)); do
echo $content >> output.txt
done
done
### output.txt 文本内容格式
aaa
bbb