Make sure that you don’t have one of the buggy Asterisk versions.
Otherwise, when it happens again, check whether the extension is unreachable, or all extensions go unreachable.