DX Infrastructure Manager

Expand all | Collapse all

Regex Multiple Lines

  • 1.  Regex Multiple Lines

    Posted 02-19-2010 09:50 PM
    I'm trying to match a target string that consists of multiple lines, but
    I don't know how to do it within the confined space of the one line
    allocated to me when configuring an AO.

    Any ideas
    would be greatly appreciated

    Thanks
    --Itsik

    P.S.
    \r
    does not work


  • 2.  Regex Multiple Lines

    Posted 02-19-2010 10:13 PM
    Have you tried \n?  That is the usual convention to represent a newline character.

    -Keith


  • 3.  Regex Multiple Lines

    Posted 02-19-2010 10:32 PM
    I have tried \n as well. No luck there either.



  • 4.  Regex Multiple Lines

    Posted 02-20-2010 01:27 AM
    I just realized that the reason I thought it wasn't working was because the test alert was not allowing me to paste the entire error message that consisted of multiple lines, therefore was not a match for the AO's regex string.

    Thanks for stepping forward and trying to help Keith!





  • 5.  Regex Multiple Lines

    Posted 02-20-2010 01:54 AM
    This regex matches fine in the NAS but in SDP message filter it does not.

    MSN: (vmware) The CPU for msnesx.msncomm2.com.Resources.CPUOverallUsage on172.31.2.48:443 is outside expected limits (3137 > 3000)

    /.*172.31.2.48*./


  • 6.  Regex Multiple Lines

    Posted 03-05-2010 10:33 PM
    This regex matches fine in the NAS but in SDP message filter it does not.

    MSN: (vmware) The CPU for msnesx.msncomm2.com.Resources.CPUOverallUsage on172.31.2.48:443 is outside expected limits (3137 > 3000)

    /.*172.31.2.48*./
    ----

    you should try and change the end of your regex to ".*" (dot star) not "*." (star dot).  The "." in regex means match one char and normally not a new line.  Also, you should escape the periods between the octets of IP because your want to say match the period not a single char between 172 and 31.

    try:  /.*172\.31\.2\.48.*/