• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login
Netgate Discussion Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login

Youtube not caching

Cache/Proxy
2
5
1.0k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S
    syfullah
    last edited by syfullah Sep 14, 2022, 5:32 PM Sep 14, 2022, 5:29 PM

    Dear all,

    I am new in pfsense, I have installed pfsense 2.6.0 + squid 0.4.45_8 and tried to cache youtube video by implementing https caching settings. However, i am able to cache youtube images and facebook contents but youtube video always shows TCP_MISS/200 for all youtube videos and does not hit any cache for repeated views in many times.
    I am using refresh_pattern as per https://forum.netgate.com/topic/172137/any-recommendations-this-custom-refresh_pattern
    but still no luck for youtube caching. Can anyone give me any idea about this ?

    Thanks

    G 1 Reply Last reply Sep 15, 2022, 9:18 AM Reply Quote 0
    • G
      Gertjan @syfullah
      last edited by Sep 15, 2022, 9:18 AM

      @syfullah

      Because Youtube does everything in their power (and they have the power) you not being able to cache 😊
      Youtube has their reasons of course, as they do not want to get "cloned", and I guess it also has to do with the fact they want to include 'publicly' when they see fit.

      See for example here : https://wiki.squid-cache.org/ConfigExamples/DynamicContent/YouTube
      Youtube also saw that article so they had the walk-through to make that impossible, as the article stated at the beginning.

      No "help me" PM's please. Use the forum, the community will thank you.
      Edit : and where are the logs ??

      S 1 Reply Last reply Sep 15, 2022, 9:49 AM Reply Quote 0
      • S
        syfullah @Gertjan
        last edited by Sep 15, 2022, 9:49 AM

        @gertjan thanks for your reply. I am bit concern how bmsoftware.org is caching youtube content as i have used their service and its works perfectly. Though, their charge is bit high thats why was wondering to use squid to cache youtube content. I also have seen 1/2 years back video shows that squid could cache youtube content in pfsense. Thats why wondering is there any custom work to do to cache youtube content on pfsense environment?

        G 1 Reply Last reply Sep 15, 2022, 12:29 PM Reply Quote 0
        • G
          Gertjan @syfullah
          last edited by Sep 15, 2022, 12:29 PM

          @syfullah said in Youtube not caching:

          wondering is there any custom work to do to cache youtube content on pfsense environment?

          Because :

          login-to-view

          bmsoftware.org probably took a proxy like squid, hired a programmer, as more then just 'configuration' has to be done.

          Each video request from youtube.com contains a non-random but changing argument next to the video name

          so every chunk of video has it's own constantly randomised file name.
          A browser based build in, video player just "plays" the chunk as they come in.
          Storing them, and then figuring out it which order to send them to a player, is total mission impossible for a machine, and a piece of cake for a human viewer.

          The key thing is : you must be more clever as the ones behind the Youtube video delivery engine.
          You pull this one of, and you'll receive an phone call from Google, and they will offer you a job that you can't turn down ;)

          Btw : I just highlight (kind-a) one scheme. They use more schemes. And they will change schemes all the time.

          No "help me" PM's please. Use the forum, the community will thank you.
          Edit : and where are the logs ??

          S 1 Reply Last reply Sep 15, 2022, 12:45 PM Reply Quote 1
          • S
            syfullah @Gertjan
            last edited by Sep 15, 2022, 12:45 PM

            @gertjan cheers mate thanks for the the clarification. I will try to get in deep on this will share here if get any outcome. Thanks again.

            1 Reply Last reply Reply Quote 0
            3 out of 5
            • First post
              3/5
              Last post
            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.