Play DVD on Ubuntu Gutsy

Thursday, February 28, 2008 | Labels: | 0 comments |

I have been wanting to post this for a while, but I don't know if I should. Over at Ubuntuguide, there is a mention on how to do this. But I eventually found another way - a very simple way to achieve this. I have mentioned before about VLC Media Player, how much I prefer that one compared to Totem. Not to say I hate Totem, it's just that Totem didn't work very well for me.

What you need for DVD playback is actually, VLC! Let's install it.

sudo apt-get install vlc


I know, tonnes of packages, just do it already :P

Launch vlc.

Applications > Sound & Video > VLC Media Player


or if you like CLI

vlc


Make sure that you have already inserted your DVD movie. Now on VLC, go to

File > Open Disc...


Make sure that the Device Name is correct, and then press OK. Tada! Instant DVD playback!

Ubuntu animals :P

Saturday, February 23, 2008 | Labels: , | 1 comments |

Warty Warthog


Hoary Hedgehog


Breezy Badger


Dapper Drake
(male ducks are called drakes)


Edgy Eft


Feisty Fawn


Gutsy Gibbon
( this is what I am using!)


Hardy Heron
(Oh, I can't wait!)


Intrepid Ibex
(just look at those horns!)

And the upcoming Ubuntu 9.04...

......



......



......


......


Jeffrey Johar!!!

Ubuntu 8.10 - Intrepid Ibex

Thursday, February 21, 2008 | Labels: | 3 comments |

Yes, people, this is an ibex!

The next iteration of the Ubuntu Linux is now known to be Intrepid Ibex. If you noticed, it seems like we are going in alphabetical order (since Dapper Drake).

  • Dapper Drake (6.06)
  • Edgy Eft (6.10)
  • Feisty Fawn (7.04)
  • Gutsy Gibbon (7.10)
  • Hardy Heron (8.04)
  • Intrepid Ibex (8.10)

And maybe some of you don't know that, the first digit in Ubuntu version represents the year it was released, while the last 2 decimal points is the month it was released.

Now you know when we are going to get our hands on the Hardy Heron (8.04)!

Latest Memtest86+ for Ubuntu?

| Labels: | 0 comments |

If you noticed in Ubuntu, the file /boot/grub/menu.lst has an entry for Memtest. It's using Memtest86+ v1.7. The latest version is v2.0 which was released on February 8th, 2008.

To get the latest memtest is easy. Just download the Pre-Compiled Bootable Binary from here.

Unzip the archive, and copy the bin file over to /boot/. You are going to need root privilege to do this, so:

sudo mv memtest86+-2.00.bin /boot/


We have to edit Grub's menu.lst so that the new Memtest shows up in the Grub menu.

sudo gedit /boot/grub/menu.lst


Put this end at the end of the file:

title Ubuntu 7.10, memtest86+2.0
root (hd0,2)
kernel /boot/memtest86+-2.00.bin
quiet


Save it, and close the file. To test, you can reboot, press escape when Grub is loading and choose the new entry and the Memtest will start as usual :)

Chrono Cross - Another way to waste time

Monday, February 18, 2008 | Labels: | 0 comments |


Actually, gaming is one of the best way to waste my time. Not really wasting them, but its just one of my hobbies (other than looking up the Internet on how to do things I have always done on Windows but on Linux).

And the game I have been playing lately is Chrono Cross! Its a PSX (short for Playstation) game, that I play on my PSX emulator; the pSX (legally, you need to own a PSX in order to play games on its emulator). pSX on Ubuntu is fairly easy to get; just follow the instructions here.

Anyway, its an old game, from the year 2000 if I am not mistaken but the gameplay is so good that I am on my 2nd playthrough already!

The gameplay is evolved around elements. Each element has their own set of spells consisting of offensive, defensive and support types. Each character has their own innate elements; so to speak - their element signature. One character may be a RED innate; while another is a BLUE innate (and there's more than a dozen characters to choose from for your 3-man party!). There are 6 elements; RED, BLUE, GREEN, YELLOW, BLACK and WHITE. Each element has their own opposite; RED to BLUE (vice versa), GREEN to YELLOW (vice versa) and BLACK is to WHITE (vice versa). So you have to set up your strategies properly in order to get the most efficient way to eliminate your enemies!

The graphics is so-so, but still one of the best on this old platform. Audio is great, and storyline is awesome! You can check out the screenshots here.

I suggest anyone who cannot play (or cannot afford the hardware :P) the latest games, might as well travel back in time, and look up those awesome great titles that you can play on an emulator, and have some fun time playing old games with great gameplay! You won't regret it!

With that said, game on!

HD DVD is Dead

Sunday, February 17, 2008 | Labels: , | 0 comments |


The high definition war went on for some time now. Now it has ended. The winner is Sony's Blu-ray. I never took the time to update myself when the war was raging, but I realized a few things that smells fishy to me. Like the huge price drop of HD DVD players.

Anyhow, Toshiba announced that they are dropping the format. The first announcement was in Japan. I just knew that the market share of Blu-ray is already 90% in Japan. Maybe now if you go to your nearest hardware electric and electronics retailer, you will notice that HD DVD players are so damn cheap; but don't bother buying it. Save your money and get a Blu-ray player. HD DVD is dead. Period. No future.

Isn't it a great time to get a PS3? :D

Evolution Summary and Folder Mismatch

Friday, February 15, 2008 | Labels: | 0 comments |

If you have been an avid user of Evolution (it's an email client), you might have encountered this bug before. This bug has been around for quite some time and was never completely fixed; or so I was told. Anyway, if you are stumped with this bug, fortunately there is a workaround.

1. Terminate Evolution.

2. Run these lines in terminal.

cd ~/.evolution/mail/local
cp Inbox.ev-summary ~
rm Inbox.ev-summary


3. Run Evolution and the error shouldn't be there anymore.

As usual, big thank you to UbuntuForums :)

What I did on Valentines Day 2008

| Labels: | 1 comments |

I was at Sunway Pyramid last night; waltzing towards TGV to get my movie tickets. I booked tickets for the movie Jumper! Isn't it nice to go for a romantic movie session with...

with...

with......

2 GUYS AND A CHICK!!!


And everyone else... let me tell you, EVERYONE else at the cinema was with their partners. Here I am with 3 of my colleagues! COLLEAGUES! AS IF I HAVE NOT SEEN ENOUGH OF THEM ALREADY!

AND YOU WANT TO KNOW WHAT I DID BEFORE THE MOVIE ON VALENTINES DAY???

I WAS PLAYING DAYTONA AT PYRAMID ARCADE!!! (*^(&^&#^$ *(&(*&(*^#&$^(&@#$(^(&@#$^(&#@^$

&*^@#$*&@#^$*&^@#$*&^@#*&$^)!@*(&#$()@*$)#(@&$(*#^%&(^&(%!!!!!!!!

After the movie? Well I bet everyone else was mushy mushy with their partner but we...

had TEH TARIK AT RESTORAN BIDARA TALKING ABOUT WORK!!!

WORK, I TELL YOU! WE TALKED ABOUT SAP!!! UNTIL 1.30AM!!!

Urgh, where is my life? I must have misplaced it somewhere in the course of becoming a geek...

Valentines Day - Pick up lines

Thursday, February 14, 2008 | Labels: | 4 comments |

Today is Valentines Day, and its already the 3rd time when someone told me that I shouldn't celebrate it because its against our religion.

No comment.

Anyway, putting that aside (maybe I shouldn't have mentioned about that matter above), I was listening to Fly FM while driving to the hospital (a friend of mine fell sick, pity her) the DJ mentioned a pick up line which seemed rather interesting to me.

Are you a parking ticket? Coz you've got fine written aaalll over you!


Which I then laughed my ass out of the car (people must think that I am crazy or maybe they think I hate my car so much). Being the usual Internet junkie I then googled on 'famous pick up lines' and stumbled upon this list of pick up lines.

Have a go, it made me smile. Reminds me how creative people can get when they want something.

Oh, Happy 'Spending-Time-With-Your-Partner' Day!

My Ubuntu Gutsy won't boot!!!

Wednesday, February 13, 2008 | Labels: | 0 comments |

So here's the story. I never had a boot splash for my Ubuntu on my laptop. A simple googling, I found out that I had to modify my usplash.conf.

sudo gedit /etc/usplash.conf


# Usplash configuration file
xres=640
yres=480


I changed the resolution to 640x480 (even 800x600 won't work). After that I regenerated the init file.

sudo update-initramfs -u -k `uname -r`


The good thing about this tool is; it creates a backup copy of your /boot/initrd.img-2.6.22-14-generic. The backup file name has .bak at the end.

After that was done, I rebooted my laptop and...

KERNEL PANIC!!! It won't mount the root filesystem! Argh!!!

A few weeks ago, I created a bootable Ubuntu on a thumbdrive. So I went off looking for the owner of the thumbdrive. Luckily he was around and after a few minutes, I was using my laptop running on Ubuntu LiveTHUMBDRIVE.

First, to look for my root partition to mount.

cd /dev/disk/by-id && ls -l


And there were a bunch of things like:

ata-IC25N020ATMR04-0_MRG157K1DAS42H
ata-IC25N020ATMR04-0_MRG157K1DAS42H-part1
ata-IC25N020ATMR04-0_MRG157K1DAS42H-part3
ata-IC25N020ATMR04-0_MRG157K1DAS42H-part4
scsi-1ATA_IC25N020ATMR04-0_MRG157K1DAS42H
scsi-1ATA_IC25N020ATMR04-0_MRG157K1DAS42H-part1
scsi-1ATA_IC25N020ATMR04-0_MRG157K1DAS42H-part3
scsi-1ATA_IC25N020ATMR04-0_MRG157K1DAS42H-part4


But of course I couldn't remember which one is my root FS. So I tembak-tembak (guessing game) with the mount command. I already know for sure that my FS is ext3.

mkdir ~/hdd
sudo mount -t ext3 ata-IC25N020ATMR04-0_MRG157K1DAS42H ~/hdd


Failed, and then:

sudo mount -t ext3 ata-IC25N020ATMR04-0_MRG157K1DAS42H-part1 ~/hdd


Failed, and...

sudo mount -t ext3 ata-IC25N020ATMR04-0_MRG157K1DAS42H-part3 ~/hdd


And it worked!!! Yatta!!!

So I accessed my root partition.

cd ~/hdd


I thought that the initrd is corrupted or something, so I went off and do:

sudo mv initrd.img-2.6.22-14-generic initrd.img-2.6.22-14-generic.backup2
sudo mv initrd.img-2.6.22-14-generic.backup initrd.img-2.6.22-14-generic


After that I rebooted...

And I can boot again! Yea!!! I recreated the initrd file.

sudo update-initramfs -u -k `uname -r`


And rebooted again.

And finally!! I finally get my Ubuntu splash screen!! I had a fair share of experience in Windows in situations where I couldn't boot Windows. Common solution would be to reboot into SAFE MODE and try to restore a RESTORE POINT. If that fails, its time to backup my files and reformat. I am so glad I don't have to go through that in a Linux environment.

Happy Linux-ing!

VPNC in Ubuntu

Tuesday, February 12, 2008 | Labels: | 0 comments |

This is actually an update from my earlier post.

There is actually a way to do this in GUI (which is far easier to maintain; and definitely the preferred of many users that I know).

First you need to install something.

sudo apt-get install network-manager-vpnc

Let it install whatever dependencies it needs. After its done, click on your network icon on your top panel.


Choose to Configure VPN...



Choose vpnc

Fill up the Connection Name; it can be anything, doesn't matter. After that click Forward.

After that you are done! Click on Apply.

Click on Network Connections, and choose your newly created VPN connection.

It will prompt for your username and password to proceed.

I hope that's simple enough! :D

Gnome Totem hates me

Friday, February 8, 2008 | Labels: , | 0 comments |

I was never a fuss when it comes to media players. When I was a full time Windows user, I used Windows Media Player, naturally. After that, I started using Windows Media Player Classic for its lightweight feature. When I started using Ubuntu about more than a month ago, I was fine with Totem. Until...

Totem won't SEEK PROPERLY! I like to rewatch my videos over and over; only watching the best parts. Sadly, Totem couldn't do seeking properly. As a workaround, I found out that I could seek by using the mouse wheel, which was okay. After that, it started to have this color issue for me.

Why do you hate me so much, Totem???

I then found out I can adjust the color of the video; like hue, saturation, brightness and contrast. After a few videos, I realized that I have to adjust the video settings every other time!!! This is just way beyond pissed. I had enough; and this is what I did.

I installed VLC. I have known VLC quite a while back, and I know it will work well. So I went off and installed VLC Media Player.

sudo apt-get update && sudo apt-get install vlc


And then I changed my Nautilus setting to open ALL video files with VLC :D

Right click any video files > Properties > Open With > Add vlc

And now I am a happy Ubuntu user again! :D

uTorrent on Ubuntu 7.10 (Gutsy)

Thursday, February 7, 2008 | Labels: | 0 comments |

uTorrent has always been my favorite torrent client. But one thing it lacked was, it wasn't able to bypass my ISP's traffic shaping. Since then, I jumped the bandwagon for a ride with Deluge. Deluge runs great on Ubuntu; thank you so much for their development team for coming up with a package for Ubuntu.

If you want to use uTorrent on Ubuntu, fret not. There is a way. If you read the download page carefully, it does say:

For Wine, Windows 95 (Winsock2), 98/ME, NT/2000, XP, 2003, and Vista.


So what are you waiting for?? Just download uTorrent, browse to where you downloaded it, and Wine it away!

wine utorrent.exe


Once its installed, Wine the executable. It should be available in your Program Files folder ;)

wine ~/.wine/drive_c/Program\ Files/uTorrent/uTorrent.exe


Here is a screenshot of it:

ABAP: Efficient ABAP-ing

Wednesday, February 6, 2008 | Labels: | 0 comments |

I just discovered this in one of our programs in our system:

loop at i_vbel.
select vbeln into i_allo-vbeln
from vlccuorder
where vguid = i_vbel-vguid.
endselect.
append i_allo.
endloop.


For sake of simplicity, let's assume that all internal tables in my codes have its own header line (though this is not the best practice, so don't practice this).

That piece of code above is really not the best way to do it. What it intends to do is to get the latest vbeln for a specific vguid from table vlccuorder (this table is only available if you have the IS-VMS module set up in your SAP installation).

The 3 main fields in the table vlccuorder in order to get the records you need are:
vguid - Global Unique Identifier
tstmp - the timestamp
vbeln - Sales Order Number

So, if you go around it like so:

*-- to get latest vbeln for each vehicle
select tstmp vguid vbeln
from vlccuorder
into table i_all_so
for all entries in i_vbel
where vguid = i_vbel-vguid.

*-- sort so tht it is grouped by vehicles; with tstmp descending
sort i_all_so by vguid tstmp descending.
*-- get latest only
delete adjacent duplicates from i_all_so comparing vguid.


... your program will run more efficiently and easier to be understood by future programmers. SELECT ENDSELECT is really inefficient and will only hog up your system's resources (furthermore you are doing it in a loop!); unless you are VERY VERY SURE that you will end up only with one record. Like so:

select name1
from kna1
into w_name1
where kunnr eq '6000123456'.
endselect.


Why not use SELECT SINGLE?

select single name1
from kna1
into w_name1
where kunnr eq '6000123456'.


Whichever is okay for me. This matter is still open for debate though.

Running Windows XP Pro on Ubuntu with Qemu and KQemu (Qemu accelerator)

Tuesday, February 5, 2008 | Labels: | 3 comments |

Okay, that's a lengthy title. Sorry about that. I couldn't figure out a better one.

Anyhow, this is a guide/how-to on how to run Windows XP Pro on Ubuntu Gutsy Gibbon using Qemu. I am going to go through this section by section; so that you don't get lost along the way.

Installing Qemu

This part is very straightforward.

sudo apt-get install qemu


Done.
Installing KQemu

This part is not as simple as the previous one. You actually don't need this to get Windows up and running on Ubuntu; but you need this so that it runs smoother. If not, you will be looking at 3 frames per second slide show which is a real pain the ass when you are actually trying to be as productive as you can.

First, let's install a few things first shall we?

sudo apt-get install module-assistant kqemu-common kqemu-source


Please note that you might already have module-assistant.

After that you need to compile and install the kqemu module; like so:

sudo module-assistant prepare
sudo module-assistant auto-install kqemu-source


When that is done, we need to modprobe it (so as to make it available to be used):

sudo modprobe kqemu


Change the permission so that other users can use it.

sudo chmod 666 /dev/kqemu

You can make sure that the permission is correct and that it is already up and running:

ls -l /dev/kqemu


Okay, that completes the installation of Kqemu. I don't plan on emulating Windows so often so I didn't make this as a startup. If you need it to be on startup, you can refer to a guide here.

Installing Windows XP Pro

The installation is going to take FOREVER. I warned you. So do it before you go to sleep. I did it on the day I had to go somewhere else; and it finished when I got back which is just nice.

First, let's create a hard disk image. Yes, you don't need a partition to install Windows.

qemu-img create windows.img 3500M


3500M means 3500MB or 3.5GB. It means you have just created a hard disk for Windows with a size of 3.5GB.

Next, let's boot into Windows! I am using a CD Image here.

qemu -boot d -cdrom /path/to/cd_image -hda /path/to/hdd_image


.. and proceed with the lengthy installation.

You can also do this with a CD. Instead of using the above command, use this one instead.

qemu -boot d -cdrom /dev/cdrom0 -hda /path/to/hdd_image


You can replace /dev/cdrom0 with your own CD drive if you need to. When the installation is done. Just shutdown Qemu by closing the window.
Booting Windows XP Pro

Use this:

qemu -boot c -hda /path/to/hdd_image


... and you shall boot into Windows normally :D

By default, the RAM for the guest OS is only 128MB. You can give it more RAM by specifying a boot flag.

qemu -boot c -hda /path/to/hdd_image -m 256


Sharing folders between Windows and Ubuntu

Before that, you should boot Windows with NIC enabled! (NIC = Network Interface Controller)

qemu -boot c -hda /path/to/hdd_image -net user -net nic


This is the least boot flag you should have. You can add more if you want to.

You need SAMBA! Configuring Samba is a different matter. You can refer here for the easiest method to configure Samba.

Now when you share a folder, make sure to give the folder write permission. From Windows, press Window + R, type in:

\\10.0.2.2\name_of_shared_folder


You should then be able to see the shared folder and dump files there :)
Easy way to choose boot flags/parameters

There's this GUI tool called qemu-launcher. Install it.

sudo apt-get install qemu-launcher


After installed, you can launch it from Applications > Accessories > Qemu Launcher. It's so much easier to boot from here and furthermore, you can enable audio for your Windows! :D

I think that is enough to get you up and running Windows on Ubuntu. Drop me a comment if you run into any issues and I might be able to help.

References:
1. https://help.ubuntu.com/community/WindowsXPUnderQemuHowTo
2. http://ubuntuforums.org/showthread.php?t=39513

Coolest things that you can do on Linux...

| Labels: | 2 comments |

but not on Windows or Mac

A good friend of mine just dropped this off from Pidgin to have a read on this article. It is very interesting and I had quite a laugh especially this one:

20. Browse the web while the OS is being installed!


LOL :D

Guess what am I doing?

Sunday, February 3, 2008 | Labels: | 0 comments |


I am trying to emulate Windows XP Professional on Ubuntu Gutsy Gibbon! Screenshot above is from Qemu with Kqemu enabled :)

HOWTO: .img to .iso in Linux Ubuntu

Friday, February 1, 2008 | Labels: | 0 comments |

I just got a CD image from a friend and it comes in the format of .IMG. After some googling (shows how big Google has got :P), I found out that this sort of CD Image is usable by CloneCD; a Windows software.

But I do not want to burn it into a CD or anything, I just want to convert it into an ISO image and be able to mount it. A little more googling and there is a Windows software to convert IMG into ISO; MagicISO. It's a shareware, so I was only able to use this for a trial period; but it was enough to convert IMG to ISO.

So, it's WINE time!!!

1. Installing Wine. It's best to use the latest version. Follow these instructions from Wine website. This should be easy enough :)

Adding the WineHQ APT Repository:

First, open a terminal window. Then add the repository's key to your system's list of trusted APT keys by copy and pasting the following:

wget -q http://wine.budgetdedicated.com/apt/387EE263.gpg -O- | sudo apt-key add -

Next, add the repository to your system's list of APT sources:

For Ubuntu Gutsy (7.10):
sudo wget http://wine.budgetdedicated.com/apt/sources.list.d/gutsy.list -O /etc/apt/sources.list.d/winehq.list

For Ubuntu Feisty (7.04):
sudo wget http://wine.budgetdedicated.com/apt/sources.list.d/feisty.list -O /etc/apt/sources.list.d/winehq.list

For Ubuntu Edgy (6.10): *64-bit packages not available*
sudo wget http://wine.budgetdedicated.com/apt/sources.list.d/edgy.list -O /etc/apt/sources.list.d/winehq.list

For Ubuntu Dapper (6.06): *64-bit packages not available*
sudo wget http://wine.budgetdedicated.com/apt/sources.list.d/dapper.list -O /etc/apt/sources.list.d/winehq.list

For Debian Etch (4.0):
sudo wget http://wine.budgetdedicated.com/apt/sources.list.d/etch.list -O /etc/apt/sources.list.d/winehq.list

Then, you can install Wine from WineHQ like it were any other package, such as by using the Synaptic Package Manager under System->Administration. Alternatively, you can install from the terminal by running 'sudo apt-get update' to update APT's package information and then 'sudo apt-get install wine'.

2. After that is done. Get the shareware version of MagicISO from here.

3. Installing MagicISO. Browse to where you downloaded the Windows installer. Mine's in my Home.

cd ~


4. Change the permission to executable.

chmod +x Setup_MagicISO.exe


5. Give it some Wine goodness so that it gets a little drunk :P

wine Setup_MagicISO.exe


6. Finish up the installation

7. Launching MagicISO!

cd ~/.wine/drive_c/Program Files/MagicISO
wine MagicISO.exe


8. Once MagicISO is launched, go to Tools > Convert to start converting IMG to ISO; or any type of CD image to ISO!

Of course you can always create a shortcut on your Desktop so that its easy for you to launch it next time :)

Good luck! :D

Note: There is a Linux program to convert IMG to ISO called KISO. It's a KDE program; and since I am running Gnome, I had to download TONNES of packages. Good news for KUbuntu users though :)

HOWTO: Mounting ISO in Ubuntu

| Labels: | 0 comments |

In Windows, this is a very tedious thing to do; because you need to install a certain software so that it can create a virtual drive for you. After that, you still need to restart your PC to be able to mount the ISO image.

Not so in Ubuntu or other Linux distros.

1. Create a folder to mount that ISO.


mkdir ~/myiso


2. Mount the ISO.

sudo mount -o loop image.iso ~/myiso


3. Browse your ISO.

cd ~/myiso
ls -l


Once you are done, you can unmount that ISO image by

sudo umount ~/myiso


Very useful when you are restoring a backup image.

Happy Linux-ing! :D