Whatever you do will be insignificant, but it is very important that you do it.
- Mahatma Gandhi

Friday, April 24, 2009

openSuse 11.1 vs Ubuntu 9.04

Recently, there were a couple of new Linux distribution releases that have been causing quite a bit of buzz around my workplace. Many of us have become fans of Ubuntu, but have used Suse for quite a while, so we like to stay informed of where each of the distributions is currently at. I installed Ubuntu 9.04 on my laptop, and had the opportunity to install openSuse 11.1 on an identical laptop for a co-worker. This gives me a moment to briefly compare a few of the things I found in the very short time that I had with the Suse box.
The first thing that I didn't like with Suse is that the wireless card, which in this case was a broadcom card, didn't auto-install. I had to search the internet, and finally found some pages that referred to running the following scripts:
/usr/sbin/install_bcm43xx_firmware
/etc/init.d/network restart
After these scripts, the wireless worked as expected. I found it kind of sad that I needed to connect to the internet and do some searching when the scripts were already with the installation. I wish it would detect that I had that type of card, and offer to run them for me. I liked Ubuntu much better, as it seemed to handle this in a fashion that would be easier for a new user to get running.

Also, openSuse seemed to be trying too hard in the looks department. It had a lot of transparency and floating menus. Kind of weird. Just didn't have a really appealing look to me.

Friday, April 10, 2009

More LibJPEG Fun

As I was compiling the jpeg library, I kept getting errors about ./libtool not being found. It was an easy fix, all I had to do was to change ./libtool to libtool in the Makefile, but I didn't want to do that every time, especially because I was trying to automate and script the build. I found an article that showed passing variables to make, and that seemed to solve my problem.
make LIBTOOL=libtool
That way, I could put it into my build script and everything would be happy, still using
the latest tarball untouched off the internet.

Thursday, April 09, 2009

Apache2, PHP, and LibJPEG

I'm configuring new server software for our internal webserver at work. I went through the build several times, and it kept complaining about not finding libjpeg.so. I finally figured out that you need to pass the configure --enable-shared or --enable-static in order to make the libraries build. Just thought I'd pass along this information, and hopefully save somebody some headache.

Friday, April 03, 2009

Read Only File and Directory Permissions

Today I needed to lock down some data so that it could only be accessed by a particular user and his group. We wanted to make sure that this archive was not modified, so I needed to lock down the permissions. For a long time, I don't think I fully understood that directory permissions are much different than file permissions. To get around this, I did my chmod in 2 steps. First, I did a
find -type d -exec chmod 550 {} \;
This needs to be 550 because the execute bit on a directory is actually an "access" bit. If you don't set it, you can't access the directory.
Then I did:
find -type f -exec chmod 440 {} \;
This gets the regular files and sets them to read only with no world access. Fairly basic, but I thought somebody might find it useful if they're struggling.

Tuesday, February 17, 2009

I'm Back

It's been a while since I've posted on my blog, so I figured I'd post a little update. We had a baby in December. She had some problems and so we had to have her flown to Salt Lake to Primary Children's Hospital. She was there for about 2 months. We recently got her home, but she had to be put back into the hospital after she contracted something, possibly RSV, that was causing her to have problems breathing. She's still currently in the hospital, and I'm at home taking care of our son.
It's been quite the experience. I've learned a lot in the last 3 months. Priorities change quite a bit when you go through something like this. I'm still not perfect, and I don't claim to have all my priorities perfectly in order, but I definitely appreciate things like a nice home, my health, family and friends, good food, and trying to help out others. It's amazing what being the recipient of some charity will do to your desire to serve.
I will probably not do any more book reviews. After reading some of them, it doesn't sound like I have anything really interesting to say about many of them. If I have opinions or original thoughts about some of them, I will try to abstract the thoughts and make some posts. I may try and keep a little update on what I'm reading, and things I'm planning on reading, but I will probably try to avoid boring "I liked this book" posts.

Friday, November 28, 2008

Tsar

Tsar by Ted Bell
This book had been in my "Wish List" for quite a while. I went to the local library and put it on their list of things to get, and they got it in. I had it for two weeks, and finally had time to finish it. There was a lot of interesting things in this book. One drawback that it had for me is that it had fairly graphic depictions of things that didn't need to be treated in such detail. That for me was a big detraction. It could've moved the story along with no need for it. It didn't seem to pick up for me until towards the end. For me, reading about the recent leadership of Russia was very interesting, as I'm fairly uninformed about that subject. The descriptions of places were quite fantastic, and the ending puts the hero in quite a moral dilemma. I didn't particularly like how the ending was written, as it seemed to gloss over some major details, but all in all it was a fairly enjoyable read.

Saturday, November 08, 2008

The Appeal

The Appeal by John Grisham
This book was very timely for me, as I read it just prior to the elections. Unfortunately, it shows a sad side of politics which I'm sure happens with all parties. It talks about purchasing elections, and in particular, Supreme Court seats.
This book brought to my attention the importance of Supreme Court justices, and indeed judges at every level of government. It's not something you think about every day, but it does have a large impact on how things work. The saddest thing about this book is that you could very well see it happening. The justice that is purchased in this book has many similar views with myself. I could have seen myself voting for him if given the information that voters would have seen. However, the premise of the book talks about a court case in which a company poisons a towns water with toxins and many in the town die or become very ill. While I have strong feelings that we need some tort reform in this country, I don't think that cases should simply be dismissed out of hand. We need some sort of middle ground.
Anyway, this was an interesting book that can open your eyes to some possibilities that you may not have thought about before.

2001: A Space Odyssey

2001: A Space Odyssey by Arthur C. Clarke
HAL, the spaceship controlling computer in this book, was my main reason for reading this book. I know it may confirm my nerdishness, but I read some excerpts from the book in an article about computer error messages, and thought it would be interesting. I found a copy at the local library and they were selling it for 50 cents. I purchased it and used it for some leisure reading on my plane ride to Phoenix. While interesting, this book ended up becoming quite strange towards the end. I'm not really 100% sure what they were going for. It was interesting, though, and had enough interesting sections to make it worth reading.

Saturday, October 18, 2008

Panic in Level 4 by Richard Preston

Panic in Level 4 by Richard Preston
During high school, we got an extra credit assignment to read Hot Zone, another book by Richard Preston. That book was about Ebola outbreaks. I don't remember many of the details, but I remember being fascinated by his vivid descriptions of the illness, and of the wonderful descriptions of how all of the agencies involved worked. Having these wonderful memories of a book from my youth, when I saw this book in my local library, I decided it would move to the head of my reading list. I was not disapointed.
It was much different than what I was anticipating, however. I had envisioned a high energy story that brought together all of the themes mentioned in the cover. What I found was a series of 4-5 shorter stories with small bits of interconnection.
One of the stories was very interesting to me as a computer programmer as it talked about two mathemeticians who build a supercomputer in their apartment that competes with some of the fastest machines in the world. They use this machine to calculate pi to many, many decimal places.
Much of the book talks about DNA and the mapping of the human genome. It was very interesting to read about the different projects and personalities working on this research. It also talked about some genetic disorders in great detail. Definitely something that makes you realize how lucky most of us are to be free of that type of problem when you're just one marker in your DNA away from having serious problems.
This was a very interesting book. It held my interest throughout, and was a fairly quick read.

Friday, October 10, 2008

Living within your means

Today as I was listening to some talk radio and Rush Limbaugh was talking about what caused this financial mess. He said that many people are blaming people not living within their means, but he went on to say something to the effect that living beyond your means is the American Dream. He said that living beyond your means and the desire to always have something more, something better was what drives the free market.
I think he has a point about the desire for something better being one of the things that drives the free market. My desire to have nice things for my family, and the desire to take care of them in the best way that I can and to give them nice things is what drives me to give my best effort at work and in everything else I do. I totally agree that this is a very healthy motivation to always want to do better.
However, I strongly disagree that living beyond your means is part of the American Dream. The American Dream, to me, has nothing to do with going into debt. The American Dream can be achieved without spending more than you make. This is a basic truth that applies across the board. Each individual needs to evaluate their situation and budget their money to be able to sustain their lifestyle. The drive to have better, nicer things is great. However, it should be achieved by saving, investing and hard work, not by taking out loans that you will never be able to pay back.
Likewise, the government should never be allowed to pass a budget that is not balanced, or to spend more than is coming in. We may need to cut some programs. We have been living in a way that is costing much more than we are earning. If this continues, we are headed for disaster. Soon, our debt will own us. We will all be working only to pay interest on our national debt. Other countries will stop loaning money to us, and we will find ourselves unable to compete in the global market.
I know I'm not perfect, but I strongly encourage each of you to think about this. If each of us can start with our own families, it can spread.

Thursday, October 09, 2008

Creating a list of machines on your NIS domain

If you're on a Linux machine that authenticates via NIS, you can very easily generate a list of all the Linux/Unix machines that are using that NIS server to authenticate. The command is:
ypcat hosts
You can also list the users that are authenticating against this server:
ypcat passwd
One situation in which this becomes very useful is if you have a heterogeneous network and people are running different shells. Part of the output of this second command is to tell you what shell people have as their default login shell. If these are set differently, you could be getting different environment settings and behavior.

kwin --replace

Many users at work have been reporting problems with our new Red Hat Enterprise Linux 4 (RHEL4) installation when running KDE. The problem manifests itself when they cannot move or resize their windows in their current session. This makes the system very unusable. Luckily, the fix is very easy. Simply type "kwin --replace" into a terminal window in the session that's not responding. This has been effective in resolving this problem in most instances. If I understand correctly, what it does is replace the current window manager with a new instance of the kwin window manager that KDE uses. Hope this is helpful if you run into the same problems that we've had.

Monday, September 22, 2008

Freakonomics

Freakonomics
by Steven D. Levitt and Stephen J. Dubner
I was looking forward to reading this book for quite a while. Several of my co-workers read it and were all very impressed. Then, it was on the front page of Amazon for what seemed like forever. When the Kindle came out, many of the images displayed the cover of Freakonomics.
This was a fairly easy read. It had nice chapter divisions and moved very nicely. I loved learning about how things happened and seeing how the causes might have been much different than we thought. I don't want to spoil the book by discussing too much detail of each of the scenarios which are dealt with in this book.
These two writers have a very interesting understanding of the world. It combines economic principles without all the math. I would encourage anyone who would like to expand their understanding of how the world works to read this book.

A Case of Need by Michael Crichton

A Case of Need
by Michael Crichton writing as Jeffery Hudson
It's been a few weeks since I read this book, but I wanted to just right a quick post about it. It's very strange, but several of the books that I've read recently have dealt with issues surrounding abortion. Definitely a very important issue. This book is very quick moving, while taking time to probe issues surrounding abortion. I don't have much to say other than that, but if you're a fan of Michael Crichton, this is definitely a good read. Another one by Michael Crichton that I read too long ago to post about right now is "State of Fear". Excellent reading!

A Seperate Peace by John Knowles

A Seperate Peace
I was at my grandmother's house for a family activity and decided to peruse her library downstairs. I found this, and it had my mother's name in the front cover, so I decided it would be interesting to read something that she had read when she was younger. This book is set during WWII and tells the story of 2 young men and their friendship. The book touches on a lot of different emotions and feelings such as jealousy, anger and true friendship. It also gives an interesting viewpoint on WWII that those of us who were not around for that time don't really get to see very often. This book was a fairly quick, easy read and I would recommend it.

Bringing Down the House by Ben Mezrich

Bringing Down the House
After watching the movie "21", I decided that it would be very interesting to get a little more detail, and hopefully a bit more of the "true story" about what happened. I found it very interesting to see all the differences between what actually happened and what was portrayed in the movie. It was also fascinating to learn a bit more about how the card-counting was actually done. The sad part is at the end it explains why it would be so difficult to duplicate this effort. This was a quick read and kept my attention well throughout.

Thursday, August 28, 2008

Bengal Ridge Golf Course

During lunch today I went and played the Bengal Ridge Disc Golf course with some friends from work.  We had a good time.  It makes Ross Park look very easy by comparison.  The drives are a lot longer, there's much fewer "safe" places, and it's quite the hike to get to some of the holes.  It is very beautiful and a good way to get a hike in while you're playing.

Finding multiple files with the find command on Linux

After fighting with the find command for quite a while yesterday, and trying to figure out it's regular expression parsing engine, one of my co-workers just let me in on a very useful function of find. You can specify multiple "-name" options on a command line if you seperate them with a "-o". For example, if you want to find all the files on your system named kids.txt and money.txt, you could issue the following command,
find / -name kids.txt -o -name money.txt
Pretty handy. Hope this helps you out if you are ever in this situation!

Wednesday, August 27, 2008

Installing old GCC Versions on current Linux distributions

Well, today I found out that I've been doing something wrong for quite a while. We have some code at work that was developed on RedHat 7.3 and has always had a hard time compiling on anything newer. There's a large, unsupported library that we depend on that doesn't compile on new compilers either. So, we're stuck with using an old compiler. On RHEL3, gcc 2.95 compiled OK with little tweaking. However, on RHEL4 it does not compile. After talking with a co-worker, and searching on the web, I found some documentation of the command "make bootstrap". This is great because it will bootstrap itself and then build with no problems after that's done. I hope if anybody else is stuck in this situation, this helps a bit.

Wednesday, May 28, 2008

Ubuntu 8.04 on VMWare Player

I've been working on getting an Ubuntu virtual machine running on my Ubuntu laptop so that I could test things without messing up my main laptop, and was having a very difficult time getting things working right. The biggest problem is that the keyboard repeat rate appeared to be set very fast, and each time I hit a key, I'd get multiples of that key. I found a blog entry that seems to have helped:
http://ubuntuforums.org/showthread.php?t=692842
This entry basically says that you should add acpi=off to the kernel line of your guest OS.
Worked great for me!