Getting started

Last Updated: Oct 21, 2017

Live activity procedure

2

Both streaming and playing operations are performed at the PC end. For streaming opeartion at the mobile end, refer to Android streaming and iOS streaming. For playing at the mobile end, refer to Android playing and iOS playing.

Step 1: Preparation

Prerequisites

  • Your domain name has completed the website record-filing.

  • To begin a live activity, you need streaming tools to upload the live video, and playing tools to pull the live video.

Procedure

  1. Log on to the ApsaraVideo Live console.

    The console checks the activation status of services on which the product is dependent. Follow the instructions on the page for operations.

  2. Add a live video domain name.

    1. Select a region, and click Add New Domain.

      1

    2. Enter the Live domain name, and click Next step.

      domain

      1

    • We recommend the domain name for live video completes ICP record filing before it is readied for use. See Record filing process for details.

    • When configured successfully, the domain name automatically completes the configuration of CDN live acceleration. The live acceleration is available after the domain name complete the CNAME binding.

  3. Bind CNAME.

    Modify the DNS and CNAME record of the live video domain name you added to the CNAME address displayed on the live video domain name management details page. Then, bind the streaming address that Alibaba Cloud provides with the live video domain name, so that the stream is pushed to the live video center at the same time it is pushed to the live video domain name. To bind the CNAME address of the domain name, follow these steps.

    • Get the live video domain name applied for at www.net.cn

      1. Get the CNAME corresponding to the live video domain name of the Live Video console.

        3

      2. Log on to the Domain console and, on the Domain Name List page, select the domain name, and click Resolve.

        2

      3. Click Configure.

        config

      4. Click Add Record.

        2

      5. Enter the resolution parameters and click Confirm.

        2

      6. Select CNAME in Type.

        • Enter the secondary domain name of the streaming address in Host. For example, if the streaming address is document4.aliyun.com, then the secondary domain name is document4.

        • Enter the CNAME content into Value in the domain name list.

          • If it is a newly created domain name, the resolution will not involve DNS refreshing.
          • If the CNAME is changed, different data is cached on different DNSs. If this occurs, it may take up to 48 hours to complete the updates.
    • Alternative domain name application method

      • If the domain name is applied for using another method, you must perform CNAME binding at the website at which the domain name is added.

      • Perform a domain name transfer on the Alibaba Cloud console.

  4. Configure authentication.

    1. Log on to the ApsaraVideo Live console.

    2. Click Domains in the left-side navigation pane,

    3. Select a region.

    4. Select the domain name, and click Detail on the right side.

      2

    5. Click Authenticate.

      2

    6. Enable Auth function.

      2

    7. Enter the Main KEY and Standby KEY and click OK.

      2

      Note:

      • Main KEY is a key for calculating encrypted string. It is a mandatory item.
      • If the main KEY is changed, all addresses using the main KEY will instantly become invalid. If the standby KEY is switched to become the main KEY, the streaming or playback address using the main KEY will not become invalid instantly, but will instead use the standby KEY as a mechanism for performing the switch.
    8. Enter the stream URL in Authentication URL Calculator.

      You can get the stream URL in the Base Information tab.

      rtmp://video-center.alivecdn.com/AppName/StreamName?vhost=document4.aliyun.com

      • The video-center.alivecdn.com is a server of the live video center and can be customized. For example, if your domain name is document4.aliyun.com, you can set the DNS and point your domain name CNAME to “video-center.alivecdn.com”.
      • AppName is the app name. This parameter can be customized.
      • StreamName is the stream name. This parameter can be customized.
      • The “vhost” parameter specifies a domain name for eventual playback on an edge node, namely your live video CDN domain name.

        Note: If you want to use a customized AppName and StreamName, you must change the AppNameand StreamName in the streaming address into the app name and stream name you defined before generating the authenticated URL.

      2

      2

    9. Enter the main KEY and standby KEY required in authentication.

    10. Enter the expiry time of the stream URL.

      Authentication will be invalid if it exceeds the expire time.

    11. Click Generate.

    12. Click Base Information to get the play information.

      4

Step 2: Streaming

The live video streaming operation can use third-party streaming software.

Step 3: Playing

  • Preview directly at the backstage of the Web page

    1. Use OBS for streaming by using the authenticated URL, and then log on to the ApsaraVideo Live console > Streams.

    2. Select the region.

    3. Select the domain name.

    4. Select the stream status.

    5. Select the address, and click Address at the right side.

      You can then check playback address and verify play.

      3

      2

  • Preview with VLC

    Download VLC. Only a default installation is required, no additional configuration is required. Click Media > Open Network Stream, enter the playback address, and click Play.

Thank you! We've received your feedback.