Showing posts with label Ubuntu. Show all posts
Showing posts with label Ubuntu. Show all posts

Tuesday, July 12, 2011

Firefox 5 on ubuntu 10.04 LTS

For people who are using ubuntu 10.04, the default version of Firefox is 3.6. (Seriously?) It's suggested that you update to the latest stable version of ubuntu.

To install the latest "stable" version of ubuntu, add the following ppa repository:

sudo add-apt-repository ppa:mozillateam/firefox-stable


This is nothing more than add a mozillateam-firefox-stable-lucid.list to "/etc/apt/sources.list.d".

Than, do "sudo apt-get update && sudo apt-get upgrade" and you are done.

Tuesday, March 8, 2011

MySQL Remote Access

By default, the mysql (5.x) allows login within localhost. What if you need to access a MySQL database from another computer?

I found this tutorial is quite helpful:
how-do-i-enable-remote-access-to-mysql-database-server

Unfortunately, I still get the following errors
chucheng@laptop:~$ mysql -ufoo -pcrap mysql.ucla.edu
ERROR 1044 (42000): Access denied for user 'foo'@'laptop' to...

After trying several solution, I finally realized that in the statement GRANT ALL ON db_name.* TO foo@'%' IDENTIFIED BY 'PASSWORD'; you cannot skip "IDENTIFIED BY password".

It turns out that you will "override" existing passwords with an empty password if you did not provide corresponding inputs.

Just in case that you still have problems:
Please make sure that
(1) Your bind-address in /etc/mysql/my.cnf has been changed to "real" IP.
(2) your port is listening
netstat -an | grep 3306
(3) You grant remote access permission to the user accounts.
p.s if you encounter any problems when login from localhost, instead of granting foo@'%', please grant foo@'localhost' as well.

Friday, February 4, 2011

Ubuntu Application

I would like to document several apps that, I believe, are very useful as follows. Though there are many choices in WWW. The followings are really handy ones.

Programming Tools:
  • WingIDE (Python)
  • IntelliJ IDEA (Java)
  • Eclipse (C++/Java)
  • Rabbit VCS (Version Control)

MISC:
  • Mendeley
  • Stardict (Dictionary)

Tuesday, February 1, 2011

Brightness Control on T410 (T410s)

I find the brightness control seems to be not working after installing ubuntu 10.04 on my Thinkpad T410s.

Here are two solutions:

(1) Switch to console (CTRL+ALT+F2) and adjust the brightness. Then switch back to GNOME (CTRL+ALT+F7)

(2) Edit /etc/X11/xorg.conf
Under the "DEVICE" section, add the following OPTION
Option "RegistryDwords" "EnableBrightnessControl=1"


Done! Enjoy it!

Tuesday, January 25, 2011

Install Sun Java SDK 6 on Ubutnu 10.04

Since Ubuntu 10.04, Sun(Oracle?) SDK is not existed in multiverse anymore.

If you would like to install Sun Java SDK, you have to use "partner" repository.


sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"
sudo apt-get update
sudo apt-get install sun-java6-jdk


Is that all? Not quitely.

Choosing the default Java to use



Just installing new Java flavours does not change the default Java pointed to by /usr/bin/java. You must explicitly set this:


* Open a Terminal window
* Run sudo update-java-alternatives -l to see the current configuration and possibilities.
* Run sudo update-java-alternatives -s XXXX to set the XXX java version as default. For Sun Java 6 this would be sudo update-java-alternatives -s java-6-sun
* Run java -version to ensure that the correct version is being called.

You can also use the following command to interactively make the change;

* Open a Terminal window
* Run sudo update-alternatives --config java
* Follow the onscreen prompt

Ref: https://help.ubuntu.com/community/Java

Wednesday, December 1, 2010

Windows 7 HotKey in Ubuntu

As a bi-OS user, I am always confused with the hot-key setting while I switch between Operating System. No offense, while I said bi-OS user, I refer to Windows 7 and Ubuntu Lucid. (Not Mac OS).

Some hotkeys introduced in Windows 7 are very userful for myself. For example, Windows + Left / Right / Up / Down

If you never try above hotkeys, try it on a Windows O/S, and you will know what would happen.
Long story short, I would like to resize my windows the the left/right window. What should I do?

(1) You have to install wmctrl package
 sudo apt-get install wmctrl


(2) Open "System"-->"Preference"-->"Keyboard Shortcuts".
Bound Windows + Left to ==> wmctrl -r :ACTIVE: -b remove,maximized_vert,maximized_horz;wmctrl -r :ACTIVE: -e 0,0,20,1920,1150
Bound Windows + Right to ==> wmctrl -r :ACTIVE: -b remove,maximized_vert,maximized_horz;wmctrl -r :ACTIVE: -e 0,960,20,960,1150

To Maximize a windows:
Bound Windows + Up to ==> wmctrl -r :ACTIVE: -b remove,maximized_vert,maximized_horz;wmctrl -r :ACTIVE: -e 0,0,20,1925,1150


Would you like to learn more?
Read here: wmctrl tutorial

Tuesday, November 23, 2010

Where is my "Ctrl + Alt + Backspace" ?

After installing ubuntu 10.04, I quickly realized that CRTL-ALT-F1 (for opening a terminal) and CRTL-ALT-BACKSPACE (for killing X-server) are gone. Luckily, here is the solution I found:

Enabling Ctrl-Alt-Backspace for Ubuntu 10.04

  1. Select “System”->”Preferences”->”Keyboard”
  2. Select the “Layouts” tab and click on the “Layout Options” button.
  3. Select “Key sequence to kill the X server” and enable “Control + Alt + Backspace”
Enjoy your hot keys :)

Thursday, October 14, 2010

Move window buttons (Min, Max, Close) back to right in ubuntu 10.04

One of the most controversial change in ubuntu 10.04 is to have window buttons on the left side. Although this change favors many mac(apple) users. As a user worked in dual O/S, windows 7 and ubuntu, the change is somehow inconvenient. Here I explain how to move them back. (The min, max, and close button)

1. Open the configuration editor of gnome.
gconf-editor


2. Click on the + button next to the “apps” folder, then click “metacity” in the list of folders expanded for apps, and then click on the “general” category. The button layout can be now changed by editing the “button_layout” key.

3. Change it to:
menu:minimize,maximize,close


Save, close, and you are done. (Restart X Window to take effect)