Category: Linux
HP Pavilion Dv3t and Ubuntu 9.04 x64
by cbrodt on August 29th, 2009
in Linux
Got a new lappy the other day to replace the sad Toshiba. It had developed a problem where sound events were causing the wireless card to fail (yes, I know that sounds crazy). And I was generally unhappy with it’s overall heft and refusal to have power management capabilities. I had originally looked at getting a Lenovo, but they were kind of pricey and didn’t seem anymore likely to work with Linux then the HP’s I was looking at. So far everything is great with the laptop, though there were a few things I had to fiddle with:
Sound
The sound card didn’t work with the version of ALSA that came with Jaunty; though, there’s a lot of commotion about it not working real well with a lot of cards so upgrading was fairly well documented. I went here. There’s also an option I had to set in “/etc/modprobe.d/alsa-base.conf”
options snd-hda-intel model=hp-m4 enable_msi=1
So far that seems to have done the trick, though sometimes on suspend/resume sound doesn’t come back; probably restarting alsa would do the trick.
Wireless
Mine came with a generic wifi card that required the ath9k driver. I was real worried when I saw that because I had previous bad experience with the Madwifi/Ath5k drivers on the Toshiba. However, the 9k series seems to be much better, and I haven’t experienced the dropped signals that can only reconnect after a restart that I was having witha the Toshiba. You’ll have to grab a newer kernel then what comes with Jaunty by pulling from the backports:
sudo apt-get install linux-backports-modules-jaunty-generic
Restart and you’re good.
Video
I agonized over this for days: The NVIDIA Geforce G 105M was unsupported by the binary drivers when I ordered the lappy. I took a gamble that support would reach Linux soon. Well, my gambit paid off and Nvidia added support in their latest beta release of the proprietary driver. Follow this link to the NVNews forum and grab the highest numbered installer. Installation is pretty straight-forward from there; shutdown X and run the install as root (you’ll probably need to run “chmod ugo+x” to grant it execution privileges).
And that’s pretty much it. Everything else just seems to work, including the brightness controls and other random function keys. I’m not too crazy about the keyboard, but I’m not a big fan of many laptop keyboards. I highly recommend it to any Linux users
UPDATE:
There’s a funky issue with the battery “disappearing” after a resume from suspend. It appears to be a known issue with the HP laptops and the kernel devs appear to have addressed it for another model. If I get a chance I’ll try rolling my own kernel and seeing if the fix works for my laptop.
UPDATE of UPDATE
Weird. I protected this post after I updated it. Oh well, here it is again
OCI8+PHP+Apache/Ubuntu 8.10 Intrepid HOW TO (Part 2)
by cbrodt on April 25th, 2009
in Linux
Last time we left off where we phpize the oci8 package. Now we’re going to compile and install it
At this point, you’ll probably want to set some environment variables in bash. There’s some debate about whether you need to set the $ORACLE_HOME or not, or whether you should put environment variables in /etc/profile or a script in /etc/profile.d. I’m not going to get into that debate but if you have a preference or concern then be my guest. For all others:
root@sonicroot@sonic:/opt/oracle/src/oci8-1.3.4# cd /etc/profile.d/
root@sonic:/etc/profile.d# vi oracle.sh
and put this in the file:
Code:
LD_LIBRARY_PATH=/opt/oracle/instantclient | |
TNS_ADMIN=/opt/oracle/instantclient | |
SQLPATH=/opt/oracle/instantclient | |
PATH=$PATH:/opt/oracle/instantclient | |
| |
export LD_LIBRARY_PATH | |
export TNS_ADMIN | |
export SQLPATH | |
export PATH |
This will setup the oracle environment variables every time someone logs in. For now, you can either setup these variables by hand at the commandline or make this script executable and run it with sh ./oracle.sh
EDIT: I’ve become hopelessly lazy with this guide and so I’m just going to cut it sort and sweet. Basically the problem I had was that I could get the PHP CLI to connect to the oracle server but I couldn’t get the Apache instance to access Oracle. Solution? Go to /etc/apache2 and edit the envvars file. Enter the following lines:
Code:
export LD_LIBRARY_PATH=/opt/oracle/instantclient | |
export TNS_ADMIN=/opt/oracle/instantclient | |
export SQLPATH=/opt/oracle/instantclient |
I’ll give you some references. First, is the how-to in the Ubuntu forums. It was what I basically followed for compiling oci,etc.
Ubuntu OCI guide
Next is a site I found useful, though it is focusing on OCI and Ruby. I believe it tipped me off to the Apache variables fix I just showed you.
Ruby and OCI
There you go. Leave a comment if you have more questions
OCI8+PHP+Apache/Ubuntu 8.10 Intrepid HOW TO (Part 1)
by cbrodt on December 25th, 2008
in Linux
SRSLY GUYS!
Man, I’m terrible with the blogging. Basically I’ve been working, dealing with boats (more on that later), and other nonsense. But for now we have a wonderful how-to guide for something that took me FOREVER to work right on my box. Oracle doesn’t officially support Ubuntu, and there’s quite a bit of half working solutions out there, and virtually none for making sure your mod-php-apache scripts will run correctly. This will hopefully fix that.
My setup involved a rather plain Intrepid box, VPN into my work to access Oracle databases and SVN, and a local Apache webserver to use the SVN checkout. I won’t cover VPN, as the new Network Manager for Intrepid makes using pptp VPN a lot easier to setup. Also this is NOT a guide about how to install oracle on your Ubuntu box. I don’t have any requirement for that at the moment and there seems to be several good guides out there that will likely apply to Intrepid.
Also, this guide is no more then a combination of several guides plus my own contributions. Credit will be given here:
First login as a root user using sudo
user@sonic:~$ sudo -i
Install a few necessary packages. The OCI module will have to be built from sources in PECL so we’ll need a couple of build packages:
root@sonic:~# apt-get install apache2
root@sonic:~# apt-get install php5-common php5 php5-dev libapache2-mod-php5 php5-cli
root@sonic:~# apt-get install build-essential php-pear libaio1
Some guides say you need to install libaio-dev. If you have problems, then do it.
Next we’re going to download some stuff from Oracle. I use Intrepid x64, so I went here. You’ll want to grab at least the basic_client and the SDK. I grabbed the sql plus libraries as well; seriously, you don’t use sqldeveloper for your db scripting do you?
The latest version of the client as of this writing is 11.1.0.7.0. Create a directory /opt/oracle and move all the zip files there and then run this command:
root@sonic:/opt/oracle# unzip \*.zip
You’ll get a fancy directory called instantclient_11_1 and you’ll rename it to instantclient. Go into that directory and make some symbolic links:
root@sonic:/opt/oracle/instantclient# ln -s libclntsh.so.11.1 libclntsh.so
root@sonic:/opt/oracle/instantclient# ln -s libocci.so.11.1 libocci.so
So we’re down to the business of compiling the php oci module. Run mkdir /opt/oracle/src, cd to the directory you just created, and then:
root@sonic:/opt/oracle/src# pecl download oci8
root@sonic:/opt/oracle/src# tar xvf oci8-1.3.4.tgz
root@sonic:/opt/oracle/src# cd oci8-1.3.4
root@sonic:/opt/oracle/src/oci8-1.3.4# phpize
That’s pretty good for now. The next installment we’ll make the oci8 extension, set environment variables, and test that everything works
Upgrading Ubuntu
by cbrodt on October 21st, 2007
in Linux
So I got around to upgrading my desktop to Ubuntu Gutsy Gibbon today. I’d like to tell you all about the new features such as the latest version of GNOME or the first iteration of Compiz-Fusion into Ubuntu, however I’m not going to.
Rather, I can’t tell you.
Yeah, Gutsy cratered my desktop. Sorta. I can get it to boot, but it looks like some combination of proprietary Nvidia drivers and Automatix, the fancy everything-you-ever-wanted-from-linux-and-more utility that is a large bone of contention in the Ubuntu community. Personally, I thought that it was more of a philosophical disagreement, but now I’m finding that’s not quite the whole story.
Personally, I’m curious if any former Debian users have recognized the use of Christian Marillat’s site in the Automatix repositories. As far as I can tell, quite a few of the packages are imported from there. I remember the days running Debian Sid, trying to get the bleeding edge out of Linux. I used quite a few of Marillat’s packages (Movie Player in particular, that was quite a day)then as well. Of course running Sid, it’s hard to point to any particular link in the chain when your system goes belly up. Christian received criticism in the Debian community along the same lines that Automatix has seen with Ubuntu
Fast forward to Automatix and Ubuntu. Quite a different presentation here; an easy to use menu, automatic key ring negotiation, etc. Which I think it is good that someone is trying to make the things we want and need easy to come by. The #1 shortfall that I’ve seen with Linux is the gap between a fast, easy to maintain software distribution system and the learning curve. It took me forever to figure out how to use and understand Apt and the Linux file system when I started fooling around with it. Now I look back and laugh at Window$ and it’s so-called registry.
But even with tools like Synaptic, it’s still tough to find exactly what you’re looking for. And if I were a new user, downloading and installing Automatix sounds much friendlier then pulling down “gstreamer0.10-plugins-ugly-multiverse” from the repositories.
I think Ubuntu is eventually headed in the right direction; I installed Ubuntu Feisty on my laptop(the one I’m on right now in fact), and found that I was able to get most of what I needed through the regular Ubuntu repositories. In some cases, I had better performance on my laptop then my desktop running Automatix. And I should probably mention that my laptop was upgraded to Gutsy about 2 weeks before it was released, without a hiccup.
Regardless, I have no intentions of installing Automatix in the near future
Subscribe: