Peter Anselmo's blog |
I've been doing a lot of research lately for a good cost-effective laptop. I obviously spend a lot of time on the computer, and it's nice to be able to branch out from my desk every so often. That's when I saw her at Best Buy: a 15.4" Dell Inspiron 1525. Suprisingly, there was internet access in the store, and I spec'd out the build online. With all the upgrades (Dual-Core processor, 6-cell battery, DVD burner, 2G ram, 160G hard drive, Vista Premium), It came to $850. In store price: $499. Done and done. Item of business numbero uno: Install Ubuntu 8.04. I was a little worried about how things would go, as linux has been know to have spotty laptop hardware support, especially when it comes to internal wireless cards. However, I shouldn't have had any fears, the installation went smooth as silk. All of the multimedia keys work, the function keys are set, sound and ethernet worked, and after a quick update I was logging on to our wireless network. Easy as pie. I'd recommend Ubuntu on Dell's Inspiron laptops with zero hesitation. So now I have a laptop with both Vista and Ubuntu installed. Having the exact same hardware with two different operating systems begs for some non-biased comparison. Here's a few tidbits. Vista calculates 2 million digits of Pi in 82.5 second. Ubuntu does it in 60.9 seconds. That's a 35.4% performace gain for Ubuntu over Vista.
Let's poke around a bit more. When running idle, Windows vista uses 701MB of memory. Just to be generous, I turned off my anti-virus software for that test, which any sane Windows user would never do. Ubuntu, when running idle, uses 228MB. Wow, Ubuntu uses 67% less memory. Alternately, Vista uses 207% more memory than Ubuntu.
Why not just wipe windows and give the entire hard drive to linux? I know, I was thinking the same thing. I decided it's nice to have internet explorer around to test my websites. Not because IE is nice, acutally, it sucks, but because a lot of people haven't discovered Firefox, so I need to test for it. All in all, I'm very happy with the rig, especially given the great price tag. My only gripe is the high-gloss screen, which (oddly enough) I find vastly inferior to a matte screen. For some reason, all consumer laptops come with glossy screens even though you can't see anything but reflections unless you're in a dark room with every light out. So I ordered an anti-gloss screen cover for $12, and that should take care of it. I saved the best for last. Using Ubuntu's "Add/Remove Programs", I downloaded Maelstrom (legally, and for free, of course). This was an Eastmond-Anselmo favorite on the old Apple LC 475. Now I don't have to fight with Matt and Chad to get time shooting the asteroids into pieces. |
|||
Backups saved my life yesterday. No, seriously. I upgraded this installation of Drupal, and forgot to copy the files for my Email client before I wrote over the directory. After trying to check my mail (and getting an empty folder), I had about 30 seconds of complete terror, before I realized I had implemented an automated daily backup system about two months ago. Whew! I found a recent version in my backup files, and bingo, there were my mail client files. So, I'd like to talk a bit about backing up. Every single person who uses a computer should create an automated backup system. Period. And let me give you a few guidelines: Burning CDs doesn't cut it. Burning DVDs doesn't cut it. Both take way too much time and energy, and you will quickly forget to keep up. You need to buy a spare hard drive, and dedicate it to backups. Hard drives are cheap. You can find some excellent options here. Next, create a system to AUTOMATE the process. You don’t want to have to remember. If you have OSX 10.5, that means setting up Time Machine. I commend Apple on their push for automatic user backups. If you’re using XP, look here. If you’re using Vista, look here. If you’re using Linux. Look here and here. The last link above is what I use to backup my server, although I use a slightly modified version. I have it set up to backup all my files every night. I keep 6 days of nightly backups at all times. Then, once a week, I do a weekly backup, of which I keep 4 at all times. Finally, on the first of every month, I do a monthly backup, of which I keep the last 12 at all times. The advantages of keeping many versions of your files are two-fold. First, your hard drive may crash slowly. In this case, it will start corrupting files before it outright dies. If you’re only keeping one copy of files on you backup drive, you could end up writing over your good files with corrupted ones. Keeping multiple, redundant versions of your data ensures there will always be healthy versions available. Second, your backup solution now serves as an archive, where you can recover files you may have lost or accidentally deleted (see first paragraph). After reading this, you have no reason not to have an automated, dedicated backup solution. Please, I urge you, go set one up. The $100-$200 you will spend on an external hard drive is NOTHING compared to the value of your non-replaceable pictures, music, and files. |
|||
I just finished reading Apache Cookbook, Ken Coar and Rich Bowen. I'd give it a solid 4 stars. I found it to be very readable, and not overly verbose or cryptic, a problem that can plague computer books. The book is quite the opposite, if I had one criticism, it would be that it could be a little thicker. It's only 264 pages, and the font is plenty big, which makes for a fast read. Having set up and run an apache server for a few months, I skipped over many of the early parts of the book. However, I did find lots of useful tips, tricks and tidbits, that I know will come in handy later. For example, I didn't know you could make a custom log for any site, with any file, that contains almost any information. You simply specify a CustomLog directive for whatever host you want to monitor. I now set up several specific logs show me only the information I find useful. Other useful directives are RewriteEngine and RewriteRule. You can do almost anything you want with the URLs from your site, including redirection, query string modification, folder modification, clean URLS and more. This all comes from the module mod_rewrite. There's useful info on authentication and authorization, dynamic content, custom error pages, email notification, and much more. Here's a doozy: you can now use apache's mod_proxy_balancer to balance a load between a cluster of computers! Who knew it was so easy! You can even specify with the ProxyPass directive whether to distribute by bandwith, or by requests! A few other tidbits that I'm sure will be useful are the Apache bench utility for benchmarking site performance, and server-status which can monitor your server health and display it somewhere in your website. All in all, I'd recommend the book, and I see it being a useful reference in the future |
|||
|
|||
I had an app the other day that required a single random row to be displayed from the database. It's an easy task, but I tripped on it for a second. Here was my impulse: //Get the total number of rows from the MySQL database //Let PHP choose a random row //Now get that row After typing that out, I realized that I had take the long way round the problem. Very similar to taking the Misty Mountain Path rather than the Mines of Moria. Here's a better way: //Get a random row from the database Much better. Gimley the dwarf would be proud. |
|||
I spend a lot of time in front of a computer. I mean, a real lot. I'd say a reasonable estimate is 10 hours a day. As such, I take my choice of desktop background a little more seriously than most. I need to find images I like enough to look at for 60 hours a week. And they need to be in the native resolution of my monitor. Stretching and cropping are not allowed. So here's my hangout for the best wallpaper: Click above to go to the homepage, or click HERE to go straight to the wallpaper page, sorted by popularity. Below are a few of my favorites: Muck like flicker, this is a place for artists to get their name out, and share some of their better stuff. Usually, when I see something I like, I'll search for other's by the artist, and be pleasantly surprised. So check it out, let me know what you think. |
|||
Have you ever been browsing with Firefox and accidentally closed a tab that you didn't mean to? It's happened to me more than I'd like to admit. The next time it does, Here's the keyboard shortcut to recover it: Control + Shift + T Easy huh? You'll like it. I guarantee it. |
|||
Apple introduced a fabulous feature in OSX 10.5 called spaces. It basically gives you 4 monitors (actually between 2 and 8), so you can have more windows open, and switch between them as necessary. Linux has been doing this for a decade, and I'm happy to finally see OS X pick the feature up. This is preferable to minimizing windows for several reasons. First, you don't have to waste time trying to figure out which minimized window (which all look the same at 50 pixels) is the one you want. I know Firefox is open is space 2 (or upper-right), and I can quickly move there with the same keystroke every time. Second, you don't need to leave the keyboard to switch views. I can be coding in Dreamweaver, shift to view some example code in Firefox, and switch back to Dreamweaver and continue typing away, no time lost. Basically spaces = productivity. I see three problems with the implementation of spaces in 10.5. First, each space has a default application that comes in focus when you switch to that space. If I open up Filemaker in space 1, then open Dreamweaver, Filemaker will be the default application, and will always be in focus when switching between spaces. Not very effective if I'm currently coding in Dreamweaver. Second, opening a new window of an already open application will always send you back to the original space. For example, if now I try to open a Filemaker database in space 3, it will automatically shift me back to space 1. Most annoying. Third, you can set up 4 workspaces as either a row (1x4), or a square (2x2). This is great, except that the keyboard shortcuts don't recognize the difference. If I'm in the upper-right space in a square setup, and press the "move right" key, it sends me down to the lower left space. For those of us visual people, this is an obvious problem. Fortunately, OSX 10.5.2 gives you a setting to disable the automatic space-shifting in the control panel. I was happy to see this in the update. Now, if I want to open Firefox in two different spaces, I can do that. Apple needs to work on the other two issues though. If anyone knows ways to change this behavior, please let me know. Ubuntu (more accurately, the Gnome desktop), Implements this feature with a bit more success. First, it doesn't suffer from three problems mentioned earlier. I can open windows in any space. It will remember what window I was using, and bring me back when I switch, and pressing "up" and "right" will always bring me to the upper right space, regardless of where I'm working. There's a couple other touches I like as well. It moves faster; if I press keys in quick succession, it will always catch them, whereas with OSX it will often miss one (such as the upper-right example). Ubuntu also shows your panels moving with the space, which makes more sense visually to me. Basically, I'm happy to Apple finally use this feature, but it needs a little polishing before I'll prefer it over Gnome's more intuitive (and more established) version. |
|||
Rhythmbox is the music player that comes on the default Ubuntu installation. Anyone that has ever used iTunes, Windows Media Player or any other similar program will find it very intuitive. You do need to download an extension to add MP3 capability, but this is easy to do. What frustrated me for months has been the lack of options for ripping music from CDs. Although it has a great selection of formats (WAV, flac, ogg, mp3) it doesn't give you any options for setting the mp3 bitrate. At last I found a way, and thought I would pass it on: Open "Preferences" from the "Edit" menu audio/x-raw-int,rate=44100,channels=2 ! lame name=enc mode=0 vbr-quality=6 ! id3v2mux To remove the default, remove the vbr-quality=6 statement, and replace it with vbr=0 bitrate=256. This will change it from variable to constant bit rate, and set it to 256 kb/s. You can set it to whatever bit rate you prefer, I like 256. You line should now look like the following: audio/x-raw-int,rate=44100,channels=2 ! lame name=enc mode=0 vbr=0 bitrate=256 ! id3v2mux Close the window, and Viola! You'll now rip CDs at a higher quality. |
|||
Behold, the latest and greatest Audioman.net. In the best interest of my wallet, this entire site has been ported from Coldfusion (expensive hosting) to PHP (cheap hosting). More accurately, the site was scrapped, and I set up a new site using the Drupal framework. I also changed the name from Audioman.net to Code Zen, to reflect my changing interests over the past few years. I'll be making more regular blog posts on computer and programing topics, and the new name is a better fit for that as well. So Enjoy, feel free to leave me a comment or send me an email. |
|||