"be consistent" | |
PerlMonks |
Regex to parse netstat outputby miller (Acolyte) |
on Feb 04, 2004 at 10:17 UTC ( [id://326452]=perlquestion: print w/replies, xml ) | Need Help?? |
miller has asked for the wisdom of the Perl Monks concerning the following question:
Hello, im trying write a little code that checks if a open is open but it do not seem to work for me, i hope you can help
The problem is if i pick a number like "94" it get also "9494" BUT cuts off the first part of the ip-addr, so : 228.132.245.9494 So how i can define make sure it: 1) only picks the ones that matches precisely the port nummer? 2) and why do it cut of the first part of the ip-addr ? the std output from a "netstat -an|grep 949"
The funny part ???
this looks right tho
Here is what i want:
EDIT::: Pasted the complete code and added some more stuff... This is really giving me a headache. EDIT:::
Thanks alot for the help. janitored by ybiC: Retitle from "Checking status of ports" for better searching, minor format cleanup for legibility
Back to
Seekers of Perl Wisdom
|
|