Tuesday, November 20, 2012

Finding fastest mirror on Quantal

Put these lines inside your /etc/apt/source.list


deb mirror://mirrors.ubuntu.com/mirrors.txt quantal main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt quantal-updates main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt quantal-backports main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt quantal-security main restricted universe multiverse

Sunday, November 11, 2012

MATE desktop environment untuk Ubuntu 12.10 Quantal

Cinnamon telah diulas di sini

Untuk MATE, pilih salah satu mirror;

sudo add-apt-repository "deb http://packages.mate-desktop.org/repo/ubuntu quantal main"

ATAU 

sudo add-apt-repository "deb http://repo.mate-desktop.org/ubuntu quantal main"


Kemudian;

sudo apt-get update
sudo apt-get install mate-archive-keyring
sudo apt-get update
# ini akan pasang pakej asas
sudo apt-get install mate-core
# ini akan pasang pakej lanjutan
sudo apt-get install mate-desktop-environment
sumber

Cinnamon untuk Ubuntu 12.10 Quantal

Bagi pengguna Cinnamon seperti saya (yang biasa menggunakan environment ini di dalam Linux Mint), tentunya menginginkan kosmetik yang sama di dalam Ubuntu 12.10

Ia boleh diperolehi dari laman PPA di sini

Secara ringkas:

sudo add-apt-repository ppa:gwendal-lebihan-dev/cinnamon-stable 
sudo apt-get update
sudo apt-get install cinnamon 


Wednesday, October 31, 2012

Pasang kernel terkini dari PPA

Kernel terkini memang mengujakan, selain dari "bragging right" untuk ada kernel terbaru, ia juga berguna untuk menguji ciri-ciri terbaru pada kernel yang ada di dalam git.

Selain dari kompil sendiri dari git, kita boleh pasang kernel terbaru dari PPA di sini.

Option linux-image-extra, menurut komen di sini adalah untuk kernel yang mengandungi driver-driver seperti untuk KVM dan Virtualbox.

Selamat mencuba!

Monday, October 29, 2012

Grabbing fastest mirror on Ubuntu

Netselect is not included by default, need to use Debian stable's netselect

1- Get it here, no dependency.


2- Find the fastest mirror:

netselect -v -s10 -t20 `wget -q -O- https://launchpad.net/ubuntu/+archivemirrors | grep -P -B8 "statusUP|statusSIX" | grep -o -P "(f|ht)tp.*\"" | tr '"\n' ' '`

3- Alter your sources.list and DONE!

Saturday, October 20, 2012

Ubuntu 12.10 dilancarkan

Ubuntu 12.10 telah dilancarkan. Antara pembaharuan yang dibawa ialah fungsi Amazon search di dalam versi kali ini. Untuk membuang fungsi carian tersebut anda boleh rujuk blog ini

Pendek kata guna arahan:

sudo apt-get remove unity-lens-shopping

Tuesday, September 18, 2012

Buang kernel lama selepas upgrade

Run ni dulu:

 dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed "s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d'
 
Bila dah yakin, baru run:
 
dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed "s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d' | xargs sudo apt-get -y purge

Pastikan anda faham apa yang anda lakukan, segala risiko tidak akan saya tanggung.

Sumber asal

Friday, August 24, 2012

Mount HFS+ partition sebagai read/write

Secara default jika kita mount partition Mac yang menggunakan filesystem HFS+, ia hanya akan beri permission "read only"

Perbincangan secara mendalam tentang hal ini boleh dibaca di sini

Thursday, August 23, 2012

VNC dari Mint(Ubuntu) ke Ubuntu

mac dalam bilik, laptop dalam study room. sebab nak akses current desktop.. thinking of guna VNC. so install tightvnc. sebab malas nak config, each session created by VNC server occupy port 5901...5902.. which is not default.

akses pulak guna xtightvncviewer.. akses default port 5900. otherwise kena specify host:. solution. guna x11vnc utk create vnc session, akses guna xtightvncviewer.

mmg awesome x11vnc ni.. very lightweight.

Wednesday, May 23, 2012

Recovering formatted device with photorec

I recently got problem with my microSD card which I used in my SGS II phone - it tells that my card is not formatted, which is odd. I then use my another device to read, and try to reformat but seems the same message appeared.

Later, I tried to read it from my Linux Mint, it does not detected at all. By using looking at /dev/ seems there's device there.. so I opt to use mkfs to format the card, it worked.

However, that card contained many pictures of my lovely daughter and my wife.

My friend, later suggested to use "photorec", which is conveniently could be installed with [check first]:

$apt-cache search photorec
testdisk - Partition scanner and disk recovery tool

It's in testdisk package

To install:

sudo apt-get install testdisk

Try to play around with the flag, you recovered file could be located as you wish:


It's brilliant. Most of my files are recovered, although it seems scattered hence you need to find your important files by yourselves.

Wednesday, May 16, 2012

The lazy way to download PDF from a website

I usually stumbled to a website where it has many PDF (slides, research papers) and I don't want to bother to download them one by one.

So I simply use lynx with -dump option and grep:
For example:

lynx -dump http://www.utdallas.edu/~zhiqiang.lin/spring2012.html|grep -o "http://*.*.pdf" > list

So in order to download them from the "list", I use curl (or you can use wget too)


for i in `cat list`;do echo $i;curl -C - $i -O;done







Done, easy eh?

Tuesday, May 15, 2012

Compiling Linux Kernel for Ubuntu

Sometimes I felt like I wanted to have a feeling of the new kernel, well my opinion is that Ubuntu and its derivatives aren't designed for such customizations, unless you're a developer.

The notes on kernel compilation is here . Basically for Ubuntu the way is slightly different and seems much easier since you don't have to edit the Grub configurations manually after you created the *.deb file for linux images and headers. Everything will be taken care for you.

My system is now, running Linux Mint 12 [derived from Ubuntu 11.10]

vostro-mint source # uname -a
Linux vostro-mint 3.4.0-1-i5 #3 SMP Tue May 15 00:23:33 MYT 2012 x86_64 x86_64 x86_64 GNU/Linux

vostro-mint source # cat /etc/issue
Linux Mint 12 Lisa \n \l

vostro-mint source # cat /proc/version
Linux version 3.4.0-1-i5 (root@vostro-mint) (gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) ) #3 SMP Tue May 15 00:23:33 MYT 2012

Thursday, May 10, 2012

Terminal record with ttyrec

Do you know that you can record your terminal session with ttyrec?

On Ubuntu/Mint this software can simply being installed by issuing 

sudo apt-get install ttyrec -y

The syntax is basically 

ttyrec [filename]

And your session will be recorded until you issue "exit" command

To replay the session simply use 

ttyplay [filename]


Enjoy!

Wednesday, May 9, 2012

ipraytime, prayer time tool for Muslims

When it comes to prayer times, I usually checked for JAKIM's e-solat page, here . As it's the only trusted source for prayer times in Malaysia, it could have been hit by massive simultaneous access when it comes to the early of the month, because some applications simply grab the data from that website to feed their apps.

I rarely use ipraytime, but it does have features that I believe as accurate it could be. Ipraytime is included in Ubuntu/Mint, within itools package. Hence you can simply install by

sudo aptitude install itools -y 
or sudo apt-get install itools -y

The usage is fairly straight forward

You can get your current position by using latitude marker in google map, or your own smartphone.

Let say your position:3.14004,101.74932

ipraytime -lat 3.14004 -lon 101.74932 -a 1 -m

For Malaysia, usually the angle method is Egyptian General Authority of Survey so the -a flag is meant for that. -m is for monthly schedule.

Or you can simply put your favorite location in your $HOME/.iprayrc with the following format:

City: Ampang,Malaysia
Latitude: 3.13998
Longitude: 101.74940
AngleMethod: 1
UTC: 8

Hence when you invoke 
ipraytime -m

Later on or just ipraytime it will show the position that you have specified.
 
As for the output, some terminals do have problem with showing special characters. But it worked on old school terminals such as xterm and the minimalist mrxvt


Tuesday, May 8, 2012

FUDCON KL 2012

This one not related to Ubuntu, as it is an interesting open source event-plus community driven; sure having this event is a bliss for the rest of us!

Date : May 18-20, 2012
Venue: Asia Pacific University College of Technology & Innovation (UCTI), Kuala Lumpur Malaysia [common open source, community based venue]


Have fun!

Monday, May 7, 2012

Linux based CLI meme generator

I wrote in my personal blog on the usage of "memegen" , a ruby based meme generator.


Read it here

Wednesday, May 2, 2012

Ubuntu for Production

I have been using Ubuntu since its earlier release and never look back after the change. Most of the time I used Ubuntu for my conference paper writings, preparing my presenation slides and so on.

VN6QTF5DGEM2

Sunday, April 29, 2012

Renaming small characters file name to capital letters

Let say you have a small letters filename for a file. And you prefer to convert all of them to capital letters, here goes;

We create several mock files using "touch" command.

najmi@vostro-mint:~/test$ touch aaa bbb ccc

najmi@vostro-mint:~/test$ ls
aaa  bbb  ccc




Use "for" loop as this makes you lazy:

With "verbose" command you should be able to see the output progress:

najmi@vostro-mint:~/test$ for i in *;do mv -v $i `ls $i|tr [a-z] [A-Z]`;done
`aaa' -> `AAA'
`bbb' -> `BBB'
`ccc' -> `CCC'

Done. That's all :)

Thursday, April 26, 2012

Ubuntu 12.04 Precise Pangolin Released

I know many already patiently waiting for the release, here is the link for Ubuntu 12.04 Desktop.

It is LTS - Long Term Support so you can expect a longer support - most suitable for servers.


Tuesday, April 10, 2012

Ubuntu Precise Pangolin 12.04 - Anytime now

Ever downloaded the BETA version of Ubuntu 12.04? What do you think about the features and performance of this version?

Please tell and share with us!

Thanks

Wednesday, February 29, 2012

Samba in Ubuntu (Mint)

I am currently using Linux Mint 12, which is derived from Ubuntu 11.10. The reason is more to personal reasons, but since most of the works are originated from the similar code base so I will keep blogging in this blog. 

I always forgot how to set up a *working* minimalist Samba setup so that I could transfer my files from my Android phones or tablet. Here goes.

In /etc/samba/smb.conf, as root edit as follows:

[Videos]
browseable=yes
readonly=no
create mask=0755
path=/home/najmi/Videos

Later, create a user with smbpasswd command;

smbpasswd -a najmi

Then restart smbd and nmbd:

sudo /etc/init.d/smbd restart
sudo /etc/init.d/nmbd restart

Test:

smbclient -L localhost -U najmi
Enter najmi's password:
Domain=[WORKGROUP] OS=[Unix] Server=[Samba 3.5.11]

    Sharename       Type      Comment
    ---------       ----      -------
    Videos          Disk     
    IPC$            IPC       IPC Service (Samba 3.5.11)
Domain=[WORKGROUP] OS=[Unix] Server=[Samba 3.5.11]

    Server               Comment
    ---------            -------
    VOSTRO-MINT          Samba 3.5.11

    Workgroup            Master
    ---------            -------
    WORKGROUP           

Sunday, February 26, 2012

Using WebDAV with Box.net cloud

You may want to mount you box.net account by your Ubuntu.

What you need;

sudo aptitude install davfs2 -y

This will get DAV file system being enabled.

Later, what you could do is to put your details in davfs configuration file, located at /etc/davfs2/secret

https://www.box.net/dav

Next, you need to mount the box.net through davfs using mount command. 
You can put inside your etc/fstab too, but I found out the system will complain it cannot mount the filesytem (heck, you need to connected to network before you can mount. Wireless connection usually only being enable when you already reached your desktop interface). So I suggest you simply use the command line mount command:

Create mount location first;

sudo mkdir /media/box.net

A bit lengthy, you could paste this to a file, let say mountboxnet.sh and chmod +x, execute by ./mountboxnet.sh later on:
 
sudo mount https://www.box.net/dav -t davfs /media/box.net

You can also find someone else blogged the methods of accessing box.net WebDAV by using nautilus, which is fairly simple too. But I prefer the CLI way :)

Saturday, February 11, 2012

Ubuntu 12.04 bakal mengembalikan antaramuka "Gnome Classic"

Ubuntu 12.04, dengan kod nama "Precise Pangolin", dalam preview di sini bakal mengembalikan antaramuka klasik yang digunakan di dalam Gnome 2. Perkara ini sudah dilakukan oleh Linux Mint, distro derivatif daripada Ubuntu.

Nampaknya pihak Canonical sudah "tersedar" dari lamunan utopia mereka tentang penggunaan antaramuka yang ekstrem tanpa memikirkan hal "usability" di dalam pembinaan antaramuka.

Ini adalah cekupan dari laman blog yang dipetik di atas