Make grep call compatible across Linux versions