LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Closed Thread
 
Search this Thread
Old 06-11-2009, 02:10 AM   #16
BslBryan
LQ Newbie
 
Registered: May 2009
Distribution: Ubuntu
Posts: 3

Original Poster
Rep: Reputation: 1

Wow, I didn't mean to start a flame war. Sorry, guys!

Thanks, Ruler2112 for your kind words, and to everyone else, yeah, there are certainly easier ways to block ads. I just found this hosts file and thought it was neat.

I might add in a little disclaimer that it's only for knowledge. I'm not recommending this tutorial, because there really are simpler ways of doing this, but there certainly isn't any harm in posting it here, or even following the steps.

Also, some people might find this comes in useful if they are using a very new, unstable browser that has no add-ons, etc.

EDIT: Just realized that the link to the hosts file has been modded out.
Anyway, thanks for reading, and I'm glad most of you seemed to enjoy it. I suppose it really is worthless now.

Last edited by BslBryan; 06-11-2009 at 02:16 AM.
 
Old 06-11-2009, 12:13 PM   #17
farslayer
Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 189Reputation: 189
Since Adblock was mentioned I'll throw in that the Untangle Gateway has adblock now, so it can do ad blocking for your entire network while it's sitting at the gateway. Plus all the other nifty features of the UTM device..
 
Old 06-16-2009, 03:02 AM   #18
BeacoN
Member
 
Registered: Nov 2008
Distribution: Linux Mint
Posts: 56

Rep: Reputation: 17
cool

I'm definitely one for knowing how to do something. many ways. This is yet another way to blacklist ip addresses from toturing you. Thanks for the post!
 
Old 06-25-2009, 05:11 AM   #19
nowonmai
Member
 
Registered: Jun 2003
Posts: 481

Rep: Reputation: 48
Quote:
Originally Posted by pwc101 View Post
My understanding is having a huge hosts file slows down address lookups since every time you enter an address, your browser has to scan through 15,000 lines before realising www.google.com isn't a dodgy address. I may be wrong on this, but that is my understanding.
Not really... name lookups will have to do this anyhow for new domain names. For other, cacheable names, the browser will remember. For non cacheables (ads for instance) it will have to do the lookup every time, either in the hosts file or via DNS.
 
Old 06-25-2009, 05:14 AM   #20
nowonmai
Member
 
Registered: Jun 2003
Posts: 481

Rep: Reputation: 48
Quote:
Originally Posted by BslBryan View Post
I just found this hosts file and thought it was neat.
And you're right, it is...

I, for one, am not a fan of loading layer upon layer of software on my network stack and/or browser. I really have no interest in privoxy, adblock and so on... they cause sluggishness, IMO.

This, simple, lightweight addition gives many of the benefits with little of the bloat.

Last edited by nowonmai; 06-25-2009 at 05:20 AM.
 
Old 06-25-2009, 05:32 AM   #21
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
Quote:
Originally Posted by nowonmai View Post
And you're right, it is...

I, for one, am not a fan of loading layer upon layer of software on my network stack and/or browser. I really have no interest in privoxy, adblock and so on... they cause sluggishness, IMO.

This, simple, lightweight addition gives many of the benefits with little of the bloat.
I'm betting a hosts file is a lot slower actually.
 
Old 06-25-2009, 06:21 AM   #22
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,561
Blog Entries: 54

Rep: Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927
Quote:
Originally Posted by nowonmai View Post
This, simple, lightweight addition gives many of the benefits with little of the bloat.
Since you say "gives many of the benefits" please explain how you would do this / block these using only your precious "simple, lightweight addition":
- incrementally update your blocklist,
- block ad-tracking cookies (for those using Firefox have a look at the www.ghostery.com plugin),
- block in-page ads residing in a path on the same server you visit,
- block ads from a hostname of which the domainname is the same as the server you visit,
- block ads presented through Javascript or Flash,
- block ads by host or path substring match,
- block only webbugs (you know, those tiny 1 pixel transparent images),
- set session-only cookies for a range of sites,
- selectively block popups, refresh-tags and redirects,
- keep images with specific sizes from displaying,
- block visiting domains based on content (like those parked sites).
Well, actually you don't need to try because you can't.
As such your "many of the benefits with little of the bloat" phrase can not based on reading (and actually understanding) what's been said in this thread already.


Also it turned out that the owner of the site where the hosts file resided is one of the Ubuntu people. That particular "hosts tutorial" got plastered over several web logs in the month it got posted here. Since this is not some radically new idea and the site owner does not make clear the content is not his but originates from mvps.org it must have been done purely for promotional purposes. He should have either linked to it or made clear it's not his work. File under plagiarism.

Last edited by unSpawn; 06-25-2009 at 06:37 AM. Reason: more *is* more.
 
1 members found this post helpful.
Old 06-25-2009, 06:40 AM   #23
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,561
Blog Entries: 54

Rep: Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927
...and since this isn't about Linux Security I'll move it elsewhere.
 
Old 08-04-2012, 09:12 AM   #24
XenaneX
Member
 
Registered: Jan 2009
Location: SE USA
Distribution: Mageia 4 formerly PCLOS
Posts: 131
Blog Entries: 4

Rep: Reputation: 18
Quote:
Originally Posted by unSpawn View Post
...and since this isn't about Linux Security I'll move it elsewhere.
I have a suggestion.
 
Old 08-04-2012, 01:21 PM   #25
jefro
Guru
 
Registered: Mar 2008
Posts: 11,969

Rep: Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484
"I'm betting a hosts file is a lot slower actually."

I have and still use some pretty huge hosts files. There were some versions of OS's and some browsers that didn't work correctly but they are all now faster than a dns lookup is (assuming your hard drive isn't from 1990).

To reverse the issue, you can put a hosts file with only the few sites that you use. Don't use any dns ip. There are some ad's that are on an ip so they will show. Not sure you can fully block all ads ever.

Sad we have to pay for this but it is also a choice to consider. http://www.opendns.com/home-solution...ntal-controls/
 
Old 08-04-2012, 02:03 PM   #26
NyteOwl
Member
 
Registered: Aug 2008
Location: Nova Scotia, Canada
Distribution: Slackware, OpenBSD, others periodically
Posts: 512

Rep: Reputation: 139Reputation: 139
using the hosts file this way is a very old trick. It still has it's uses but once it grows too large it can contribute some lag. And of course there are things it can't catch. But as a means of blocking specific IP's or host names it's fairly efficient, especcially for a short list.

I do have to chuckle at someone actually applying a licence of any kind to this as these lists have been around the net forever and are virtually all in the public domain. Trying to licence a particular list (which is undoubtedly a collation of other such lists strikes me as a bit over the top.
 
1 members found this post helpful.
Old 08-04-2012, 03:03 PM   #27
jefro
Guru
 
Registered: Mar 2008
Posts: 11,969

Rep: Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484
For many years I only could get a very slow dial up connection. It was usable on bulletin boards if you didn't mind paying long distance charges every night for a week to get a few floppies worth of data. When the internet took over I still had to use a text based browser. If you really want to speed up things you can try them. Once you get used to it, you wonder what the big deal is with other forms.
It may be that a person born into the web can't easily use a text based browser but at least try it.
 
Old 08-04-2012, 03:35 PM   #28
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,561
Blog Entries: 54

Rep: Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927Reputation: 2927
FCOL not again...

Quote:
Originally Posted by jefro View Post
Not sure you can fully block all ads ever.
Easy to test.


Quote:
Originally Posted by NyteOwl View Post
(..) of course there are things it can't catch.
Yeah, likely the stuff you wouldn't encounter the past millennium.


http://www.linuxquestions.org/questi....php?p=3585760
 
Old 08-04-2012, 11:24 PM   #29
jefro
Guru
 
Registered: Mar 2008
Posts: 11,969

Rep: Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484Reputation: 1484
I view the subject of ad's or unwanted content on a web page the same way I view OS/application security. I say my OS will be subject to an attack at some point no matter what I do. I can only limit my exposure. If you feel you have found some way to block content then there will be some new means to send junk to your browser. The worse offenders rely on new found holes in security. The really bad ones might get past any controls, because they know someone is trying to prevent them.
 
Old 08-04-2012, 11:54 PM   #30
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,025

Rep: Reputation: 558Reputation: 558Reputation: 558Reputation: 558Reputation: 558Reputation: 558
Quote:
Originally Posted by XenaneX View Post
I have a suggestion.
Post the suggestion.
 
  


Closed Thread

Tags
advertising, block, dont_use_a_hosts_file, firefox, localhost, tutorials, ubuntu, websites


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Linux: Which internet/web browser do you use and favour ? frenchn00b General 33 11-08-2008 05:59 AM
Unable to access internet thru web browser corbis_demon General 3 10-22-2006 05:46 AM
Internet connection problem, able to ping but unable to get web page in browser rajnishmishra Linux - Networking 13 07-15-2004 01:54 AM
Emptying Internet cache under Konqueror web browser piggysmile Linux - Software 2 05-25-2004 05:31 AM


All times are GMT -5. The time now is 08:26 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration