def METHOD_NAME( pattern ):
    "Reliably terminate processes matching a pattern (including args)"
    sh( 'pkill -9 -f %s' % pattern )
    # Make sure they are gone
    while True:
        try:
            pids = co( [ 'pgrep', '-f', pattern ] )
        except CalledProcessError:
            pids = ''
        if pids:
            sh( 'pkill -9 -f %s' % pattern )
            time.sleep( .5 )
        else:
            break