Owl Dev. X

Linux and Development Blog

Install Oracle JDK 6 update 35 in Debian Sid

Oracle asked many linux distros to remove their JDK package from their repositories, the latest version was 6.0u26, now the latest is the update 35.

In order to get in installed in Debian Sid, some easy steps must be followed.

1. Download the latest JDK from Oracle Website
jdk-6u35-linux-x64.bin

2. Install debian package java-package

#aptitude install java-package

3. Let run the command to get our downloaded bin file converted into a debian package (this has to be made as a normal user, not root:

$fakeroot make-jpkg jdk-6u35-linux-x64.bin

4. Let’s install our new debian package:

#dpkg -i oracle-j2sdk1.6_1.6.0+update35_amd64.deb 

5. Now let’s update our alternatives:

#update-java-alternatives -s j2sdk1.6-oracle

6. Let’s make sure that we now have our Oracle JDK:

$java -version

This should be our output:

$java -version
java version "1.6.0_35"
Java(TM) SE Runtime Environment (build 1.6.0_35-b10)
Java HotSpot(TM) 64-Bit Server VM (build 20.10-b01, mixed mode)

If we get this, then we got it right.

Hope that works for you.

Trigger onChange Event in IE for radio buttons and check boxes

onChage event in IE doesn’t get triggered until the onBlur event is fired up. This can be easily fixed with the next code:

if ($.browser.msie) {  
  $(function() {  
    $('input:radio, input:checkbox').click(function() {  
      this.blur();  
      this.focus();  
    });  
  });  
}

This code will fire up both events (blur and focus) to each radio button and check box.

This workaround was taken from here

Install Firefox 14 in Debian

We need to enable the Ubuntuzilla Project repository for the latest Mozilla Firefox/Thunderbird/SeaMonkey build.

Add to our /etc/apt/sources.list:

deb http://downloads.sourceforge.net/project/ubuntuzilla/mozilla/apt all main

Then we need to add the GPG key:

apt-key adv --recv-keys --keyserver keyserver.ubuntu.com C1289A29

Then:

#apt-get update
#apt-get remove iceweasel ; apt-get install firefox-mozilla-build

This will remove Iceweasel and install the latest Firefox build.

Hope this works for you :)

Asus G74SX-DH71 Keyboard lights Function Keys in KDE (Debian and Fedora)

I was trying for a while to make my Function Keys (volume, keyboard lights, etc) work in KDE 4.x, and I was finely able to do it with a *funny* workaround. It turns out that the Fn keys works just fine in Gnome, so I dig a little bit and found that the responsible of making this work is a small daemon called gnome-settings-daemon… So it’s just a matter of starting up this daemon in KDE and that’s it.

So, for doing that I just needed to add the next bash file:

$vi ~/.kde/Autostart/gnome-settings-daemon.sh

and add this line:

For Debian:

gnome-settings-daemon

For Fedora:

/usr/libexec/gnome-settings-daemon

we save the file and then add exec permissions

$chmod u+x ~/.kde/Autostart/gnome-settings-daemon.sh

Now you need to logout and login again and that’s it.

For getting the screen brightness function keys working properly, we need to edit our xorg.conf file:

#vi /etc/X11/xorg.conf

Under the section “Device” we need to add:

Option "RegistryDwords" "EnableBrightnessControl=1"

So, at the end, our “Device” section should look similar to:

Section "Device"                                                                                                                     
    Identifier  "Video Card"                                                                                                         
    Driver      "nvidia"                                                                                                             
    Option "RegistryDwords" "EnableBrightnessControl=1"                                                                              
EndSection

You need to reboot in order to get this working.

Hope that works for you. :)

Atmosphere, Airglow and Aurora

This is amaizing……..

The Earth as you’ve never seen it before: Atmosphere, Airglow and Aurora

yumbackend.py taking up 100% of the CPU

I was one of the people with this issue.

How I fixed it?

# yum remove apper

APPER is the cause of the yumBackend.py process.

Once I removed it, the problem was solved.

Since I don’t use PackageKit I had no problem removing this package. I rather use yumex for yum gui.

Slow WiFi connection on Fedora 16 with ath9k driver

This issue should be fixed according to Red Hat’s Bugzilla (Bug #698978), but it’s happening to me … so… searching a bit in FedoraForums I found this workaround (and works)

# rmmod ath9k
# modprobe ath9k nohwcrypt=1

Hope this can truly be fixed in next relases.

Fedora 16 brightness issue in Acer Aspire 4750

I recently bought an Acer Aspire 4750, it’s a cool laptop, the only thing I regret it’s the screen resolution, I’m used to a Full HD Monitor, since I have one at work and in my desktop (still use it)… but, this is not about that.. it’s about a brightness issue in my laptop, since I can’t use the FN key + left and right arrow to lower or upper the brightness out of the box in Fedora 16.

This is the solution:

Edit /etc/grub2.cfg (you obviously need to be root to do so) and at the line that starts with “linux /vmlinuz-…” add this at the end:

"acpi_backlight=vendor acpi_osi=linux" (without the quotes, of course)

If you don’t know how to do this:

vi /boot/grub/grub.conf

So for example your first Fedora block should become:

menuentry 'Fedora (3.2.6-3.fc16.x86_64)' --class fedora --class gnu-linux --class gnu --class os {
	load_video
	set gfxpayload=keep
	insmod gzio
	insmod part_msdos
	insmod ext2
	set root='(hd0,msdos2)'
	search --no-floppy --fs-uuid --set=root 8172b21b-d5f0-44b2-a899-d6c5d91d9311
	echo 'Loading Fedora (3.2.6-3.fc16.x86_64)'
	linux	/vmlinuz-3.2.6-3.fc16.x86_64 root=/dev/mapper/vg_wportalaptop-lv_root ro rd.md=0 rd.dm=0 rd.lvm.lv=vg_wportalaptop/lv_swap rd.lvm.lv=vg_wportalaptop/lv_root quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=es_ES.UTF-8  KEYTABLE=es acpi_backlight=vendor acpi_osi=linux
	echo 'Loading initial ramdisk ...'
	initrd /initramfs-3.2.6-3.fc16.x86_64.img
}

You may want to try this with the first block in your grub2.conf, so if something goes wrong you can always boot with an old kernel and fix it.

Hope it works for you..

Enjoy..

Install xine in Fedora 16

You need to have RPM Fusion repositories enabled.

If you don’t have them enabled yet:

rpm -ivh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm

Now, let’s install xine:

yum install xine xine-lib-extras xine-lib-extras-freeworld

You may also need to install some codecs:

yum install gstreamer-plugins-bad gstreamer-plugins-bad-free-extras gstreamer-plugins-bad-nonfree gstreamer-plugins-ugly gstreamer-ffmpeg libdvdread libdvdnav

And, DVD Playback:

rpm -ivh http://rpm.livna.org/repo/15/x86_64/libdvdcss-1.2.10-1.x86_64.rpm

Enjoy..

VNC Server – Fedora 16

This are the basic steps I use to create a VNC Server configuration in my Fedora 16.

1. Install VNC Server (as root):

# yum -y install tigervnc-server

2. Create a password for our VNC Server (this has to be done as a regular user, not as root):

# vncpasswd

3. Let’s create a start configuration that we can later edit:

# vncserver :1

4. Now that we have just created a basic configuration, let stop our running server:

# vncserver -kill :1

5. Let’s edit our VNC configuration file:

# vi ~/.vnc/xstartup

Let’s comment the actual last line:

#twm &

Now, we need to add a line at the end of the file:

exec gnome-session & # This is for using Gnome

6. Now we can start up again our VNC Server:

# vncserver :1 -geometry 800x600 -depth 24

You can change the resolution at your convenience.

7. Now it’s safe to test and use our running VNC Server:

If you need any more info please refer to this article:

Install VNC Server

Follow

Get every new post delivered to your Inbox.