Wednesday, November 30, 2011

Unity vs Gnome 3 your choice?

Finally I have to admit that I need to adapt with either Unity or Gnome 3. Although Unity is the default UI for Ubuntu 11.10, I don't feel I like it much. After few experiments with XFCE, KDE, Gnome 3 and the default, I decided to use Gnome 3 instead?

For me because I can simply add more workspaces using add drop, also tweaking the UI - not much  config avail though using gnome-tweak-tools.

As long as I can do my job, it's fine.

Thursday, October 27, 2011

Buffalo Network Area Storage (NAS) LS WXL

I recently bought a 2 bays Buffalo NAS, which costs RM295 without hard disk. HDD that I bought was 1TB 64MB cache for around RM170.

The reason is that I need a reliable backup since I was quite pissed with Dropbox which deleted my important files silently, given that I enable many devices with dropbox, some of them might be deleting the changes that being done on another machine with dropbox demon (at least, from what I suspect. Shouldn't it just commit the NEW changes instead? I am not sure).

This beast, considered cheap, since there are more expensive, enterprise level NAS out there.

Anyway, this box enable FTP,SFTP and SMB by default so you might be happy with that. But for me, I love rsync, and I need root account to do that (don't ask why, this is proprietary device anyway). There are people out there who documented their Debian/Gentoo experience but I might try that later since if anything happened that bricked my device, the warranty is void.

Anyway, to tell you the steps, in summary

1- Get acp_commander
2- Use acp_commander to change your device to emmode
3- You need Windows or Mac unfortunately to "flash" (I hope I'm using the right term) the firmware. As of the current firmware, v1.54, we have to create the /root/.ssh/authorized_keys from the machine that you intend to login..
4- Using LS_UPDATER, push your custom firmware
5- You should be able to log in using your root account

I managed to use rsync and enable NFS.. which aren't by default. So far so good. But I think for normal user, you might want to try another NAS out there.. seriously.

Friday, July 1, 2011

Google+ :)

Google+ with Facebook Theme on Chrome(only?) since it's using script from here

Thursday, June 2, 2011

Converting Media in Ubuntu using FFMPEG

Let's say, we have a media in FLV format that we got it somewhere. Ubuntu's default ffmpeg wasn't compile with conversion option into MP3 (at least from what I understood). In order to make use of FFMPEG to the most is by getting FFMPEG straight from it's farm (terbaik dari ladang, so to speak).

The complete HOWTOS is here

The only thing that I could say important is libmp3lame support, which could allow the conversion. After the steps from the website that I linked before being done, we can check the flag of the compiled, installed FFMPEG;

najmi@vostro:~/ffmpeg-git$ ffmpeg
ffmpeg version git-N-30459-g58fd70b, Copyright (c) 2000-2011 the FFmpeg developers
  built on Jun  2 2011 19:52:29 with gcc 4.5.2
  configuration: --enable-gpl --enable-version3 --enable-nonfree --enable-postproc --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libxvid --enable-x11grab
  libavutil    51.  3. 0 / 51.  3. 0
  libavcodec   53.  6. 1 / 53.  6. 1
  libavformat  53.  2. 0 / 53.  2. 0
  libavdevice  53.  1. 0 / 53.  1. 0
  libavfilter   2. 11. 0 /  2. 11. 0
  libswscale    0. 14. 0 /  0. 14. 0
  libpostproc  51.  2. 0 / 51.  2. 0
Hyper fast Audio and Video encoder
usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...

Use -h to get full help or, even better, run 'man ffmpeg'

As we can see, given the right flag being ENABLED, we can make use FFMPEG to the most. 

Mount Google Documents in Ubuntu

There are several workaround done to have Googledocs in your native directory.

Methood 1:
Add the following PPA in your Ubuntu, I am using 11.04, the deb developed on Lucid, but it worked.
Change the source.list so that it'll use Lucid instead of Natty

root@vostro:/etc/apt/sources.list.d# cat doctormo-ppa-natty.list
deb lucid main
deb-src lucid main

Later, sudo apt-get update && apt-get install gdocs-mount-gtk

Check the installed package;

# dpkg -l |grep gdoc
ii  gdocs-mount-gtk 1.2-0ubuntu2 Mount a Google Docs Directory

Type gdocs-mount-gtk through console or select from drop down menu and it should works!

Method 2:
Use "gmount"

sudo gmount /targetdir

It should work too!


Compile from several resources online.

Wednesday, June 1, 2011

Note to myself: Installing NTOP in Ubuntu

Ubuntu is known with its wonderful tool (which actually Debian's); apt-get/aptitude.

I was having trouble to get my RRD plugin shows the network load graph in Ubuntu, although the apt-get should resolve that automatically. The following is the method that I gathered from various online sources, so that I can refer back whenever I need to do a fresh install.

sudo mkdir /var/lib/ntop/rrd
sudo mkdir /var/lib/ntop/rrd/graphics
sudo mkdir /var/lib/ntop/rrd/flows
sudo mkdir /var/lib/ntop/rrd/interfaces
sudo mkdir /var/lib/ntop/rrd/interfaces/eth0

sudo mkdir /var/lib/ntop/rrd/interfaces/eth1
sudo mkdir /var/lib/ntop/rrd/interfaces/ppp0

sudo chmod -R 775 /var/lib/ntop
sudo chown -R nobody:nogroup /var/lib/ntop/rrd

*note, for eth0, eth1, pp0, you may need to replace that with your own preference, some machine, such as Dell Latitude D430 use wlan0 for its Wifi card.

I also could not understand, this problem was let ignored for several releases, and no action being taken so that ntop could work just straight away with RRD. 

Tuesday, May 31, 2011

Gnome 3, Unity, KDE Plasma or back to old layout?

I tried out the new Unity interface introduced in Ubuntu 11.04, found it hard for me to get used to, so I opt to use the old interface, and stay productive.

Most of the work can simply done through consoles, and the application drop down menu, so I don' really bother changing to the new UI. But it may impress you, right?

Data Analysis Application

You might dealing with data, a lot of them. Now that you want to interpret them all, say, making sense of them and show those figures to your boss. As for my case, for my literature readers.

Data obtained from many sources, say from the existing dataset - or the one that you create on your own. Perhaps, we may be able to make some conclusion or future prediction, as closest to the highest probability as possible.

Ever use Weka?

Weka, is an open source software developed by Univ of Waikato researchers years back. It has been used in many literatures, including my domain, malware research.

Default file format for Weka is ARFF.. and I managed to convert them from Comma Separated Value file, CSV. Tools involved including Clustering, Classification, Association and many others. If you're in Data Mining and Machine Learning; this is your friend. In some sense Pattern Recognition area may need Weka as well.

If you're used to Matlab and Weka, please share your opinion in using both for data analysis. I know many friends who did their research for Image Processing used to Matlab for pattern recognition problem.

Cloud storage dengan Wuala

Anda pernah guna storan cloud seperti Dropbox ataupun jika anda menggunakan Ubuntu, Ubuntu One? Cloud storage seperti Dropbox dan Ubuntu One membolehkan anda menyimpan data di dalam storan lokal dan salinannya dihantar ke storan cloud berkenaan. Untuk tujuan promosi mereka meletakkan had promosi, contohnya Dropbox sebanyak 2 GB dan boleh ditingkatkan ke 8GB sekiranya anda memperkenalkan ahli baru yang berjaya mendaftar melalui anda. (saya dapat 9GB, dah terlebih!). Sekiranya anda ingin menggunakan lagi, anda perlu melanggan, bergantung kepada had penggunaan anda.

Baru-baru ini saya diperkenalkan kepada Wuala, satu storan cloud juga, dan mempunyai mekanisma encryption. Jika anda ingin melanggan, klik sini dan masukkan promo code sewaktu anda mendaftar.

Saya sudah cuba di dalam mesin Ubuntu saya, 64bit dan versi 11.04 

Friday, April 29, 2011

Ubuntu 11.04 Dilancarkan

Salam Sejahtera.

Ubuntu 11.04 baru saja dilancarkan. Dapatkan imej ISO anda di sini.
Shipit CD sudah dihentikan, jadi anda kena mua turun menggunakan talian anda sendiri

Tuesday, February 15, 2011

Papan kekunci rosak!!! Apa nak buat?

Saya mengalami masalah di mana SATU kekunci pada papan kekunci saya telah tercabut dan tidak dapat dibaiki (setelah berkunjung ke Plaza Low Yat, buy a new keyboard, such a nice advice from the shoppers, and it will costs me around RM135, very helpful indeed) dan perlu diganti keseluruhannya. Huruf yang berkenaan ialah huruf "L", di mana kadang-kadang untuk urusan "chat" saya perlu tukar huruf ini dengan kekunciu "|" yang seolah-olah seperti "l".

Sahabat saya telah mengesyorkan cara key remap, di mana kita boleh menukar pemetaan aksara kepada kekunci lain yang jarang digunakan.

Saya pun tidak pernah terfikir tentang perkara ini. Tiba-tiba saya teringat peristiwa semasa saya menjalani latihan Honeynet semasa seminar FIRST di mana juru ajar kami menggunakan mapping "English Britain" walhal kebiasaannya kita di Malaysia kita menggunakan US Keyboard. Yang demikian menyebabkan kesukaran di kalangan kami untuk menaip aksara-aksara yang diingini.

Untuk Ubuntu, saya menemui solusi di Internet yang akan saya sampaikan di bawah:

Baik, katakan untuk huruf "r"

1) Mula-mula, kita kena kenalpasti, apa kod bagi huruf "r" menggunakan arahan "xev"

KeyRelease event, serial 33, synthetic NO, window 0x6e00001,
    root 0xac, subw 0x0, time 30688496, (793,491), root:(795,563),
    state 0x0, keycode 27 (keysym 0x72, r), same_screen YES,
    XLookupString gives 1 bytes: (72) "r"
    XFilterEvent returns: False

dan saya mahu tetapkan pada "Ctrl" pada sebelah kanan papan kekunci:

KeyRelease event, serial 33, synthetic NO, window 0x6e00001,
    root 0xac, subw 0x0, time 30787011, (850,361), root:(852,433),
    state 0x4, keycode 105 (keysym 0xffe4, Control_R), same_screen YES,
    XLookupString gives 0 bytes:
    XFilterEvent returns: False

pada paparan di atas, huruf "r" ditetapkan pada kod kekunci 27
manakala "Ctrl" pada sebelah kanan pada kod kekunci 105

2) Kemudian, kita akan gunakan padankan kekunci Ctrl kanan supaya apabila ia ditekan ia akan memaparkan "r" pada skrin;


 xmodmap -e 'keycode 105=R'

keycode 105 merujuk kod kekunci Ctrl pada sebelah kanan papan kekunci yang jarang digunakan.

Sekarang kita periksa semula "mapping" kekunci ini;

KeyPress event, serial 33, synthetic NO, window 0x6e00001,
    root 0xac, subw 0x0, time 31111455, (931,429), root:(933,501),
    state 0x0, keycode 105 (keysym 0x72, r), same_screen YES,
    XKeysymToKeycode returns keycode: 27
    XLookupString gives 1 bytes: (72) "r"
    XmbLookupString gives 1 bytes: (72) "r"
    XFilterEvent returns: False

KeyRelease event, serial 33, synthetic NO, window 0x6e00001,
    root 0xac, subw 0x0, time 31111572, (931,429), root:(933,501),
    state 0x4, keycode 105 (keysym 0x72, r), same_screen YES,
    XKeysymToKeycode returns keycode: 27
    XLookupString gives 1 bytes: (12) ""
    XFilterEvent returns: False

sekarang anda boleh cuba pada komputer anda, ia berfungsi dengan baik di dalam komputer saya.

Sekiranya tetapan ini hilang sebaik anda "reboot" komputer anda, boleh letak di dalam $HOME/.bashrc anda

Rujukan asal, di sini

Tuesday, January 11, 2011

Cloud Computing dan

GoogleDocs, DropxBox, SugarSync mungkin anda sudah tahu. Pagi ini saya cuba satu perisian baru disebabkan keadaan memaksa saya untuk mengimbas dokumen, walhal saya tidak mempunyai mesin pengimbas. Saya hanya imbas dokumen tersebut dengan fon Android saya, dan muat naik ke Dropbox. Tetapi saya perasan ia juga punya opsyen ke

Bagaimana jika saya hendak guna di dalam Ubuntu? Gunakan opsyen "Connect to Server" pada menu "Places" di Ubuntu anda... dan pilih protokol "WebDAV"

Pada fon Android saya, anda boleh dapatkan client daripada website

Fail yang disenaraikan hanya ada di pelayan, jika anda mahukannya, klik dan urusan muat turun akan dilakukan:

Zenity dan merakam audio/video menggunakan FFMPEG

Zenity membolehkan kita membuat graphical interface dengan mudah untuk skrip kita. Contohnya di dalam hal ini saya ingin merakam gambar melalui kamera web (webcam) saya dengan FFMPEG:

 ffmpeg -f video4linux2 -s 1200x960 -i /dev/video0 -r 30 -f avi -vcodec mpeg4 -vtag xvid -sameq $HOME/Pictures/`echo $(date +%a%H%M%S)`.avi 2>&1|zenity --title "Rakaman guna FFMPEG dan Zenity by Najmi  ::  Simpan ke $HOME/Pictures/" --width 900 --height 600 --text-info;reset

Di dalam skrip di atas, saya merekod video ke dalam format AVI dan ia akan dinamakan mengikut timestamp mula rakam video tersebut. 

Hasilnya, jika kebiasaannya log verbose akan dipaparkan ke terminal, ia akan dipaparkan ke dalam tetingkap luar:


Dalam contoh di atas, skrip FFMPEG saya hanya merakam gambar bisu, disebabkan saya tidak meletakkan mikrofon untuk merakam suara.