How to configure Cisco Linksys WRT54G v.2 to run Pixelserv on DD-WRT

Cisco Linksys WRT54G v.2
Cisco Linksys WRT54G v.2

This is how I was able to implement the solution given by Aviad Raviv found here How to Remove Advertisements with Pixelserv on DD-WRT

 

I am not going to go through his tutorial or how to get DD-WRT onto your Cisco Linksys WRT54G v.2. Aviad did a wonderful job, for the most part, and there are plenty of DD-WRT tutorials out there. I followed every step that Aviad wrote up, downloaded what he said to download, made every configuration as it was laid out but I could not get the disable_ads.sh script to run. I kept getting errors like these

In the WRT54G commands GUI:

sh: eval: line 1: /jffs/dns/disable_adds.sh: not found

 

And this in the SSH CLI

root@Deadend:~# sh /jffs/dns/disable_adds.sh
: not foundisable_adds.sh: line 10: {
ad_blocker_script:
: not foundisable_adds.sh: line 12: }
: not foundisable_adds.sh: line 13:
: not foundisable_adds.sh: line 15: {
/jffs/dns/disable_adds.sh: line 189: syntax error: end of file unexpected (expecting "then")

I spent a few hours trying this and that, permissions, and manually editing the file with Notepad++ and / or vi. Nothing worked. I knew about the big Indian / little Indian situation when working with files to be run on a Unix / Linux system with a Windows system. I have never run into that issue while using Notepad++ though. This was making me crazy, plus I could not remember ever even opening that file before I uploaded it to my WRT54G so what was the deal. Well as a last ditch effort I tried to run dos2unix on the file on the WRT54G … well that program is not on the WRT54G, to save space I am sure. So I uploaded the disable_ads.sh file to my CentOS 6 box and tried to run dos2unix … well it wasn’t there, I did a minimal install when I setup that box so I got:

-bash: dos2linux: command not found

Thankfully that machine is connected to the Internet and a quick

sudo yum install dos2unix -y

got it installed. I then dos2unix’ed the disable_ads.sh file and migrated it back to the WRT54G; BTW the file size changed from 10KB to 9KB so something was changed for sure. After putting this new version of the sh script on the WRT54G I rebooted it. When it came back up I checked WinSCP and the files that were to be created on first run of the script were there just as Aviad said they would be.

 

To recap if you are not getting success with running the disable_ads.sh script after going through Aviad’s tutorial then you need to run it through dos2unix and re-upload to your router. I assume this could be a problem on other routers not just the Cisco Linksys WRT54G v.2.

 

I would have made this post as a comment on Aviad’s tutorial but it was not open for comments. Hope others will find this and it help them .

 

BONUS:

I spent quite some time making up this file. It is a personal-ads-list.conf with 3,595 blocked sites, mostly adult sites. I grabbed the initial list from jacop_’s post, then I formatted it to work with Pixelsrv. When you upload and reboot the router it will take some time, maybe 10 minutes or more for Pixelsrv to parse through the list.

Cedar fire 21AUG2016 Satelite Image

Satellite Image

Screen shot of the Cedar wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 08/20/2016 at 21:29:49 GMT or 1:29:49 PM local time. Woke up this morning in Ridgecrest to massive amounts of smoke and some falling ash. You can see in the image that this is a very big wild fire.

CedarFireSatImg_20160821
CedarFireSatImg_20160821

Cedar fire 20AUG2016 Satelite Image

Satellite Image

Screen shot of the Cedar wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 08/19/2016 at 21:42:15 GMT or 1:42:15 PM local time. Woke up this morning in Ridgecrest to massive amounts of smoke and some falling ash. You can see in the image that this is a very big wild fire.

CedarFireSatImg_20160819
CedarFireSatImg_20160819

Worst first experience

Hello,

My wife and I attempted to attend the NFL preseason game between the L.A. Rams and the Dallas Cowboys on Saturday August13th 2016. This was to be her first time going to see an NFL game in person, and it was happening at the perfect time. She had just finished her first week in her new carrier as an elementary school teacher after years of attending college and teaching courses. Her favorite football team is the Cowboys and until the Rams came back to L.A. there was no opportunity for us to afford a trip to go see them play. She came home from grocery shopping Saturday morning and told me about the game so I told her “let’s go”. We found tickets that were mostly within our budget, and hopped in the car. Even though we convinced ourselves that the $203.98 for the tickets and the money for gas, food, and baby sitter was something that we could afford in order to celebrate my wife’s achievement it is a lot of money for us to spend on something that isn’t food or to pay bills.

Our trip to the Los Angeles Memorial Coliseum is one that encompasses a 158 mile 2 hour and 39 minute, without traffic, trip. One way. Even with these negative aspects that presented themselves we still made the choice to make the pilgrimage to see the Rams host the Cowboys. We expected traffic and chaos and higher than normal prices for things like hot dogs and water, but we had no idea and we’re completely shocked at the parking situation. As we were driving up to the stadium we saw that the city of L.A. had placed special no parking signs for blocks around the stadium, even on sections of road that have parking meters. We figured we would have to pay for parking but $100 and up was ridiculous. We drove around in circles in event level traffic for over an hour and when we finally found an open spot it the parking lot of a gas station over a mile away. We sat there for a few minutes weighting our options and evaluating our situation. On the one had we had the $200 + spent on tickets etc. and a desire to celebrate and enjoy a fun time together. On the other we had a 30-45 minute walk in an unfamiliar city, the potential for our vehicle being towed or vandalized, and the game was half over and with the walk waiting to get inside etc. we could maybe see the last 10 minutes of the game. With more negatives than positives we kissed the idea of going to the game good by and headed back home dissapointed, sad, mad, and angry.

That’s our story of what we will forever remember and refer to as “The Rams Game”. It will always remind each other to think about the worst thing that could happen before making quick last minute decisions.

In my most practical frame of mind I want to have this experience be recorded and our anger and disappointment in the Los Angeles Memorial Coliseum venue, the Los Angeles Rams, the City of Los Angeles, and the National Football League made public. When in my frame of mind where I feel cheated out of my time, money, and ability to reward my wife for her hard work I want a full refund of the price of the tickets. While still in this frame of mind I cannot understand how a venue that has a capacity of 93,607 does not have a corresponding capacity parking lot. Then as it seems the City of Los Angeles works to slow for the gouging of parking prices by eliminating the ability to use otherwise usable public parking spaces.

Please respond as you see fit, as I plan to broadcast this message as far and as wide across the Internet, social media, friends, and family.

Michael Lane

Erskine fire 11JUL2016 Satelite Image

Satellite Image Update

Screen shot of the Erskin wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 07/11/2016 at 21:36:11 GMT or 1:36:11 PM local time. According to InciWeb there will be no more daily updates as of 07/06/2016 on the Erskine wild fire. They say that the operation is in “mop up” mode with fire crews walking the perimeter and searching for smoldering stumps and the like. I will still check the satellite images for as long as I can remember to do so and there is still visible heat.

ErskineFire11jul2016SatImg
ErskineFire11jul2016SatImg

Erskine fire 10JUL2016 Satelite Image

Satellite Image Update

Screen shot of the Erskin wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 07/10/2016 at 20:53:04 GMT or 12:53:04 PM local time. According to InciWeb there will be no more daily updates as of 07/06/2016 on the Erskine wild fire. They say that the operation is in “mop up” mode with fire crews walking the perimeter and searching for smoldering stumps and the like. I will still check the satellite images for as long as I can remember to do so and there is still visible heat.

ErskineFire10jul2016SatImg
ErskineFire10jul2016SatImg

Erskine fire 08JUL2016 Satelite Image

Satellite Image Update

Screen shot of the Erskin wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 07/08/2016 at 21:05:15 GMT or 1:05:15 PM local time. According to InciWeb there will be no more daily updates as of 07/06/2016 on the Erskine wild fire. They say that the operation is in “mop up” mode with fire crews walking the perimeter and searching for smoldering stumps and the like. I will still check the satellite images for as long as I can remember to do so and there is still visible heat.

ErskineFire08jul2016SatImg
ErskineFire08jul2016SatImg

Erskine fire 07JUL2016 Satelite Image

Satellite Image Update

Screen shot of the Erskin wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 07/07/2016 at 20:23:00 GMT or 12:23:00 PM local time. According to InciWeb there will be no more daily updates as of 07/06/2016 on the Erskine wild fire. They say that the operation is in “mop up” mode with fire crews walking the perimeter and searching for smoldering stumps and the like. I will still check the satellite images for as long as I can remember to do so and there is still visible heat.

ErskineFire07jul2016SatImg
ErskineFire07jul2016SatImg

Erskine fire 06JUL2016 Satelite Image

Satellite Image Update

Screen shot of the Erskin wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 07/06/2016 at 21:17:35 GMT or 1:17:35 PM local time. According to InciWeb there will be no more daily updates as of 07/06/2016 on the Erskine wild fire. They say that the operation is in “mop up” mode with fire crews walking the perimeter and searching for smoldering stumps and the like. I will still check the satellite images for as long as I can remember to do so and there is still visible heat.

ErskineFire06jul2016SatImg
ErskineFire06jul2016SatImg

Erskine fire 04JUL2016 Satelite Image

Satellite Image Update

Screen shot of the Erskin wild fire. Zoomed in and taken from the Satellite: Aqua Bands 7, 2, 1 False Color (JPEG) image on the USDA Forest service website. It was taken on 07/04/2016 at 21:30:01 GMT or 1:30:01 PM local time. According to InciWeb the Erskine wild fire 95% contained, but you can see in the satellite image there is still significant heat in / on the ground. Amazing!

ErskineFire04Jul2016SatImg
ErskineFire04Jul2016SatImg