ubuntu
Ubuntu Lucid window button layout
I recently upgraded to Ubuntu 10.04 Alpha 3. A few days ago Ubuntu announced a new branding. One of the things they changed is the order of the window button layout. Instead of the expected Minimize | Maximize | Close they changed to Maximize | Minimized | Close. Very confusing and I kept pressing the wrong button each time I wanted to maximize my screen.
Luckely there's an easy way to alter it. Open the Configuration Editor, navigate to /apps/metacity/general and modify the button_layout key to:
menu:minimize,maximize,close
PhpMyAdmin WSOD after changing apache run user
If you've ever installed Apache and phpMyAdmin on Ubuntu 9.04 and you changed the Apache run user and group to your local user (because it's a lot easier when developing that way) you will most likely have encountered a WSOD when loading the phpMyAdmin page.
The reason behind this is that the permissions of those files on your system are no longer correct. Luckily this can easily be solved by changing them back. By default Ubuntu creates a group with the same name as your user so if your user name is foo the group name is most likely also foo. All we need to do is change the group permissions and everything should work again.
sudo chown root:foo /etc/phpmyadmin/htpasswd.setup
sudo chown root:foo /var/lib/phpmyadmin/*.inc.php
Firefox 3.5 Font Fix On Jaunty
Firefox 3.5 has been released a couple of days ago and I started using it at work on my Windows XP machine. I must say I'm quite happy with certain improvements and speed.
This new version will be the default one in the upcoming Ubuntu release but can also be installed on Jaunty. It will be installed as a separate application so it won't mess up any regular Firefox configurations.
The main problem I had was that Firefox 3.5 uses a different implementation when rendering fonts and all the webpages looked boldier, bulkier and crispier and gave me a headache after 5 minutes. Luckely this can be solved easily as I found on the Ubuntu forums.
$ sudo rm /etc/fonts/conf.d/10-no-sub-pixel.conf
$ sudo ln -s /etc/fonts/conf.available/10-hinting-medium.conf /etc/fonts/conf.d/.
$ sudo ln -s /etc/fonts/conf.available/10-sub-pixel-rgb.conf /etc/fonts/conf.d/.
$ sudo dpkg-reconfigure fontconfig
That looks so much better now...
PokerTracker and PostgreSQL installation
I have been playing online poker for quite some time now and I noticed that I recently started playing more and more. I think I went from one or two hours per month to around one hour per day. I also never cared much about my plays. Did I play a lot, did I win a lot, what were my chances when I played certain hands. Across many forums people post advanced graphs of their hands and overall progress so I set out to find something similar. Wine has come far, yet certain Windows applications still cause a lot of problems.
I opted to use PokerTracker. It was recommended by me and has a free 60 day trial. The installation of PokerTracker was easy. Much like any normal Windows application. Troubles came afterwards.
PokerTracker uses a PostgreSQL database to store all the information about your hands. After an hour of trying to install the Windows version of PostgreSQL without any success I gave up and attempted to install PostgreSQL on my Ubuntu installation. Installing stuff on Ubuntu is fairly easy:
$ sudo apt-get install postgresql postgresql-client postgresql-contrib pgadmin3
Done. All I needed to do was set some passwords and PostgreSQL was finished. (Make sure to replace the word mynewpassword with your new password.)
$ sudo su postgres -c psql template1 template1=# ALTER USER postgres WITH PASSWORD 'mynewpassword'; template1=# \q
After I changed the password for within the database I needed to change the password of the Linux postgres user. Easily done as follows:
$ sudo passwd -d postgres $ sudo su postgres -c passwd
For future usage I also enabled the admin pack.
$ sudo su postgres -c psql < /usr/share/postgresql/8.3/contrib/adminpack.sql
Almost done. The only thing we need is a PostgreSQL ODBC driver which we can download from here. Extract the zip file and install it like any other Windows application using Wine.
The last thing I had to do (found here) was to change some registry settings:
wget http://www.holdemresources.net/hr/linuxpoker/pokertracker/ptrack-reg.txt regedit ptrack-reg.txt
When I started PokerTracker it asked me to install PostgreSQL. When I clicked the cancel button it asked me for my PostgreSQL database information. I entered my password since I kept everything else to its defaults and of it went.
