Ubuntu: How do I prevent me from changing /etc/hosts [closed]



Question:

I'm trying to fight my bad habit of wasting time on time-consuming websites such as reddit/liveleak etc.

The only thing which seems to work is adding a line like this to my etc/hosts 127.0.1.1 www.reddit.com

It works for a few days but then when i got nothing to do i edit this file and remove this line and start wasting my life again.

Is it a way to make my etc/hosts file immune to changes that would delete something from it ? (So that i would only be able to add things to it when i stumble upon a website which i think is a potential threat for my time).

It is really important for me and i will be extremely grateful for any help.


Solution:1

TL;DR Unfortunately, your self-control cannot be configured.


If you want to prevent yourself from editing this file, it will not be possible as long as you are logged in with your administrator account (sudo rights). Create a new user without administrator privileges and work with this account.

Or by editing the configuration of your router and forbid it from that side.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »