How To Share Dialup Internet Connection On Ubuntu Server

This article explain how to share your dialup internet connection on ubuntu linux. Just to share with the other. Here you are.

1. Change your statict network interface. In this example is eth1.
# vim /etc/network/interfaces

auto eth1
iface eth1 inet static
address 192.168.0.254
netmask 255.255.255.0
broadcast 192.168.0.255

where eth1 is the network card and ip is your desired server ip address. I used 192.168.0.254 as IP Address.

2. Configure the NAT:

# iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE

where ppp0 is the network card that the Internet is coming from. Use ppp0 for dialup connection.

# echo 1 > /proc/sys/net/ipv4/ip_forward

3. Install dnsmasq and ipmasq using apt-get:

# apt-get install dnsmasq ipmasq

4. Reconfigure ipmasq to start after networking has been started:

# dpkg-reconfigure ipmasq

5. Add the line “net.ipv4.ip_forward = 1″ to /etc/sysctl.conf

# vim /etc/sysctl.conf

6. Set your client DNS to 192.168.0.254

How to recover images from formatted memory card

A few days ago, My friend’s SD card accidentally formatted. While in the SD card is a memorable photographs of the birth of their first son. To restore these photos I recommend to use the recovery tool. To find the recovery tool, I told him to look for in google.

There are some recovery tools that are used. All are Windows programs. However, none of which succeeded. This is because the tool is a trial version. Meanwhile, to get the full version required to buy it. Fortunately I have a Ubuntu Linux machine which Ubuntu Lucid Lynx LTS upgrade from Ubuntu LTS Hardy Heron, minimal installation with LXDE. And finally my friend’s problem could be solved with the help of my Ubuntu Linux machine.

Here are some things you need to do with simple commands. This tutorial is written for Ubuntu GNU/Linux, but should be similar for most Linux machines.

1. Make a copy of the image of your SD card.
sudo dd if=/dev/sdb of=SDCARD-backup.img bs=1M

2. Install recoverjpeg package via apt-get
sudo apt-get install recoverjpeg

3. Run the command below.
$ recoverjpeg SDCARD-backup.img
Restored 398 pictures

The pictures that have been recovered will be stored in a folder. Please see the recovery that have been made. Good luck … Go Opensource .

Simple WordPress Themes

Simple is my next WordPress themes. Simple WordPress Themes consist of only 2 files, index.php and style.css. Simple WordPress themes is Valid CSS and Valid XHTML 1.0 Transitional.

As the previous themes, Simple WordPress Theme is released under a Creative Commons Attribution License 3.0. Here’s the source code of the Simple WordPress Theme.
Read the rest of this entry »

How to add Breadcrumbs without plugins on WordPress

Most of the blog with SEO considerations using breadcrumbs. In this article I am going to show you how to do proper, full breadcrumbs in including nested categories and nested pages. Breadcrumbs are a pretty standard design pattern and can be very useful in a lot of website situations. For WordPress users typically use plugins. But for those who want to add facilities in bredacrumbs WordPress-based blog without using plugins, try my way below.

You can just include this function in your theme’s “functions.php” file.

8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
function get_wp_breadcrumbs() {
	if (!is_home()) {
		echo ('You are here: '); 
		echo '<a href="';
		echo get_option('home');
		echo '">';
		echo 'Home';
		echo "</a> » ";
		if (is_category() || is_single()) {
			the_category(' &raquo; ',multiple);
			if (is_single()) {
				echo " » ";
				the_title();
			}
		} elseif (is_page()) {
			echo the_title();
		}
 
	}
	else { 
	echo ('You are here: '); 
	echo '<a href="';
	echo get_option('home');
	echo '">';
	echo 'Home';
	echo "</a> » ";
	}
}

And then add the following code in the “header.php” file.

108
<?php get_wp_breadcrumbs(); ?>

So there you have it. Fully customizable, valid breadcrumbs in WordPress. Please let me know what you think.

Howto Fix login delay after upgrade to Lucid Lynx

My Linux Box is Ubuntu LTS 8.04.4 minimal install with LXDE/Openbox as Window Manager. But after upgrading to Ubuntu Lucid Lynx, I noticed that it took an extra 15 – 20 seconds for it to finish logging me in after I entered my password. This was particularly noticeable to me because I use LXDE/Openbox as my window manager, and normally starts up in less than one second on my hardware.

If you’re experiencing this problem, there’s a very easy fix:

sudo mv /usr/bin/xsplash /usr/bin/xsplash_hidden

This just hides xsplash under a different name so that the login manager can’t find it and run it. I found that it did not cause any problem to have xsplash unavailable. However, the reason I’ve suggested renaming it rather than deleting it is so that if it does cause a problem, you can just rename it back.

For explanation, it turns out that xsplash has a 15-second delay hardcoded into it before the brown splash screen goes away. If you’re using Gnome, apparently Gnome has a mechanism to let xsplash know when it’s done loading, so the brown xsplash screen will go away in less than 15 seconds. But if you’re using a window manager other than Gnome that doesn’t support this mechanism, the brown screen will stay there for the full 15 seconds, while you wait for it.

Install Ubuntu Lucid Lyxn Via Debootstrap

Just looking for nLite like on Ubuntu/GNU Linux? Please follow my guide.

1. Booting from your ubuntu installation media.
2. Make a new ext3 partition via cfdisk and mkfs.ext3
3. Mount your partition under /mnt/Ubuntu_10.04
4. Copy hardy script to lucid
5. cd /mnt/Ubuntu_10.04
6. debootstrap –arch=i386 lucid .
7. mount proc proc/ -t proc
8. cp /etc/resolv.conf etc/resolv.conf
9. cp /etc/hosts etc/hosts
10. cp /etc/network/interfaces etc/network/interfaces
11. chroot /mnt/Ubuntu_10.04
12. Install the kernel apt-get install linux-image-generic
13. Fix the sources.list file
deb http://archive.ubuntu.com/ubuntu lucid main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ lucid main restricted

deb http://us.archive.ubuntu.com/ubuntu/ lucid-updates main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ lucid-updates main restricted

deb http://us.archive.ubuntu.com/ubuntu/ lucid universe
deb-src http://us.archive.ubuntu.com/ubuntu/ lucid universe

deb http://us.archive.ubuntu.com/ubuntu/ lucid-updates universe
deb-src http://us.archive.ubuntu.com/ubuntu/ lucid-updates universe

deb http://us.archive.ubuntu.com/ubuntu/ lucid multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ lucid multiverse

deb http://us.archive.ubuntu.com/ubuntu/ lucid-updates multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ lucid-updates multiverse

#backports
deb http://us.archive.ubuntu.com/ubuntu/ lucid-backports main restricted universe multiverse

#partner repos
deb http://archive.canonical.com/ubuntu lucid partner
deb-src http://archive.canonical.com/ubuntu lucid partner

deb http://security.ubuntu.com/ubuntu lucid-security main restricted
deb-src http://security.ubuntu.com/ubuntu lucid-security main restricted

deb http://security.ubuntu.com/ubuntu lucid-security universe
deb-src http://security.ubuntu.com/ubuntu lucid-security universe

deb http://security.ubuntu.com/ubuntu lucid-security multiverse

deb http://us.archive.ubuntu.com/ubuntu/ lucid-proposed restricted main multiverse universe
deb-src http://security.ubuntu.com/ubuntu lucid-security multiverse

14. Install language pack apt-get install language-pack-en-base
15. Reconfigure locale dpkg-reconfigure locales
16. apt-get clean
17. apt-get install grub
18. grub-install /dev/hda
19. update-grub
20. Exit the chroot

Thanks to CentraBiz Jember for Amazing Internet Connection…

Forgiven But Not Forgotten

Profesor saya melempar topik panas berkenaan dengan masalah memaafkan dan melupakan. Kalau dalam istilah Maduranya, “Forgiven Forgotten”. Topik yang beliau lempar adalah “Forgiveness will open the doorway of our own love? ” Artinya kita harus bersedia SELALU memaafkan, tidak membalas, tidak mendendam, tidak membenci! Bisa gak ya dilakukan ma kita?

Maka sayapun menanggapi dengan statement, kalau manusia lebih bersifat emosional. Dan disini berlaku hukum sebab akibat. Jangan lup, ingatan manusia berlaku dua arah. Dimana pada satu sisi lebih kuat arus kognitifnya dan disaat lain sifat emosional akan muncul. Dan celakanya, emosi dalam diri lebih kuat. Keadaan ini malah menimbulkan dendam kusumat. Yang diistilahkan oleh Prof. Dwi sebagai “Forgivness”. Coba kalau ingatan manusia hanya kuat disisi kognitifnya, maka dengan mudah kita akan “melupakan” kejadian2 yang lalu. Jadi buat yang tingkat emosinya tinggi, yakin deh tak akan pernah bisa memaafkan…. apalagi melupakan… Bukan masalah melupakan atau memaafkan, yang terpenting apa hikmah yang bisa diambil. Jangan seperti keledai bodoh yang terperosok pada lobang yang sama. Seperti nyanyian The Corrs dalam lagu Forgiven Not Frogotten.

A bleeding heart torn apart, left on an icy grave,
In the room where they once lay, face to face,
Nothing could get in their way, but now the memories of the man
Are haunting her days and the craving never fades,
Shes still dreaming of a man long forgiven, but not forgotten,

Youre forgiven not forgotten
Youre forgiven not forgotten
Youre forgiven not forgotten
Youre not forgotten

Still alone, staring on, wishing her life goodbye
As she goes searching for the man long forgiven, but not forgotten,

Forgiven But Not Forgotten