# Obtain the output with robotframework of SSH session

**URL:** <https://forum.robotframework.org/t/obtain-the-output-with-robotframework-of-ssh-session/6115>\
**Category:** SSHLibrary\
**Created:** [22 August 2023 14:04 UTC](https://forum.robotframework.org/t/obtain-the-output-with-robotframework-of-ssh-session/6115 "2023-08-22T14:04:46Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![damies13](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/damies13/32/623_2.png) [@damies13](https://forum.robotframework.org/u/damies13)\
**Post date:** [23 August 2023 00:37 UTC](https://forum.robotframework.org/t/obtain-the-output-with-robotframework-of-ssh-session/6115/5 "2023-08-23T00:37:42Z")

</div>

Hi Carlos,

Sorry I made a mistake (That’s what I get for replying to posts at 1am 😆 )

You need `return_rc=True` not `return_stderr=True`

Here’s an example:

```python
***Test Cases***
Carlos Pitero 1
  Open Connection ${IP}
  Login ${User} ${Password}
  ${output} ${rc}= Execute Command ifconfig return_rc=True
  Log ${rc}
  IF ${rc} == 0
    Log command has been executed with success
  ELSE
    Log command failed with error level ${rc}
  END
  Log ${output}
  Close Connection

```

 ![image](https://europe1.discourse-cdn.com/flex005/uploads/robotframework1/original/2X/2/2604e89d8ff3854bac2d75a5fdf35fd97ef4084c.png)

Dave.

---

_[View the full topic](https://forum.robotframework.org/t/obtain-the-output-with-robotframework-of-ssh-session/6115)._
