This topic describes common error codes for Real-Time Communication (RTC) and their solutions.
Client error codes
| Hexadecimal | Decimal | Fault Description | Causes | Solution |
| 0x01030101 | 16974081 | Invalid parameter | Invalid parameter. A field in AuthInfo is empty, or the timestamp is less than or equal to 0. | Check that all fields in AuthInfo are complete. |
| 0x01030204 | 16974340 | The operation is rejected in the current state | An internal SDK state error occurred. | Destroy the SDK instance and create a new one. |
| 0x01030304 | 16974596 | The stream to be published does not exist. | The local stream (video, screen, or audio) does not exist. | Call the publish method to ingest the stream again. |
|
| An error occurred with the stream to be published. | An error occurred with the local stream (video, screen, or audio). | Call the publish method to ingest the stream again. |
| 0x01030403 | 16974851 | The stream to be subscribed to does not exist. | The remote stream (video, screen, or audio) does not exist. | Confirm whether the remote user has stopped stream ingest. |
|
| An error occurred with the stream to be subscribed to. | An error occurred with the remote stream (video, screen, or audio). | Confirm whether the remote user has stopped stream ingest. |
|
| SDK initialization error. | An exception occurred during SDK initialization. | Check whether the SDK version is correct and whether any JAR packages are missing. |
| 0x01020204 | 16908804 | Join timeout | The request to join the channel timed out. | Check the network connectivity. |
| 0x0102020C | 16908812 | Signaling heartbeat timeout. | The heartbeat packet timed out. | Check the network connectivity. |
| 0x01020401 | 16909313 | Signaling request error. | An error occurred with the signaling request. | Check the network connectivity. |
|
| Signaling request timeout. | The signaling request timed out. | Check the network connectivity. |
| 0x02010201 | 33620481 | The AppId does not exist. | AppId does not exist. | Create an application in the console. |
| 0x02010202 | 33620482 | The AppId is invalid. | The application has been disabled. | Enable the application in the console. |
| 0x02010203 | 33620483 | The channel is invalid. | Failed to join the channel because the channel has expired. A channel is valid for 48 hours. | Generate a new channel authentication token. |
| 0x02010205 | 33620485 | The token is invalid. | Failed to join the channel because the token is invalid. | Generate a new channel authentication token. |
| 0x02010401 | 33620993 | Stream ingest was aborted. | The stream ingest was interrupted. | Call the publish method to ingest the stream again. |
| 0x02010402 | 33620994 | Stream subscription was aborted. | The stream subscription was interrupted. | Confirm whether the remote user has stopped stream ingest. |
| 0x02010403 | 33620995 | Failed to subscribe to the remote stream | Failed to subscribe to the remote stream because it is no longer being published. | None. |
| 0x01040404 | 17040388 | Failed to open the audio recording device, or the audio device is occupied | The capture device failed to initialize, the media service for the capture device is abnormal, or the audio device is in use. | On macOS and Windows, check whether the energy bar for the audio device is active in System Settings. On iOS and Android, confirm whether the device is in use by another application. If everything is normal, restart the device. |
| 0x01040405 | 17040389 | Failed to open the audio playback device, or the audio device is occupied | The playback device failed to initialize, the media service for the playback device is abnormal, or the audio device is in use. | On macOS and Windows, check whether the energy bar for the audio device is active in System Settings. On iOS and Android, confirm whether the device is in use by another application. If everything is normal, restart the device. |
| 0x01040406 | 17040390 | Audio recording error, or the audio device is occupied | Insufficient system performance, the media service for the capture device is abnormal, or the audio device is in use. | Restart the application or the device. |
| 0x01040407 | 17040391 | Audio playback error, or the audio device is occupied | Insufficient system performance, the media service for the playback device is abnormal, or the audio device is in use. | Restart the application or the device. |
| 0x01040408 | 17040392 | No audio recording permission | No microphone permission. | Go to System Settings to grant microphone permission, and then join the channel again. |
| 0x01040409 | 17040393 | No audio recording device found | The microphone device is abnormal. | Check whether an active microphone is connected. Then, check whether the device is disabled in System Settings. |
| 0x01040410 | 17040400 | No audio playback device found | The playback device is abnormal. | Check whether an active speaker or headset is connected. Then, check whether the device is disabled in System Settings. |
| 0x01040104 | 17039620 | Failed to open the camera due to no permission, or the camera is occupied | Failed to open the camera. The camera is unavailable or may be in use. | Check whether the system camera is available. On a mobile device, check whether another app is using the camera. |
| 0x01040106 | 17039622 | An error occurred during camera capture. | The camera is not working correctly. For example, on a macOS or Windows computer, the camera capture light turns off and the device is forcibly interrupted. | Join the channel again or restart the app. |
| 0x01040201 | 17039873 | Failed to open the rendering device | Failed to start video rendering. | On Windows, check whether the graphics card driver needs to be upgraded. On mobile devices, check whether the phone model, Android tablet, or other peripheral supports OpenGL. |
| 0x01040202 | 17039874 | An error occurred during rendering. | An exception occurred during video rendering. A system error caused the rendering engine to fail. | Join the channel again or restart the app. |
| 0x01050201 | 17105409 | Failed to create a media connection | Failed to establish a media channel. | Check the network connectivity. |
| 0x01050202 | 17105410 | Failed to reconnect the media connection | Failed to reconnect to the media channel. | Check the network connectivity. |
| 0x01060101 | 17170689 | Low performance detected. | Poor performance is detected. | Turn off CPU-intensive processes, such as retouching or video stream ingest. |
| 0x01060102 | 17170690 | Performance restored | Performance has recovered, and the application is running normally. | None. |
| 0x02010105 | 33620229 | Session has been removed | The session has been removed. | Destroy the instance, create a new one, and then join the channel. |
| 0x02010121 | 33620257 | H5 is not compatible | The client is not compatible because H5 compatibility mode is not enabled correctly. | Check whether H5 compatibility mode is enabled correctly. |
| 0x02010903 | 33622275 | Failed to join the channel due to an invalid channel profile | Failed to join the channel. | Verify that the user's join mode is consistent with the channel mode. |
| 0x01010302 | 16843522 | Failed to leave the channel because the user has already left. | ERROR_ROOM_LEAVING_NOW. The user was already leaving the channel when the API to leave the channel was called. | Wait for the session closing task to complete before you perform other operations. |
| 0X01010304 | 16843524 | Operation failed because the user is not in the channel. | ERROR_ROOM_NOT_IN_THE_CHANNEL. The user is not in the channel. | Join the channel before you perform operations related to stream ingest or stream pulling. |
|
| Failed to publish because a stream is already being published. | The user was already ingesting a stream when the stream ingest API was called. | Do not call the publish method repeatedly. You can also stop the current stream ingest before you call the publish method. |
| 0x01010402 | 16843778 | Operation failed because no stream is being published. | ERROR_PUBLISH_NOT_PUBLISHER. The user was not ingesting a stream when the API to stop stream ingest was called. | Do not call the API to stop stream ingest repeatedly. |
| 0x01010405 | 16843781 | The publish configuration is invalid. | ERROR_PUBLISH_CONFIG_IS_INVALID. The publish configuration is incorrect. | Check the publish configuration. |
| 0x01010501 | 16844033 | The subscribe configuration is invalid. | ERROR_SUBSCRIBE_CONFIG_IS_INVALID. The subscribe configuration is incorrect. | Check the subscribe configuration. |
| 0x01020110 | 16908560 | Failed to update role | SOPHON_RESULT_UPDATE_ROLE_ERROR. Failed to update the role. | Confirm the current channelProfile (channel type). If the mode is Communication, you do not need to set the ClientRole (role type). The role can be updated only when stream ingest is stopped. |
|
| Signaling request timeout. | The signaling request timed out. | Check the network connectivity. |
| 0x00000101 | 257 | Weak network. | SDK_WARNING_NETWORK_WEAK. The network quality is poor. | Check the network connectivity. |
| 0x00000102 | 258 | Network recovered. | SDK_WARNING_NETWORK_RECOVERY. The network has recovered. | None. |
| 0x00000103 | 259 | Network disconnected. | SDK_WARNING_LOCAL_NETWORK_DISCONNECT. The local network is disconnected. | Check the network connectivity. |
| 0x00000104 | 260 | Remote network disconnected. | SDK_WARNING_REMOTE_NETWORK_DISCONNECT. The remote user's network is disconnected. | None. |
| 0x00000105 | 261 | Local network connected. | SDK_WARNING_LOCAL_NETWORK_CONNECT. The local network connection has been restored. | None. |
| 0x00000106 | 262 | Remote network connected. | SDK_WARNING_REMOTE_NETWORK_CONNECT. The remote user's network connection has been restored. | None. |
| 0x01070101 | 17236225 | External audio input buffer is full | SDK_AUDIO_INPUT_BUFFER_FULL. During external audio input, the input frequency is too high, which causes the buffer to become full. | Reduce the external input frequency. Set a wait time of 20 ms and ensure that a single input does not contain more than 40 ms of data. |
| 0x0103030d | 16974605 | Failed to publish due to the wrong role | SDK_RESULT_PUBLISH_WRONG_ROLE_ERROR. A user with the viewer role cannot publish a stream. | Check the role of the current user. |
| 0x01090003 | 17367043 | Failed to open the media file | Failed to open the file. | Check whether the file path is correct and whether the file has read permission. |
| 0xFFFFFFFF | -1 | WARN_DEFAULT | Default alert information. | None. |
| 0x02010101 | 33620225 | Session Subscribe | The client failed to subscribe to the remote user. This may be because the remote user has not started or has stopped stream ingest. | Ensure that the subscribe API is called while the remote user is ingesting a stream. |
Error codes for joining a channel
| Hexadecimal | Decimal | Fault Description | Causes | Solution |
| 0x01010301 | 16843521 | Already joined. | The user has already joined the channel. | Check the API call logic. |
| 0x02010903 | 33622275 | Failed to join the channel due to an invalid channel profile | The channel profile does not match. For example, this error occurs if the first user joins in communication mode and a subsequent user tries to join in interactive mode. | Check whether the user's channel mode is the same as that of other users. |
| 0x05040002 | 84148226 | Channel overdue |
| Check the following:
|
| 0x02010702 | 33621762 | Failed to join the channel because the same user is trying to join again. Check whether another device is still in the channel. | The user failed to join the channel. For example, the same user is trying to join the same channel from two different devices, or the user's previous session has not completely ended. | Check the API call logic. |
| 0x02010104 | 33620228 | Session Join | The client left the channel and then tried to join again using the same session ID. | Join the channel again. |
| 0x02010204 | 33620484 | The channel does not exist. | Failed to join the channel because it does not exist. For example, the channel creator joined and then quickly left. When a second user tried to join, the channel no longer existed. | Join the channel again. |
| 0x05010011 | 83951633 | Failed to join the channel due to an invalid channel ID. | The channel ID in the Global Server Load Balancing (GSLB) request is invalid. For example, the channel ID cannot contain spaces. | Check the format of the channel ID. A channel ID can be 1 to 64 characters in length and can contain uppercase letters, lowercase letters, digits, underscores (_), and hyphens (-). |
| 0x05010012 | 83951634 | Failed to join the channel due to an invalid user ID. | The user ID in the GSLB request is invalid. | Join the channel again. |
| 0x0501001a | 83951642 | Failed to join the channel due to an invalid channel ID | The AppId is configured for large-scale channel mode. You must use a package of version 1.16.5 or later to join the channel. Otherwise, the join attempt will fail. | Check the SDK version. |
| 0x01020201 | 16908801 | Signaling request timeout. | A response to the GSLB request was not received in time, which caused a timeout. | Check the network connectivity. |
| 0x01020204 | 16908804 | Join timeout | A response to the join request was not received in time, which caused a timeout. | Check the network connectivity. |
| 0x01030202 | 16974338 | Join error | An error occurred while joining the channel. | Check whether the authentication information is correct and whether the network environment is normal. |
| 0x01030201 | 16974337 | GSLB error. | The gslb field in the AuthInfo parameter is incorrect. | Check whether the gslb field in AuthInfo is complete, or verify that AuthInfo can pass validation. |
Bypass live streaming error codes
| Hexadecimal | Decimal | Description | Causes | Solution |
| 0x01100001 | 17825793 | MPU task not found | A URL was not passed for the MPU task, or an attempt was made to stop a task that had already been stopped. | Check the URL passed when you update or stop the MPU task. Check whether you are trying to stop a task that is already stopped. |
| 0x01100002 | 17825794 | The MPU task already exists. | An attempt was made to start an MPU task that had already been started. | Check whether you are trying to start an MPU task that is already started. |
| 0x01100003 | 17825795 | Invalid MPU task parameter. | An invalid parameter was passed. | Check whether the passed parameter is valid or within the valid range. |
| 0x01100004 | 17825796 | MPU task internal error. | An internal SDK error occurred. This includes, but is not limited to, network errors and server-side errors. | Send the request again. |
| 0x01100005 | 17825797 | MPU task Real-Time Messaging Protocol (RTMP) server error. | The server-side RTMP service failed to initialize, or a resource failed to download. | Check the validity of the resource link in the MPU task. |
| 0x01100006 | 17825798 | MPU task RTMP stream error. | An error occurred with the server-side RTMP stream. | Check whether the format of the RTMP stream URL is correct and valid. |
| 0x01100007 | 17825799 | MPU task publish timeout. | The server-side stream ingest timed out. | Send the request again. |
Cross-channel stream ingest error codes
| Hexadecimal | Decimal | Description | Cause Analysis | Solution |
| 0x01200001 | 18874369 | Channel relay state error. | The user has not joined the channel, the role is incorrect, or the channel mode is incorrect. | Check the join status. Ensure that the current mode is interactive and that the role is streamer. |
| 0x01200002 | 18874370 | The specified channel relay source is not permitted. | The channel mode is incorrect for cross-channel stream ingest. | Switch to interactive mode or low-latency interactive stream mode. |
| 0x01200003 | 18874371 | Failed to join the destination channel for relay. | During cross-channel stream ingest, the destination channel does not exist, or the destination channel and the source channel are not in the same channel mode. | When you ingest a stream across channels, check whether the destination channel exists. Ensure that the destination channel and the source channel are in the same mode, such as interactive mode. |
| 0x01200005 | 18874373 | Channel relay role error. | The role is incorrect for cross-channel stream ingest. | Switch the role to streamer. |
| 0x01200006 | 18874374 | Channel relay invalid parameter. | The passed parameter is invalid. | Check whether the passed parameter is valid or within the valid range. |
| 0x01200007 | 18874375 | Channel relay to self error. | The destination channel ID is the same as the source channel ID. | Enter the correct destination channel ID. The destination channel ID cannot be the same as the source channel ID. |
Cross-channel stream pulling error codes
| Hexadecimal | Decimal | Description | Cause | Solution |
| 0x01300001 | 19922945 | Channel relay subscription request error. | A parameter in the request contains an invalid character or has an invalid format. | Check the format and validity of the request parameters. |
| 0x01300002 | 19922946 | Channel relay subscription request timeout. | The cross-channel stream pulling request timed out. | Try to send the request again. |
| 0x01300003 | 19922947 | Channel Relay: Sub-server Timeout | The destination channel was not created within the specified time, which caused a timeout. | Ensure that the destination channel has been created. Try to send the request again. |
该文章对您有帮助吗?