Hi Thanks for the awesome work, i just fresh install the demo when i start both server and client, and i connected 2 users with different browsers, and it , Users are visible to each other, but audio video not working between then
Logs : Client
and Server Logs
0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48116071, type: 'bwe' }] +795ms
mediasoup-demo-server:Room transport "trace" event [transportId:d2091a94-58ce-4155-9b4f-e99508712ca7, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48117281, type: 'bwe' }] +1s
mediasoup-demo-server:Room transport "trace" event [transportId:f09f20b8-ab2a-42e1-8f12-46f74e588aaf, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48118081, type: 'bwe' }] +800ms
mediasoup-demo-server:Room transport "trace" event [transportId:d2091a94-58ce-4155-9b4f-e99508712ca7, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48119293, type: 'bwe' }] +1s
mediasoup-demo-server:Room transport "trace" event [transportId:f09f20b8-ab2a-42e1-8f12-46f74e588aaf, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48120098, type: 'bwe' }] +805ms
mediasoup:Worker getResourceUsage() +2m
mediasoup:Channel request() [method:worker.getResourceUsage, id:82] +2m
mediasoup:Channel request succeeded [method:worker.getResourceUsage, id:82] +4ms
mediasoup-demo-server:INFO mediasoup Worker resource usage [pid:31463]: { ru_idrss: 0, ru_inblock: 0, ru_isrss: 0, ru_ixrss: 0, ru_majflt: 0, ru_maxrss: 14424, ru_minflt: 5110, ru_msgrcv: 0, ru_msgsnd: 0, ru_nivcsw: 0, ru_nsignals: 0, ru_nswap: 0, ru_nvcsw: 0, ru_oublock: 0, ru_stime: 281, ru_utime: 187 } +2m
mediasoup:Worker getResourceUsage() +40ms
mediasoup:Channel request() [method:worker.getResourceUsage, id:1] +33ms
mediasoup:Channel request succeeded [method:worker.getResourceUsage, id:1] +14ms
mediasoup-demo-server:INFO mediasoup Worker resource usage [pid:31465]: { ru_idrss: 0, ru_inblock: 0, ru_isrss: 0, ru_ixrss: 0, ru_majflt: 0, ru_maxrss: 8908, ru_minflt: 2287, ru_msgrcv: 0, ru_msgsnd: 0, ru_nivcsw: 0, ru_nsignals: 0, ru_nswap: 0, ru_nvcsw: 0, ru_oublock: 0, ru_stime: 46, ru_utime: 0 } +49ms
mediasoup:Worker getResourceUsage() +45ms
mediasoup:Channel request() [method:worker.getResourceUsage, id:1] +31ms
mediasoup:Channel request succeeded [method:worker.getResourceUsage, id:1] +32ms
mediasoup-demo-server:INFO mediasoup Worker resource usage [pid:31467]: { ru_idrss: 0, ru_inblock: 0, ru_isrss: 0, ru_ixrss: 0, ru_majflt: 0, ru_maxrss: 8912, ru_minflt: 2290, ru_msgrcv: 0, ru_msgsnd: 0, ru_nivcsw: 0, ru_nsignals: 0, ru_nswap: 0, ru_nvcsw: 0, ru_oublock: 0, ru_stime: 62, ru_utime: 0 } +63ms
mediasoup:Worker getResourceUsage() +54ms
mediasoup:Channel request() [method:worker.getResourceUsage, id:1] +22ms
mediasoup:Channel request succeeded [method:worker.getResourceUsage, id:1] +45ms
mediasoup-demo-server:INFO mediasoup Worker resource usage [pid:31469]: { ru_idrss: 0, ru_inblock: 0, ru_isrss: 0, ru_ixrss: 0, ru_majflt: 0, ru_maxrss: 8916, ru_minflt: 2290, ru_msgrcv: 0, ru_msgsnd: 0, ru_nivcsw: 0, ru_nsignals: 0, ru_nswap: 0, ru_nvcsw: 0, ru_oublock: 0, ru_stime: 78, ru_utime: 0 } +73ms
mediasoup-demo-server:INFO:Room logStatus() [roomId:pdqax3ww, protoo Peers:2, mediasoup Transports:5] +2m
mediasoup-demo-server:Room transport "trace" event [transportId:d2091a94-58ce-4155-9b4f-e99508712ca7, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48121301, type: 'bwe' }] +1s
mediasoup-demo-server:Room transport "trace" event [transportId:f09f20b8-ab2a-42e1-8f12-46f74e588aaf, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48122104, type: 'bwe' }] +802ms
mediasoup-demo-server:Room transport "trace" event [transportId:d2091a94-58ce-4155-9b4f-e99508712ca7, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48123316, type: 'bwe' }] +1s
mediasoup-demo-server:Room transport "trace" event [transportId:f09f20b8-ab2a-42e1-8f12-46f74e588aaf, trace.type:bwe, trace:{ direction: 'out', info: { availableBitrate: 1000000, desiredBitrate: 0, effectiveDesiredBitrate: 0, maxBitrate: 1000000, maxPaddingBitrate: 0, minBitrate: 30000, startBitrate: 1000000, type: 'transport-cc' }, timestamp: 48124116, type: 'bwe' }] +801ms
and this is my config.js
/**
* IMPORTANT (PLEASE READ THIS):
*
* This is not the "configuration file" of mediasoup. This is the configuration
* file of the mediasoup-demo app. mediasoup itself is a server-side library, it
* does not read any "configuration file". Instead it exposes an API. This demo
* application just reads settings from this file (once copied to config.js) and
* calls the mediasoup API with those settings when appropriate.
*/
const os = require("os");
module.exports = {
// Listening hostname (just for `gulp live` task).
domain: process.env.DOMAIN || "localhost",
// Signaling settings (protoo WebSocket server and HTTP API server).
https: {
listenIp: "0.0.0.0",
// NOTE: Don't change listenPort (client app assumes 4443).
listenPort: process.env.PROTOO_LISTEN_PORT || 4443,
// NOTE: Set your own valid certificate files.
tls: {
cert: process.env.HTTPS_CERT_FULLCHAIN || `${__dirname}/cert/cert.pem`,
key: process.env.HTTPS_CERT_PRIVKEY || `${__dirname}/cert/key.pem`,
},
},
// mediasoup settings.
mediasoup: {
// Number of mediasoup workers to launch.
numWorkers: Object.keys(os.cpus()).length,
// mediasoup WorkerSettings.
// See https://mediasoup.org/documentation/v3/mediasoup/api/#WorkerSettings
workerSettings: {
logLevel: "warn",
logTags: [
"info",
"ice",
"dtls",
"rtp",
"srtp",
"rtcp",
"rtx",
"bwe",
"score",
"simulcast",
"svc",
"sctp",
],
rtcMinPort: process.env.MEDIASOUP_MIN_PORT || 40000,
rtcMaxPort: process.env.MEDIASOUP_MAX_PORT || 49999,
},
// mediasoup Router options.
// See https://mediasoup.org/documentation/v3/mediasoup/api/#RouterOptions
routerOptions: {
mediaCodecs: [
{
kind: "audio",
mimeType: "audio/opus",
clockRate: 48000,
channels: 2,
},
{
kind: "video",
mimeType: "video/VP8",
clockRate: 90000,
parameters: {
"x-google-start-bitrate": 1000,
},
},
{
kind: "video",
mimeType: "video/VP9",
clockRate: 90000,
parameters: {
"profile-id": 2,
"x-google-start-bitrate": 1000,
},
},
{
kind: "video",
mimeType: "video/h264",
clockRate: 90000,
parameters: {
"packetization-mode": 1,
"profile-level-id": "4d0032",
"level-asymmetry-allowed": 1,
"x-google-start-bitrate": 1000,
},
},
{
kind: "video",
mimeType: "video/h264",
clockRate: 90000,
parameters: {
"packetization-mode": 1,
"profile-level-id": "42e01f",
"level-asymmetry-allowed": 1,
"x-google-start-bitrate": 1000,
},
},
],
},
// mediasoup WebRtcTransport options for WebRTC endpoints (mediasoup-client,
// libmediasoupclient).
// See https://mediasoup.org/documentation/v3/mediasoup/api/#WebRtcTransportOptions
webRtcTransportOptions: {
listenIps: [
{
ip: process.env.MEDIASOUP_LISTEN_IP || "127.0.0.1",
announcedIp: process.env.MEDIASOUP_ANNOUNCED_IP || "127.0.0.1",
},
],
initialAvailableOutgoingBitrate: 1000000,
minimumAvailableOutgoingBitrate: 600000,
maxSctpMessageSize: 262144,
// Additional options that are not part of WebRtcTransportOptions.
maxIncomingBitrate: 1500000,
},
// mediasoup PlainTransport options for legacy RTP endpoints (FFmpeg,
// GStreamer).
// See https://mediasoup.org/documentation/v3/mediasoup/api/#PlainTransportOptions
plainTransportOptions: {
listenIp: {
ip: process.env.MEDIASOUP_LISTEN_IP || "127.0.0.1",
announcedIp: process.env.MEDIASOUP_ANNOUNCED_IP || "127.0.0.1",
},
maxSctpMessageSize: 262144,
},
},
};
Thanks for the help,