Tuesday, 31 July 2007

Stupid Sony SXRD bulb died.

Just my luck -- the DLP bulb in my Sony SXRD crapped out. The front light went red, indicating "lamp". It took a while to find the manual pdf online for my model, the KDSR60XBR1. Sure enough, the red light means the lamp is dead, see page 104 for replacement instructions. Basically, you can buy the bulb (XL-5100 replacement lamp from Philips) in the housing for $200 from this vendor, or the bulb without the housing for $140 from this vendor. Removing the old bulb from the housing takes about 15 minutes and can be done with a philips screwdriver and pliers as described in this blog.

 This is the second major problem I've had with my SXRD, which is about 15 months old. The first problem was a colored pixel problem where the blue pixels failed in a nice C-shapped wave. This made everything look more yellow (white-blue=red+green=yellow). Fortunately, that was covered by Best Buy's warrantee, including in home repair. Best Buy won favor with me on that one, but I'm not thrilled with Sony for this TV. My other WEGA is an regular TV and it's been fine. I remember growing up we had the same Sony TV for what seemed like 15 years.

Technorati Tags:

Posted by spout at 8:37 PM in reflections on life

I-Phone: Do I want one

I'm not sure if I want an IPhone or not. Somebody help me figure this out.
Posted by spout at 10:15 AM in the internet, web, web 2.0 and beyond

Monday, 30 July 2007

mod_proxy_ajp: Simpler than mod_jk

I happened to look in my /etc/httpd/conf/conf.d directory, and there by default is a file proxy_ajp.conf . Hmmm, what is this? Well it appears to be a simpler way of mapping a piece of the apache URL space onto tomcat's AJP connector. Instead of the previous posting, I reconfigured apache using proxy_ajp.conf like so:

LoadModule proxy_ajp_module modules/mod_proxy_ajp.so
ProxyPass /blog/ ajp://localhost:8009/blojsom/blog/spout/

<VirtualHost blog.bwtaylor.com:80>
    ProxyPass /blojsom ajp://localhost:8009/blojsom
    ProxyPass / ajp://localhost:8009/blojsom/blog/spout/  
</VirtualHost>
I also went in to blojsom and changed the url properties accordingly. Note that stuff like CSS will be found under /blojsom, but the main blog can be hit directly at blog.bwtaylor.com . Or bwtaylor.com/blog . 

 I still think mod_jk is "correct" in a few circumstances where it's fine grained controls might help. Under load, mod_jk is capable of just sending the servlets and JSP to tomcat, while serving the static content itself. However, for something like my blog, letting tomcat handle static doesn't create any problems. The above is pretty darn simple and very easy to understand, so I'm going with that.

Technorati Tags:

Posted by spout at 9:35 PM in stuff about java

Getting mod_jk to work

This blog is now accessible at http://blog.bwtaylor.com . To make this work I did three things:

  1. I added blog.bwtaylor.com to my DNS
  2. I set up mod_jk and configured it to route the virtual host blog.bwtaylor.com to the AJP1.3 connector on port 8009
  3. I added a redirect in index.html at higher levels to go to the blogsom/blog/spout context path

These three steps are all you have to do to have simple apache tomcat integration so that tomcat access that is normally on port 8080 is added to the regular apache URL namespaces. 

The mod_jk setup was pretty easy. After downloading the appropriate mod_jk binary from a mirror like this one and symlinking it to the name mod_jk.so in the apache modules directory, I added this to /etc/httpd/conf/httpd.conf


 LoadModule jk_module modules/mod_jk.so 

Then I created a workers.properties file under /etc/httpd/conf like so:
# List workers
worker.list=tomcatWorker
# Define wrkr
worker.tomcatWorker.port=8009
worker.tomcatWorker.host=localhost
worker.tomcatWorker.type=ajp13
worker.tomcatWorker.cachesize=10
worker.tomcatWorker.cache_timeout=600
worker.tomcatWorker.socket_timeout=300

and finally I finished off the connection by adding mod_jk.conf under /etc/httpd/conf.d for the virtual hosting rules:
JkWorkersFile /etc/httpd/conf/workers.properties

JkShmFile     /var/log/httpd/mod_jk.shm
JkLogFile     /var/log/httpd/mod_jk.log
JkLogLevel    info
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "

NameVirtualHost *:80
<VirtualHost blog.bwtaylor.com:80>
    DocumentRoot /opt/tomcat/webapps
    ErrorLog /var/log/httpd/mod_jk-error.log
    CustomLog /var/log/httpd/mod_jk-access.log common
    <LocationMatch ".*WEB-INF.*">
        AllowOverride None
        deny from all
    </LocationMatch>
    JkMount /* tomcatWorker
</VirtualHost>

 


Technorati Tags:

Posted by spout at 8:07 PM in stuff about java

Checking out JPackage

It's been a while since the last time I looked at JPackage, so I thought I look back. JPackage provides rpms of common java libraries and frameworks for linux.

I was hoping that since Java has gone GPL (98%) anyway, that JPackage would have an rpm for it. Nope. They don't even have java-1.6 at all yet. And that's my general comment on most of the things they do have... they're old. Spring? no 2.0. Struts? no 2.0. JBoss? 4.0.3 is their latest. Tomcat? no 6.0. Generally, I don't see the point -- I've already got the old packages, I generally want to install newer things. So, sorry, JPackage just isn't helping me.

Technorati Tags:

Posted by spout at 5:05 PM in stuff about java

Sunday, 29 July 2007

Trying this blogging thing, using Blojsom

I'm wanted to try this blogging thing, so I looked around for some software and decided to try blojsom. I wanted something that would run under tomcat, so it came down to choosing between blojsom and roller. I found this post comparing the two. Basically blojsom is supposed to be simpler for a single user, whereas roller scales up to lots of users well. If I don't like blojsom, I'll give roller a try.

The install of blojsom went fairly smoothly, with one little hickup. When I got it installed and went to the url for the default blog or for the administration console, all the links and buttons pointed to localhost (including the CSS), even though I was coming in remotely. I had to dig a little to troubleshoot, but after grep'ing a little I discovered that the urls are stored in data in the Properties table (it's loaded by the blojsom-full-initial-data-mysql.sql script). After ssh'ing in to my server and using lynx a little (my server has no X server), I found you can change the URL's in the admin console. Lynx was tiring me out with the admin forms, so I just went in to the database and did some update magic, and then it worked.

 Anyway, I know I could have tried one of the many service out there that host your blogs, but I wanted a little more intimate experience. Blojsom is written with spring and hibernate, which are both tools I know and like.

 One interesting thing I noticed is that blojsom lets you tag your pages in the "technorati tags" box. Tagging appeals to me greatly and fits in with my interest in ontologies and hip cool web 2.0 stuff. I imagine I'll blog about similar stuff that I put on my del.icio.us page.

  

Technorati Tags:

Posted by spout at 7:41 PM in the internet, web, web 2.0 and beyond