Syed Jahanzaib Personal Blog to Share Knowledge !

June 13, 2011

Ubuntu : A sample share for sharing your Folder with others.

Filed under: General IT Related — Syed Jahanzaib / Pinochio~:) @ 9:15 AM

# A sample share for sharing your Folder with others.
[zaib]
comment = zaib folder
read only = yes
locking = no
path = /zaib
guest ok = yes

UBUNTU: Howto boot into Text Mode :)

Filed under: General IT Related — Tags: , , , — Syed Jahanzaib / Pinochio~:) @ 8:58 AM

ubuntu-text-mode_big

UBUNTU: Howto boot into Text Mode 🙂

How to launch Ubuntu in Text Mode like FEDORA boots it in a cool way by displaying all spices?Follow the below . . .

I had make ubuntu boot into text mode by changing /etc/default/grub file:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
to
GRUB_CMDLINE_LINUX_DEFAULT="text"

Then run update-grub & reboot.

Regard’s
Syed Jahanzaib

Ubuntu : Persistent DNS Caching with pdnsd.

Filed under: Linux Related — Syed Jahanzaib / Pinochio~:) @ 8:30 AM

When I setup Squid on Ubutu, there was one problem that I faced frequently, is the slow DNS look-up performance, especially compared with the same hardware running Windows. I found one way of improving performance is to provide DNS caching on the local machine and to disable ipv6.
First to disable ipv6 on ubuntu, Add
net.ipv6.conf.all.disable_ipv6=1
to /etc/sysctl.conf and run sysctl -p

Now install pdnsd by
apt-get install pdnsd

now edit its config file
ano /etc/pdnsd.conf
and paste the following config, its mine, u can edit accordingly.


global {
perm_cache=1024;
cache_dir="/var/cache/pdnsd";
run_as="pdnsd";
#server_ip = 127.0.0.1;
#server_port=53;
status_ctl = on;
paranoid=on;
query_method=udp_tcp;
max_ttl=1w; # One week.
timeout=10;
}

server {
label=Lan;
ip=129.168.2.1;
timeout=30;
uptest=ping;
interval=30;
ping_timeout=300;
purge_cache=off;
caching=on;
preset=off;
}
server {
label=OpenDNS;
ip=221.132.112.8;
ip=221.132.112.9;
timeout=30;
uptest=ping;
interval=30;
ping_timeout=300;
purge_cache=off;
caching=on;
preset=off;
}

source {
owner=localhost;
serve_aliases=on;
file=”/etc/hosts”;
}

rr {
name=localhost;
reverse=on;
a=127.0.0.1;
owner=localhost;
soa=localhost,root.localhost,42,86400,900,86400,86400;
}

Now in /etc/resolv.conf , replace your nameserver with this
nameserver 127.0.0.1

restart pdnsd , and enjoy fast websites response due to local DNS caching 🙂 , also dont forget to add dns_nameservers 127.0.0.1 in squid.conf

%d bloggers like this: