Monitor notebook instances on cloudwatch dashboard

0

Is there any way to get the details of all notebook instances on a cloudwatch dashboard in the below format

Notebook instance Name | Status | start time | up time

experiment_instance | inService | 2023-0630 9:10:00 am | 2.5 hrs

app_instance | Stopped | 2022-06-29 9:10:00 am | 1 hrs

Lak
已提問 10 個月前檢視次數 209 次
1 個回答
0

Hi Lak, To grab such details on SageMaker notebook instances, boto3 SageMaker client API, list_notebook_instances can be used. This API returns a list of notebook instances as below with their metadata as well.

{
    'NextToken': 'string',
    'NotebookInstances': [
        {
            'NotebookInstanceName': 'string',
            'NotebookInstanceArn': 'string',
            'NotebookInstanceStatus': 'Pending'|'InService'|'Stopping'|'Stopped'|'Failed'|'Deleting'|'Updating',
            'Url': 'string',
            'InstanceType': '',
            'CreationTime': datetime(2015, 1, 1),
            'LastModifiedTime': datetime(2015, 1, 1),
            'NotebookInstanceLifecycleConfigName': 'string',
            'DefaultCodeRepository': 'string',
            'AdditionalCodeRepositories': [
                'string',
            ]
        },
    ]
}
AWS
已回答 10 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南