title: In video.js, how to solve the buffering problem by using playlist.m3u8 file format
body: <p>I can't find my solution. I am going to play the playlist.m3u8 file with video tag of html5 in my website.</p>
  
  <p>Below is my javascript code.</p>
  
  <pre><code>&lt;html&gt;
      &lt;body&gt;
          &lt;video id="my-video" class="video-js" autoplay preload="auto" muted="false"&gt;
          &lt;/video&gt;
      &lt;/body&gt;
  
  &lt;link href="https://vjs.zencdn.net/7.4.1/video-js.css" rel="stylesheet"&gt;
  &lt;script src="https://vjs.zencdn.net/7.4.1/video.js"&gt;&lt;/script&gt;
  &lt;script&gt;
      var myPlayer = videojs('my-video'); 
      myPlayer.src('https://5bf6159570fba.streamlock.net/Bwin/Horses_0/playlist.m3u8');
      myPlayer.play();
  &lt;/script&gt;
  </code></pre>
  
  <p>And at regular intervals i use the myPlayer.reset() function.</p>
  
  <p>Contents of playlist.m3u8 file is below.</p>
  
  <pre><code>#EXTM3U
  #EXT-X-VERSION:3
  #EXT-X-STREAM-INF:BANDWIDTH=2566576,CODECS="avc1.66.30,mp4a.40.2",RESOLUTION=960x540
  chunklist_w1328950476.m3u8
  </code></pre>
  
  <p>Contents of chunklist_w1328950476.m3u8 file is below.</p>
  
  <pre><code>#EXTM3U
  #EXT-X-VERSION:3
  #EXT-X-TARGETDURATION:2
  #EXT-X-MEDIA-SEQUENCE:1
  #EXTINF:2.0,
  media_w1328950476_1.ts
  #EXTINF:2.0,
  media_w1328950476_2.ts
  #EXTINF:2.0,
  media_w1328950476_3.ts
  </code></pre>
  
  <p>If i run above code, the following error codes are dislayed at console.</p>
  
  <pre><code>video.js:142 VIDEOJS: ERROR: DOMException: Failed to set the 'duration' property on 'MediaSource': 
  The 'updating' attribute is true on one or more of this MediaSource's SourceBuffers.
  at HtmlMediaSource.addSeekableRange_ (https://vjs.zencdn.net/7.4.1/video.js:49141:44)
  at addSeekableRange (https://vjs.zencdn.net/7.4.1/video.js:55039:36)
  at PlaylistLoader.&lt;anonymous&gt; (https://vjs.zencdn.net/7.4.1/video.js:55054:15)
  at PlaylistLoader.data.dispatcher (https://vjs.zencdn.net/7.4.1/video.js:1818:33)
  at trigger (https://vjs.zencdn.net/7.4.1/video.js:1954:27)
  at PlaylistLoader.EventTarget.trigger (https://vjs.zencdn.net/7.4.1/video.js:2432:5)
  at PlaylistLoader.haveMetadata (https://vjs.zencdn.net/7.4.1/video.js:39151:14)
  at https://vjs.zencdn.net/7.4.1/video.js:39089:17
  at Object.callback (https://vjs.zencdn.net/7.4.1/video.js:40086:9)
  at cbOnce (https://vjs.zencdn.net/7.4.1/video.js:7220:17)
  </code></pre>
  
  <p>And Status of media_w1328950476_6.ts file is <strong>(cancelled)</strong>.</p>
  
  <p>I would appreciate it if you could find a solution to this problem as soon as possible.</p>
  
  <p>Thanks for your time and attention</p>