Change Debian / Ubuntu Shell Prompt

When I working with Debian terminal, my eyes felt pain. Debian doesn’t has colors sense. You open the terminal and you just seeing gray text.

For me, I dislike it. I love colorful shell, colorful text editor. That very helpful to edit or write syntax.

Thanks to Joshua Steiner for making such a great custom bash. Read More

Install The Latest APC Opcode through PECL on Debian 6 and How it Works

I have finished migrated this blog from Jakarta to Milan. The reason is BlackFriday coupon. Yes! I got an offer from iwStack/prometeus in LET community. I couldn’t leaving this precious offer.

On my previous server (Jakarta, CloudKilat), actually I didn’t have any issue. All thing work smoothly. But, as I said, I couldn’t leaving this precious offer.

On the previous server, I have 1 Gigs ram. I never thought about resources, but here at iwStack I have only 384 MB. So I have to save any resource.

To Save resources, I have good experiences with APC opcode. I installed it on my DigitalOcean blog, here the result I got. Read More

Install Nginx 1.4.x on Debian 6 Squeezy 32-bit

This is my documentation how I install nginx 1.4.x on Debian Squeezy.

Note: before I installed nginx on debian squeezy I tried to install it to debian wheezy. But I don’t like that, not because debian wheezy itself, but because debian wheezy can’t install nginx 1.4.x.

That was the reason why I chose debian squeezy than wheezy. If the nginx 1.4.x has support debian wheezy, I just need to upgrade the OS.

Let’s begin!

First of all, make sure that the repository work well. Install python-software-properties

This software provides an abstraction of the used apt repositories. It allows you to easily manage your distribution and independent software vendor software sources. ->

Now, edit the /etc/apt/sources.list and add this following line

FYI, if you are using Ubuntu precise, add this

In order to pull nginx during installation or update from nginx repository, we need the key. Download the key and run it with this following code:

Now, to install nginx to Debian system we just run this code:

apt-get install nginx-extras or apt-get install nginx-full or apt-get install nginx.

To run, restart, or stop the service, run this code:

That’s it!

To verify what version of nginx that you have installed. Run this code nginx -v

What is the different between nginx-extras vs nginx-full vs nginx?

The different of that is the module package. The nginx extreas is the heavier and nginx is the lighter. You can check the details.

Unable to locate package php5-fpm? & Break The Limit of Upload Size

Just documented the problem when I failed to install PHP5-FPM to Debian Squeeze.

failed to install php

failed to install php

The problem caused by repository. Here the instruction how to fix it.

First add this to /etc/apt/sources.list

Second fetch and install the GnuPG key

Don’t forget to run apt-get update and apt-get upgrade.

Now, you should be able to install php5-fpm

Perhaps you want minimum install

To run, restart, and stop php, you should do this

service php5-fpm restart | stop | start

Break The Limit

The default php allowed you to upload file no more than 2MB, if you want more you should edit the upload_max_filesize and post_max_size, both code is written on php.ini.

If you don’t know where php.ini located, you can find it with this solution

my case, the result were

It’s no problem if you edit all of these, but you have more effort. As I installed PHP5-fpm I just edit ./etc/php5/fpm/php.ini.

Do not randomly change the number, there are the rules to edit upload_max_filesize and post_max_size. Read the rules here.

In my case I edited the upload_max_filesize to 64M and post_max_size to 96MB.

Restart the php and see the phpinfo() to make sure your configuration.

413 Request Entity Too Large

Other issue when you failed to upload is webserver itself. I use to use nginx as webserver. To solve that just edit /etc/nginx/nginx.conf and add client_max_body_size 96M;

on http section,

You can change 96 to whatever you want. The 96M represent client body size that size 96MB.

Enjoy!

Membuat VPN Server di Debian 6 Squeeze

Kali ini gue mau ngedokumentasiin gimana caranya membuat VPN server di Debian 6. Kenapa Debian 6? lagi-lagi karena alasan resources, debian 6 tidak begitu makan resource gede.

Di sini gue pake RamNode 128MB SVZ.

Pertama pastikan bahwa TUN/TAP dan PPP nyala.

VPScontrol Panel

VPScontrol Panel

Yang belum tau apa itu TUN/TAP dan PPP, silahkan googling dulu.

Update VPS.

Download dan Install OpenVPN,

32bit

64bit

Begitu selesai, lo bakalan liat di terminal,

Access Server web UIs are available here:
Admin UI: https://192.xxx.xxx.xxx:943/admin
Client UI: https://192.xxx.xxx.xxx:943/

Ganti password admin openVPN dengan perintah

Login sebagai admin dengan user openvpn dan password yang baru di set barusan.

Setup OpenVPN di client

Server sudah menginstall OpenVPN dan sudah siap dijadikan VPN server. Selanjutnya, setting untuk client. Pertama kita buat user baru lagi di debian.

Di sini gue mau buat user dengan nama nadiar.

Ganti password user

Login sebagai user tadi di https://192.xxx.xxx.xxx:943/ lalu download dan install OpenVPN

OpenVPN Connect

OpenVPN Connect

Koneksikan OpenVPN dengan user dan password yang telah dibuat sebelumnya, cek IP lo. Sampe di sini seharusnya koneksi udah di encrypt.