Archive for March 5th, 2009
Adding a static route in ubuntu linux
by swicknire on Mar.05, 2009, under linux/ubuntu
You may come across the circumstance where you have one ip subnet with a gateway ip on a different subnet.
Lets say for instance your static ip is 10.10.0.1 and you need to set the gateway as 9.9.0.1. After your initial setup of static ip, you may notice the destination is unreachable.
configure your static ip via command line
sudo nano /etc/netowork/interfaces
if you hapen to be using centos or fedora, you may use something similar to
system-config-network
(or)
setup
in ubuntu using the /etc/network/interfaces file
auto eth0
iface eth0 inet static
address 10.10.0.1
netmask 255.255.255.0
gateway 9.9.0.1
now while all looks right, you probably won’t be able to get online. You can restart your interface with
sudo /etc/init.d/network restart
if you add a custom route to the host and set the default gateway you should then be able to access something
sudo route add -host 9.9.0.1 eth0
sudo route add default gw 9.9.0.1
hopefully everything should be good to go! Make sure that your /etc/resolve.conf file has proper name servers for your isp.
nameserver 123.123.123.123
Now in order to make these changes persistant on startup/reboot you may add them to the /etc/network/interfaces file, but typically that has never worked for me across any distro.
What I do is add them to my rc.local file (which is executed after all other system modules are brought online).
sudo nano /etc/rc.d/rc.local
/sbin/route add -host 9.9.0.1 eth0
/sbin/route add default gw 9.9.0.1
This should help bring your network back online in case of power outage or reboot. Keep in mind that if you /etc/init.d/network restart you will likely have to manually add those routes by hand again. (no biggie).
To check your routing table just simply
route -n
The Problem with openDNS nameservers
by swicknire on Mar.05, 2009, under The Web
First and foremost, openDNS sucks! They’re trying to offer an advantage over how regular DNS works… but to be honest… there is no advantage other than you’re regular run of the mill DNS. When I type something wrong, I want an error! When I type something right and you spit back something wrong, that pisses people off!
Name resolutions are totally wack! If you use openDNS with ubuntu, centos, or most any other linux distro – you may notice you cannot update your systems! Total crap! And who’s to say they don’t inject their own DNS record so that when you mange to update your system – you’re actually installing a root kit embedded into a package you think is legit.
Using openDNS is the absolute biggest security hole you can possibly think of. All those phishing scams you’re afraid of… well they become 100% transparant when you’re relaying off their servers… they can send you to any page they wish to grab facebook passwords, email passwords, whatever! And guess what, you’re none the wiser! Your address bar still has the address you think it is, but you could very well be connected to a different server.