Archive for February, 2006

Review: iAudio M5 (day 4)

So I’ve been using the M5 for the last few days and have been pretty impressed. I missed a few days due to a long holiday weekend, but the last few days I’ve been on it.

I still haven’t read the manual- I need to check the CD tonight. It’s still broken on their site… Actually, I could just check google’s cache of the iAudio M5 mamual. I think I’ll do that now.

As it stands now, I’m 90% sure I’m going to buy one for myself. I haven’t used a portable music player since my CD player my freshman year of college, and a cassette player in high school before that.

Something else I’ve noticed- it’s more masculine than the ipod. It’s metal and shiny, where as the ipod looks like a femine hygene product. That amuses me on some level.

Useful Utility: dig

No, not the popular social new site, the dns utility. Dig stands for Domain Information Groper (get it, DIG?), which fills the same niche as nslookup. As a matter of fact, dig is the successor to nslookup.  Unlike nslookup however, the primary use of dig is non-interactive mode (which makes it ideal for scripting). Dig can also read batch files for more advanced executions, although I’ve not used this functionality myself.

So why bother using dig when nslookup is ubiquitous and you’re already familiar with it? There are a few good reasons, but here are the high points:

  • nslookup is flawed (the link above goes into detail)
  • nslookup is deprecated (it may not be included in future releases of Bind)
  • dig will eventually replace it (so stay ahead of the curve)

Using Dig

So supposing that’s good enough for you, how do you use dig?

dig [name] [@dns.server] [type] [query options]

It’s really straight forward- usually something as simple as dig morgajel.net mx would be a normal use, occasionally throwing it a dns server when testing bind replication.

As with most command line tools, you can also pass it various flags, but we’ll get to those a bit later. The name should be obvious- the name of the host you’re inquiring about. The second parameter here is the dns server, denoted by an @. If you don’t specify the DNS server, it will use the resolv.conf file. The next parameter is the type of record you’re inquiring about- mx, soa, a, cname, txt, etc. You can also use any to see all matching records, which is useful for seeing the big picture.

Besides bare parameters and command line flags, you can also pass mutliple query options prefaced with a +. Most options can also be negated by adding no; for example +multiline becomes +nomultiline. The most useful of these query options (for me):

  • +short: cuts the response down to the bare minimum
  • +multiline: makes responses like soa human readable
  • +search: uses search and domain directives from resolv.conf

Flags

The dig command accepts multiple command line flags, but to be honest, -x is the only one I use on a regular basis (for reverse lookups). In either case, here’s a breakdown of some of the more useful flags:

  • -x <0.0.0.0>: Designate reverse lookup for ip addresses. This is the only flag I really use.
  • -b <0.0.0.0>: Sets the base interface to query from on multi-homed machines. Useful for testing connectivity and firewall rules.
  • -f <filename>: Allows you to send a batch file of commands to run.
  • -p <port>: Allows you to designate a nonstandard port.
  • -q <name>: Explicitly sets the name to remove order ambiguity.
  • -t <type>: Explicitly sets the type to remove order ambiguity.

Examples

Dig is one of those commands that you need to see examples of to fully appreciate. Here’s some fun you can try:

dig -x 127.0.0.1
dig literaryescapism.com
dig @ns1.gopedro.net www.morgajel.com
dig morgajel.com any
dig @ns1.gopedro.net morgajel.net any +noquestion +nocomments +nostats
dig literaryescapism.com soa +short
dig literaryescapism.com soa +multiline

So, if you haven’t made yourself familiar with dig, you should- I use it 99% of the time when working with DNS requests. As usual, if you have any suggestions or comments, leave them below.

Useful Utility: wget

Wget is useful for a lot of things- downloading images from a directory listing, mirroring a website, recursively fetching one subdirectory of a website, etc. The main focus as you can tell is downloading from the web(http, https, ftp) in a non-interactive manner.

There are a lot of flags to change the behavior, and you can get all sorts of wild behavior by mixing and matching those flags. The most straightforward use is this:

wget http://example.com/software_pkg.tar.gz

This is the best tool for grabbing packages off a website to install on a headless machine. I can’t count the number of times I’ve needed to install something on my server manually and used wget to do it.

Useful Flags

Flag Use
-nc no clobber. useful for re-downloading sites, but not files you already have.
-N similar to -nc, except it overwrites if the file on the server is newer than the local version. useful for keeping mirrors up to date.
-r work recursively through a site and grab all the files
–spider doesn’t download the files, just checks to see if they’re there.
-l x designates to recursively download to a “depth” of x
-m mirrors a site. turns on timestamping, infinite recursion and keeps ftp indexes.
-X list exclude a list of directories from download. useful for preventing yourself from mirrors 30 gigs of video files
-np no parent. prevents you from accidentally going up into the parent directory when downloading recursively.

That’s a good start. There are a lot more options, but those listed above (and combinations of them) are probably enough to get you moving. Use this tool. Play with it. Mirror a site, play with the -N and -nc flags. Please feel free to include your own wget recipes below in the comments.

K_F, dev_null, I’m looking at you.

Review: iAudio M5 (day 1)

Since my music collection is 100% legitimate and ripped in Ogg Vorbis, finding a portable audio place that can play my music is a bit tough. There are 3 major players and a bunch of minor ones- the Neuros, the Rio Karma and the iAudio series are the leaders however.

The Rio Karma is very difficult to find these days since it went out of production. I purchased a Neuros about a year ago and it was such utter crap I returned it (which broke my heart since I was looking forward to it). I got Jackie the iAudio M5 for her birthday hoping it would be better than the neuros. She’s had it for a week and now it’s my turn to figure out all the features she hasn’t yet. I figured, “while I’m at it, I’ll do a little review.” Here’s one iAudio M5 review I’ve found for it which includes pretty pictures.

Disclaimer: This is my first real mp3 player (other than the neuros), so I am not spoiled by the features of other players.

First thing I notice was how small it was- it is also very sleek. It’s a nice neutral silver color with a polished control joystick. At first I had doubts about the joystick- I was afraid it was easily breakable. That is not the case. it’s very study, and as an added bonus I can adjust the volume while its in my shirt pocket without removing it. It’s just sensitive enough to make operating it in this fashion easy, but not easy enough to accident switch songs if it gets bumped.

it has a USB 2.0 socket on the side under a protective cover. The cover is connected in an odd way that makes it “dangley”, and I have doubts as to how long it will last. That’s just a minor complaint though- I honestly think it’ll last longer than the rubber booties on my digital camera did.

As for oddities, there’s a button on the top of it labelled “charge”. I don’t know what it does, and it doesn’t appear to have much to do with charging. I’m guessing it’s tied into the windows software that came with it. I’d read the Manual but it appears to have gone missing.

The actual onboard software is a bit confusing at first- it took me a minute or two to get the hang of it. Jackie had a hard time trying to figure out how to get it to shuffle, but I found the setting in “settings->playmode->shuffle” in about 30 seconds.

One nice feature I found was fade-in. I set it to 3 seconds, and I’m guessing that it’ll take the last 3 sconds of the current song and fade into the next, which is much nicer than the half-second gap that was there beforehand. I’ve had it set like this for the last 30 minutes, but I haven’t actually heard it do it- the transition is too smooth for me to notice despite the range of music I’m listening to.

As I write this, I’m listening to “Hittin’ the Note by the Allman Brothers. I’m using my own set of headphones, and the sound quality is pretty good. This is one of the CDs I’m currently favoring

It also has a voice-record feature for taking verbal notes- it’s a good idea and nice feature, but the mic placement is a little crappy- if you hold it like you’d expect to hold an oldschool micro-tape voice recorder( with your thumb on the record button), the mic hole sits between your thumb tip and the fleshy part at the base of the thumb.
I haven’t tested the quality yet, I just know that it exists.

Probably the best feature of the entire system is the fact that it’s a USB storage device, meaning I can directly copy files/playlists voice records, etc back and forth in linux as if it were an external harddrive. This also makes it easy for me to script up playlists in bash and write it to a file.

Overall I’m impressed with the unit, and have no problem recommending it, especially if you’re a linux user or have a collection in FLAC or Ogg Vorbis.

LPIC prepping

I’ve been wanting to take a linux certification for some time now. It’s been a goal, but I don’t feel I’m ready. Lately I’ve been studying a lot, trying to prepare myself and took a few practice exams.

The first pre-exam I took was a Linux+ pre-test from skillsoft, which I got a 92% on, which made me fell pretty good.

The next one I took was an LPIC test out of the back of my LPIC Exam Cram book. The LPIC is generally considered to be much harder than the linux+ exam. I needed a 70% to pass, and only got a 62%. Most of the questions I missed were RPM related or x window related.
I’ve since studied those sections and continued to make my way through the exam cram book (I’m on page 207 of 487, reading at most 5 pages a day due to the sheer volume of information on each page).

Today I took a test off the CD that came with the book and got a 70.7%

I’m reviewing my answers now to see what needs to be improved, but this is exciting to me that had this been a real test, I would have passed.
I plan on putting a lot more work into it still, but it definately lets me know I’m learning something.

I highly reccommend the LPIC exam cram book btw if you’re planning on doing any work with linux. flip to a random page and you’ll learn a handful of things- it’s great.

Useful Utility: cut

This is the first of a series of entries I’d like to do. Each week I’m gonna discuss a simple linux utility that you may or may not be familiar with.

First up is cut.

Cut can be used to shape data that is piped to it. for example, lets suppose you wanted a list of the real names and user names from the /etc/passwd file where you actually have a real name. Here’s the data as it’s currently stored.

morgajel:x:1000:100:Jesse Morgan:/home/morgajel:/bin/bash
cullenp:x:1011:100:Paul Cullen:/home/cullenp:/bin/bash
clstopher:x:1013:100:Chris Shaffer:/home/clstopher:/bin/bash
fletchmr:x:1014:100:Matt Fletcher:/home/fletchmr:/bin/bash
kristianf:x:1034:100:Kristian F.:/home/kristianf:/bin/bash

We can run this through cut, telling cut to use the colon(:) as the delimiter and to only take get the user name and the real name:

cut -d: -f 1,5 /etc/passwd

morgajel:Jesse Morgan
cullenp:Paul Cullen
clstopher:Chris Shaffer
fletchmr:Matt Fletcher
kristianf:Kristian F.

Suppose you want to just cut characters off an entry? we can do that too. Suppose you want to look at who owns the sites hosted on a machine:

morgajel@p-nut ~/ $ ls /var/www/ -l
total 84
drwxrwxr-x  23 morgajel ourselves 4096 Jan 14 10:32 morgajel.net
drwxrwxr-x  27 morgajel ourselves 4096 Jan 28 09:45 morgajel.com
drwxr-xr-x   5 jaxon    apache    4096 Oct  9 11:14 myjaxon.com
drwxr-xr-x   2 morgajel apache    4096 Jan 24  2005 test

That shows it, but there’s a lot of cruft that isn’t useful if you’re trying to script the information into something useful.
We can visually count characters and figure out that the usernames are between the 16th and 24th characters and the site name starts and the 52 character and extends beyond. We can use the -c flag in cut and specify which characters we want to keep:

morgajel@p-nut ~/ $ ls /var/www/ -l|cut -c 16-24,52-

morgajel  morgajel.net
morgajel  morgajel.com
jaxon     myjaxon.com
morgajel  test

Anyways, that was a quick run-through. There are more powerful tools that can do this an more, such as awk and sed, but this is useful for spur of the moment scripts that you don’t plan on keeping long. Always check the manpage for more details or leave a comment if you have more helpful tips.

Owning Up

Had a discussion with my wife last week about how much we share on our websites. It sounds like there is some concern that we talk “personal” issues on our websites- like my temper tantrum when pablo died, and how jackie’s family act like children when you get them in a room together.

So here is my statement on it.

If I discuss it here, I have nothing to hide. I am not perfect, nor do I pretend to be. This site is open to everyone- if you want to understand me, this is the place to read. I don’t feel the need to hide- I am proud of who I am. I talk about my embarassing moments here. You know why? To keep me from ever doing it again. It’s trial by fire.

Not to get real philisophical, but the last 10 years has been a pivitol point in the history of humanity. Knowledge is no longer a secret meant to be bottled up- it is now shared. The people who do this are also opening themselves to the world as well.

People who read this know me; they know my motivations. They’re less likely to mistake my intentions. Yes, I am human; yes, I make mistakes. But I do not cover them up. I will not cover them up. This does not mean I am not a private person- quite the opposite. I however choose the information I release. For example, I wouldn’t release information that would purposfully do injury to people (although I do not care about their feelings). But I do not hide information because I am ashamed.

If you disagree with me, I want to ask you this- why? Why would you not want people to know? Does it matter? Do you care what people really think of you? I admit, I do care- but I care only for selfish reasons. If they cannot accept me for who I am, that is their loss.

I am Jesse Morgan. I am comfortable with who I am. Why can’t you be?

Hey you…

Yeah you, the jackasses who decided that the middle of a crowded elevator lobby was a good place to stop and chat.

While I understand it’s of dire importantance you tell each other about what your coworkers said to annoy your other coworkers, could you please NOT STAND IN FRONT OF THE ELEVATOR CALL BUTTONS while doing it? I know there’s not much space there, with it being lunch rush and 50 other people crammed into this small space, but we all have to make sacrifices.

I hate to be a party pooper, but could you please GTFO of the way before I have to push you down so I can get back to work? There’s a whole open lobby not 20 feet away from you where could chatter- you could even spread out a bit.

Oh yeah, and thank you for convincing me to add a new category- Jerks.

Star Ocean: Till the end of *yawn* time

This is my first real video game review, so I’m not sure where to go with it.

You play a kid named Fayt with a sword who is being chased. There are a couple of plot twists, but for the most part the story is disjointed. Gameplay is spread between a couple of different worlds, and as you progress to the next world, they squeeze some plot in.

They could have done more with the klausians, and they could have done a LOT more with the guys chasing them in the beginning. Introducing a big bad alien species and then taking them out of the game before you fight them is sorta lame.

Also, Fayt and Maria- they’re the only 2 people in the game with blue hair, both results of an experiment… are they supposed to be twins? was that ever explained? Their hair just *happened* to both be blue? I think Fayt’s dad has the bluehair gene and was spreadin the love with her Maria’s mom. And what was the deal with Sophia? that felt sorta tacked on at the end. They also never explained the relationship between Mirage and Cliff. Cousins? Divorced? what the hell?

ok, back to the plot. I was actually embarassed at the MAJOR plot twist in the game- They completely ripped off a certain movie that came out around the same time.

The game kept dragging on, and the final battle with the boss was difficult, but boring.

Pros:
I liked the battle system- it was an rpg, yet a button masher at the same time. Paging through the spell interface would have been a nice feature, but other than that it was pretty good.

Cons:
the plotline reminded me of something the cat yacked up. level layouts, like the carnival near the end, were just painful- fight fight fight, run 3 screens to go get supplies, one more to save, and back across all 4 to get back to fighting.

also, the dialogs in the arena- for crying out loud, I don’t want to hear the same lame 15 box intro and joke every time I fight the sacred beasts- I’m trying to level up to beat the final boss! Shut the hell up!

ok, upon reading this review, I’ve decided not to do anymore.

It’s changing me…

I did something today that made me feel very crappy. Nothing really big, I just sorta stepped in front of people to get to the escalator- just sorta pushed my way forward. Why does this bother me? Here’s why.

When I first moved to DC, I noticed how rude people are- pushing shoving, cutting in line, not waiting their turn, generally being impatient, and treating those around them like crap in order to move on to their oh-so-important jobs of backstabbing, manuvering, and powerpoint presentations,.

My actions offended me not because they were heinous, but because I’ve come to the realization that people are not precious- there’s entirely too many of them here. They’re not people, they’re obstacles. They don’t have personalities and problems, they just get in my way. For all my gruff exterior, I still try to treat those around me decently. This was the first step in the opposite direction.

I don’t want to go this direction. I like helping total strangers; I like being nice to random people. It makes me feel better. I don’t want to treat people like moving garbage cans. I don’t want to become one of these assholes I shake my head at.

I need to get the fuck out of DC.

Go to Top