mirror of
https://github.com/samba-team/samba.git
synced 2024-12-22 13:34:15 +03:00
ctdb: Do not use egrep
On some platforms, egrep prints a deprecation warning to stderr: egrep: warning: egrep is obsolescent; using grep -E Use grep -E instead. This is nice and simple, so no use splitting this commit into 2 separate commits for each of tools and test. Signed-off-by: Martin Schwenke <mschwenke@ddn.com> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
This commit is contained in:
parent
4deb178eb3
commit
862fc5770c
@ -39,7 +39,7 @@ get_src_socket ()
|
||||
|
||||
local pat="^${proto}6?[[:space:]]+[[:digit:]]+[[:space:]]+[[:digit:]]+[[:space:]]+[^[:space:]]+[[:space:]]+${dst_socket//./\\.}[[:space:]]+ESTABLISHED[[:space:]]+${pid}/${prog}[[:space:]]*\$"
|
||||
out=$(netstat -tanp |
|
||||
egrep "$pat" |
|
||||
grep -E "$pat" |
|
||||
awk '{ print $4 }')
|
||||
|
||||
[ -n "$out" ]
|
||||
|
@ -30,7 +30,7 @@ pat="ctdb_control error: 'ctdb_control to disconnected node'|ctdb_control error:
|
||||
for i in ip disable enable "ban 0" unban listvars ; do
|
||||
try_command_on_node -v 0 ! $CTDB $i -n $test_node
|
||||
|
||||
if egrep -q "$pat" "$outfile" ; then
|
||||
if grep -Eq "$pat" "$outfile" ; then
|
||||
echo "OK: \"ctdb ${i}\" fails with expected \"disconnected node\" message"
|
||||
else
|
||||
echo "BAD: \"ctdb ${i}\" does not fail with expected \"disconnected node\" message"
|
||||
|
@ -228,7 +228,7 @@ Showing software versions
|
||||
EOF
|
||||
show_all "uname -a"
|
||||
[ -x /bin/rpm ] && {
|
||||
show_all "rpm -qa | egrep 'samba|ctdb|gpfs'"
|
||||
show_all "rpm -qa | grep -E 'samba|ctdb|gpfs'"
|
||||
}
|
||||
[ -x /usr/bin/dpkg-query ] && {
|
||||
show_all "/usr/bin/dpkg-query --show 'ctdb'"
|
||||
|
Loading…
Reference in New Issue
Block a user