Help Center> ModelArts> DevEnviron> Managing Notebook Instances> Creating a Notebook Instance
Updated on 2023-12-08 GMT+08:00

Creating a Notebook Instance

Before developing a model, create a notebook instance and access it for coding.

Context

  • Only running notebook instances can be accessed or stopped.
  • A maximum of 10 notebook instances can be created under an account.

Procedure

  1. Log in to the ModelArts management console. In the navigation pane, choose Settings and check whether the access authorization has been configured. If not, configure access authorization. For details, see "Configuring Access Authorization".
    Figure 1 Configuring authorization
  2. Log in to the ModelArts management console. In the left navigation pane, choose DevEnviron > Notebook to switch to the new-version Notebook page.
  3. Click Create. On the Create Notebook page, configure parameters.
    1. Configure basic information of the notebook instance, including its name, description, and auto stop status. For details, see Table 1.
      Figure 2 Basic information of a notebook instance
      Table 1 Basic parameters

      Parameter

      Description

      Name

      Name of the notebook instance. Enter 1 to 64 characters. Only letters, digits, hyphens (-), and underscores (_) are allowed.

      Description

      Brief description of the notebook instance

      Auto Stop

      Automatically stops the notebook instance at a specified time. This function is enabled by default. The default value is 1 hour, indicating that the notebook instance automatically stops after running for 1 hour.

      The options are 1 hour, 2 hours, 4 hours, 6 hours, and Custom. You can select Custom to specify any integer from 1 to 24 hours.

    2. Configure notebook parameters, such as the image and instance flavor. For details, see Table 2.
      Table 2 Notebook instance parameters

      Parameter

      Description

      Image

      Public and private images are supported.

      • Public images are the AI engines built in ModelArts.
      • Private images can be created using an instance that is created using a public image. Custom images have not been officially released.

      An image corresponds to an AI engine. When you select an image during instance creation, the AI engine is specified accordingly. Select an image as required. Enter a keyword of the image name in the search box on the right to quickly search for the image.

      You can change an image on a stopped notebook instance.

      Resource Pool

      Select a resource pool as required.

      Type

      Chip type, which can be CPU or GPU.

      The chips vary depending on the selected image.

      Flavor

      The flavor of your notebook instance.

      Storage

      Default, EVS, and SFS can be selected.

      • Default

        If you select this option, the system provides 50 GB of default free storage for each notebook instance.

      • EVS

        Set disk space, ranging from 5 GB to 4096 GB, based on actual usage. The default value is 5 GB.

      • SFS, which is supported by dedicated resource pools only

      All the storage paths of Default, EVS, and SFS are mounted to /home/ma-user/work. All read and write operations on files in the notebook instance are stored in this directory, not in OBS.

      The data is retained in /home/ma-user/work, even if the notebook instance is stopped or restarted.

      When the notebook instance is deleted, the data is deleted accordingly.

      Remote SSH

      • After you enable this function, you can remotely access the development environment of the notebook instance from your local development environment.
      • When a notebook instance is stopped, you can update the SSH configuration on the instance details page.
      NOTE:

      The notebook instances with remote SSH enabled have VS Code plug-ins (such as Python and Jupyter) and the VS Code server package pre-installed, which occupy about 1 GB persistent storage space.

      Key Pair

      Set a key pair after remote SSH is enabled.

      Select an existing key pair.

      Alternatively, click Create on the right of the text box to create one on the DEW console. To do so, choose Key Pair Service > Private Key Pairs and click Create Key Pair.

      After a notebook instance is created, you can change the key pair on the instance details page.

      CAUTION:

      Download the created key pair and properly keep it. When you use a local IDE to remotely access the notebook development environment, the key pair is required for authentication.

      Whitelist

      Set a whitelist after remote SSH is enabled. This parameter is optional.

      Add the IP addresses for remotely accessing the notebook instance to the whitelist, for example, the IP address of your local PC or the public IP address of the source device. A maximum of five IP addresses can be added and separated by commas (,). If the parameter is left blank, all IP addresses will be allowed for remote SSH access.

      If your source device and ModelArts are isolated from each other in network, obtain the public IP address of your source device using a mainstream search engine, for example, by entering "IP address lookup", but not by running ipconfig or ifconfigip locally.

      After a notebook instance is created, you can change the whitelist IP addresses on the instance details page.

  4. Click Next.
  5. After confirming the parameter settings, click Submit.

    Switch to the notebook instance list. The notebook instance is being created. It will take several minutes when its status changes to Running. Then, the notebook instance is created.

  6. In the notebook instance list, click the instance name. On the instance details page that is displayed, view the instance configuration.
    Figure 3 Details about a notebook instance

    The SSH configuration of a stopped notebook instance can be modified. Both the key and whitelist can be modified.

    To modify the whitelist, click the modification icon on the right.