DNS Redirect to Lancache

Hello i used Pihole with my Lancache in Version 5.x and it worked.
I put a 02-Cache.conf File under the same directory as "/etc/dnsmasq.d/01-pihole.conf"

Now in V6 there is no 01-pihole.conf

So how could i redirect the Urls from the Cache Server in Pihole?

Old file looks like this:

"# Riot Games

server=/l3cdn.riotgames.com/192.168.1.245
server=/worldwide.l3cdn.riotgames.com/192.168.1.245
server=/riotgamespatcher-a.akamaihd.net/192.168.1.245
server=/riotgamespatcher-a.akamaihd.net.edgesuite.net/192.168.1.245
server=/*.dyn.riotcdn.net/192.168.1.245
"

Thank you.

You have two easily accessible options with v6.0:

1. Keep your file and re-enable it

Make sure your 02-Cache.conf file is the only remaining file in /etc/dnsmasq.d and set the option misc.etc_dnsmasq_d to true.

You can either do this on the web interface (see Settings -> All settings on settings level "Expert") or from the CLI using

sudo pihole-FTL --config misc.etc_dnsmasq_d true

If there are no conflicting files in /etc/dnsmasq.d it should immediately start working.

2. Add custom dnsmasq config lines without a file

Pi-hole v6.0 has a new option called misc.dnsmasq_lines which can be used to add a series of config lines just as the one you mentioned above.

It can similarly be reached via the "All settings" page (one per line) or alternatively on the CLI formatted as JSON array (one line = one entry), like

sudo pihole-FTL --config misc.dnsmasq_lines '["server=/l3cdn.riotgames.com/192.168.1.245", "server=/l3cdn.riotgames.com/192.168.1.245","server=/l3cdn.riotgames.com/192.168.1.245", "server=/riotgamespatcher-a.akamaihd.net.edgesuite.net/192.168.1.245", "server=/riotgamespatcher-a.akamaihd.net.edgesuite.net/192.168.1.245"]'

It should start working immediately, too. No need for extra restarting FTL or something.

# Steam Cache

server=/lancache.steamcontent.com/192.168.1.245

# Windows Cache
server=/*.windowsupdate.com/192.168.1.245
server=/*.dl.delivery.mp.microsoft.com/192.168.1.245
server=/dl.delivery.mp.microsoft.com/192.168.1.245
server=/*.update.microsoft.com/192.168.1.245
server=/*.do.dsp.mp.microsoft.com/192.168.1.245
server=/*.microsoft.com.edgesuite.net/192.168.1.245
server=/amupdatedl.microsoft.com/192.168.1.245
server=/amupdatedl2.microsoft.com/192.168.1.245
server=/amupdatedl3.microsoft.com/192.168.1.245
server=/amupdatedl4.microsoft.com/192.168.1.245
server=/amupdatedl5.microsoft.com/192.168.1.245

# Rockstar Cache
server=/patches.rockstargames.com/192.168.1.245

#Epic Games
server=/cdn1.epicgames.com/192.168.1.245
server=/cdn.unrealengine.com/192.168.1.245
server=/cdn1.unrealengine.com/192.168.1.245
server=/cdn2.unrealengine.com/192.168.1.245
server=/cdn3.unrealengine.com/192.168.1.245
server=/download.epicgames.com/192.168.1.245
server=/download2.epicgames.com/192.168.1.245
server=/download3.epicgames.com/192.168.1.245
server=/download4.epicgames.com/192.168.1.245
server=/epicgames-download1.akamaized.net/192.168.1.245
server=/fastly-download.epicgames.com/192.168.1.245

#Xbox Live
server=/assets1.xboxlive.com/192.168.1.245
server=/assets2.xboxlive.com/192.168.1.245
server=/xbox-mbr.xboxlive.com/192.168.1.245
server=/assets1.xboxlive.com.nsatc.net/192.168.1.245
server=/xvcf1.xboxlive.com/192.168.1.245
server=/xvcf2.xboxlive.com/192.168.1.245
server=/d1.xboxlive.com/192.168.1.245

#Nintendo
server=/ccs.cdn.wup.shop.nintendo.net/192.168.1.245
server=/ccs.cdn.wup.shop.nintendo.net.edgesuite.net/192.168.1.245
server=/geisha-wup.cdn.nintendo.net/192.168.1.245
server=/geisha-wup.cdn.nintendo.net.edgekey.net/192.168.1.245
server=/idbe-wup.cdn.nintendo.net/192.168.1.245
server=/idbe-wup.cdn.nintendo.net.edgekey.net/192.168.1.245
server=/ecs-lp1.hac.shop.nintendo.net/192.168.1.245
server=/receive-lp1.dg.srv.nintendo.net/192.168.1.245
server=/*.wup.shop.nintendo.net/192.168.1.245
server=/*.wup.eshop.nintendo.net/192.168.1.245
server=/*.hac.lp1.d4c.nintendo.net/192.168.1.245
server=/*.hac.lp1.eshop.nintendo.net/192.168.1.245

#Blizzard

server=/dist.blizzard.com/192.168.1.245
server=/dist.blizzard.com.edgesuite.net/192.168.1.245
server=/blizzard.vo.llnwd.net/192.168.1.245
server=/blzddist1-a.akamaihd.net/192.168.1.245
server=/blzddist2-a.akamaihd.net/192.168.1.245
server=/blzddist3-a.akamaihd.net/192.168.1.245
server=/level3.blizzard.com/192.168.1.245
server=/nydus.battle.net/192.168.1.245
server=/edge.blizzard.top.comcast.net/192.168.1.245
server=/cdn.blizzard.com/192.168.1.245
server=/*.cdn.blizzard.com/192.168.1.245

# Riot Games

server=/l3cdn.riotgames.com/192.168.1.245
server=/worldwide.l3cdn.riotgames.com/192.168.1.245
server=/riotgamespatcher-a.akamaihd.net/192.168.1.245
server=/riotgamespatcher-a.akamaihd.net.edgesuite.net/192.168.1.245
server=/*.dyn.riotcdn.net/192.168.1.245

# Nexus Mods

server=/filedelivery.nexusmods.com/192.168.1.245

This is the File i use but it seams that it is not working. Used ipconfig /flushdns and try to ping "lancache.steamcontent.com" but i got the external ip.

Maybe it does not like the "comments" with the #.

Which of the two methods I proposed above have you tried?
Was there any error shown during the process?

Comments (#) should be fine.

"Pi-hole v6.0 has a new option called misc.dnsmasq_lines which can be used to add a series of config lines just as the one you mentioned above."

<-This and i reboot the client and "ipconfig /flushdns". And no Error.

and i changed the File so now there is no space or # in the File:

server=/lancache.steamcontent.com/192.168.1.245
server=/.windowsupdate.com/192.168.1.245
server=/
.dl.delivery.mp.microsoft.com/192.168.1.245
server=/dl.delivery.mp.microsoft.com/192.168.1.245
server=/.update.microsoft.com/192.168.1.245
server=/
.do.dsp.mp.microsoft.com/192.168.1.245
server=/.microsoft.com.edgesuite.net/192.168.1.245
server=/amupdatedl.microsoft.com/192.168.1.245
server=/amupdatedl2.microsoft.com/192.168.1.245
server=/amupdatedl3.microsoft.com/192.168.1.245
server=/amupdatedl4.microsoft.com/192.168.1.245
server=/amupdatedl5.microsoft.com/192.168.1.245
server=/patches.rockstargames.com/192.168.1.245
server=/cdn1.epicgames.com/192.168.1.245
server=/cdn.unrealengine.com/192.168.1.245
server=/cdn1.unrealengine.com/192.168.1.245
server=/cdn2.unrealengine.com/192.168.1.245
server=/cdn3.unrealengine.com/192.168.1.245
server=/download.epicgames.com/192.168.1.245
server=/download2.epicgames.com/192.168.1.245
server=/download3.epicgames.com/192.168.1.245
server=/download4.epicgames.com/192.168.1.245
server=/epicgames-download1.akamaized.net/192.168.1.245
server=/fastly-download.epicgames.com/192.168.1.245
server=/assets1.xboxlive.com/192.168.1.245
server=/assets2.xboxlive.com/192.168.1.245
server=/xbox-mbr.xboxlive.com/192.168.1.245
server=/assets1.xboxlive.com.nsatc.net/192.168.1.245
server=/xvcf1.xboxlive.com/192.168.1.245
server=/xvcf2.xboxlive.com/192.168.1.245
server=/d1.xboxlive.com/192.168.1.245
server=/ccs.cdn.wup.shop.nintendo.net/192.168.1.245
server=/ccs.cdn.wup.shop.nintendo.net.edgesuite.net/192.168.1.245
server=/geisha-wup.cdn.nintendo.net/192.168.1.245
server=/geisha-wup.cdn.nintendo.net.edgekey.net/192.168.1.245
server=/idbe-wup.cdn.nintendo.net/192.168.1.245
server=/idbe-wup.cdn.nintendo.net.edgekey.net/192.168.1.245
server=/ecs-lp1.hac.shop.nintendo.net/192.168.1.245
server=/receive-lp1.dg.srv.nintendo.net/192.168.1.245
server=/
.wup.shop.nintendo.net/192.168.1.245
server=/.wup.eshop.nintendo.net/192.168.1.245
server=/
.hac.lp1.d4c.nintendo.net/192.168.1.245
server=/.hac.lp1.eshop.nintendo.net/192.168.1.245
server=/dist.blizzard.com/192.168.1.245
server=/dist.blizzard.com.edgesuite.net/192.168.1.245
server=/blizzard.vo.llnwd.net/192.168.1.245
server=/blzddist1-a.akamaihd.net/192.168.1.245
server=/blzddist2-a.akamaihd.net/192.168.1.245
server=/blzddist3-a.akamaihd.net/192.168.1.245
server=/level3.blizzard.com/192.168.1.245
server=/nydus.battle.net/192.168.1.245
server=/edge.blizzard.top.comcast.net/192.168.1.245
server=/cdn.blizzard.com/192.168.1.245
server=/
.cdn.blizzard.com/192.168.1.245
server=/l3cdn.riotgames.com/192.168.1.245
server=/worldwide.l3cdn.riotgames.com/192.168.1.245
server=/riotgamespatcher-a.akamaihd.net/192.168.1.245
server=/riotgamespatcher-a.akamaihd.net.edgesuite.net/192.168.1.245
server=/*.dyn.riotcdn.net/192.168.1.245
server=/filedelivery.nexusmods.com/192.168.1.245

Okay, thanks, what does the command

grep "conf-dir=" /etc/pihole/dnsmasq.conf

return when run on your Pi-hole?


Did that help?

If not, please try running sudo service pihole-FTL restart - even if that shouldn't make a difference - and try again.

image

Nothing.

and after->
image
Still nothing.


If it helps i am on Version:

  • Core vDev (development-v6, 2338c9e9)
  • FTL vDev (development-v6, 01983299)
  • Web interface vDev (development-v6, 4ed958db)

Log gives me this.192.168.1.145 is the client

2023-11-27 16:50:38.313 query[A] lancache.steamcontent.com from 192.168.1.145
 2023-11-27 16:50:38.313 cached lancache.steamcontent.com is 
 2023-11-27 16:50:38.313 cached origin-tier2.steampipe.steamcontent.com is 
 2023-11-27 16:50:38.313 cached steampipe-origin-tier2.steamcontent.com is 162.254.197.9
 2023-11-27 16:50:38.314 cached steampipe-origin-tier2.steamcontent.com is 205.196.6.144
 2023-11-27 16:50:38.314 cached steampipe-origin-tier2.steamcontent.com is 162.254.197.25
 2023-11-27 16:50:38.314 cached steampipe-origin-tier2.steamcontent.com is 205.196.6.174

@ DL6ER Ok i am Stupid.

Without ENABLE misc.etc_dnsmasq_d Funktion it could not work right?!..... Right...

image

And now i got this :slight_smile:
image

Maybe add a funktion or HINT that this MUST be enabled. Or enable it as soon a User enter a Text at the values?

Thanks for the Help.

No, actually, one or the other should have worked independently. Could you try again which one (exclusively!) is not working? Or do they really only work in combination (shouldn't be!)?

ok redid everything.

Did a Clean Setup... Reboot Clients und Server....

now without "misc.etc_dnsmasq_d" @ off and so far all is working. dont know why it does work now.

1 Like