Fix grep pattern for beam process

Fixes  #226.