Execute command not always working