You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
riskshell/shell/savePid

18 lines
269 B

4 years ago
#!/bin/sh
4 years ago
#保存应用进程pid
4 years ago
echo "findPort $1"
while true
do
pid=`findPortPid $1`
if [ -z $pid ]
then
echo "pid not found!!!"
sleep 1s
else
echo "pid is $pid"
touch $pid.log && chmod +x $pid.log
break
fi
done