How to get the public ip of amazon sagemaker’s notebook instance? Is it possible?

Question:

Is it possible to get the public-ip of an amazon sagemaker notebook instance?

I was wondering if I can ssh into it using the public ip for remote debugging purposes.

I tried getting the public ip using the below curl command

This just lists the local ip and not the public ip.

I also tried the below command.

This returns an ip address like 13.232.96.15. If I try ssh into this it doesnt work.

Is there any other way we can do this?

Note : The ssh port 22 is open already in the security group

Answer:

I don’t think you can ssh to notebook instances. You can either use open them from the console, or grab the url with an API, re: https://docs.aws.amazon.com/sagemaker/latest/dg/howitworks-access-ws.html

If you need a terminal, then you can open one from Jupyter.

Leave a Reply