# Ysqlsh: could not connect to server: Connection refused

**URL:** <https://forum.yugabyte.com/t/ysqlsh-could-not-connect-to-server-connection-refused/848>\
**Category:** General\
**Created:** [October 27, 2020, 9:07am UTC](https://forum.yugabyte.com/t/ysqlsh-could-not-connect-to-server-connection-refused/848 "2020-10-27T09:07:39Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![karthikchennai](https://avatars.discourse-cdn.com/v4/letter/k/43a26b/32.png) [@karthikchennai](https://forum.yugabyte.com/u/karthikchennai)\
**Post date:** [October 27, 2020, 9:46am UTC](https://forum.yugabyte.com/t/ysqlsh-could-not-connect-to-server-connection-refused/848/3 "2020-10-27T09:46:04Z")

</div>

Hi Sebastian,  
I’m using the same command  
docker run -d --name yugabyte -p7200:7200 -p7000:7000 -p9000:9000 -p5433:5433 -p9042:9042 yugabytedb/yugabyte:latest bin/yugabyted start --daemon=false --ui=false

this worked for me yesterday. after updating my docker am facing this error.

C:\>docker run -d --name yugabyte -p7200:7200 -p7000:7000 -p9000:9000 -p5433:5433 -p9042:9042 yugabytedb/yugabyte:latest bin/yugabyted start --daemon=false --ui=false  
016d21df244918a5160a1cb02a903de8d049205fc2ad6f14333d5e5b3959e717

C:\>docker exec -it yugabyte /home/yugabyte/bin/ysqlsh --echo-queries  
ysqlsh: could not connect to server: Connection refused  
Is the server running on host “localhost” (127.0.0.1) and accepting  
TCP/IP connections on port 5433?  
could not connect to server: Cannot assign requested address  
Is the server running on host “localhost” (::1) and accepting  
TCP/IP connections on port 5433?

---

_[View the full topic](https://forum.yugabyte.com/t/ysqlsh-could-not-connect-to-server-connection-refused/848)._
