I have process id in a file "pid" I'd like to kill it.
Something like:
kill -9 <read pid from file>
I tried:
kill -9 `more pid`
but it does not work. I also tried xargs
but can't get my head around it.
Does
kill -9 $(cat pid)
work for you?
Let me summarize all answers
kill -9 $(cat pid)
kill -9 `cat pid`
cat pid | xargs kill -9
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With