Comment 2 for bug 1007554

Revision history for this message
Baron Schwartz (baron-xaprb) wrote : Re: [Bug 1007554] Re: XtraDB cluster does not properly detect bonded network interfaces

The sed command suggested in the last comment may not be completely
reliable and portable. I've found that sed works differently in some
cases with respect to regex patterns and so forth. The command doesn't
work on my laptop, for example.

Perl might actually be a better tool for this case:

/sbin/ifconfig | perl -e
'$/="";while(<>){$_!~m/LOOPBACK/&&/UP.*RUNNING/&&s/^.*addr:(\S+).*$/$1/s&&print
$_, "\n"}'