14 Ağustos 2012 Salı

GloboChem: Hilarious Video From Mr. Show

To contact us Click HERE

Happy Sunday :)

SPECIAL NOTE FOR PARENTS: The video embedded in today's post contains effusive amounts of swearing in certain parts. Please don't watch with children present unless you've previewed and approved!

Today's post is way off-topic, but, as some of you may know, I'm a huge fan of Mr. Show and suffered from terrible depression for the entire period following its sudden cancellation and the release of the DVD box set of all 4 seasons. It wasn't all that long between the two, I'll admit, but it was really really hard on my fragile psyche ;) Check out this link for our post featuring another Mr. Show sketch called "The pre-taped call-in show." It's just as funny, if not funnier, and much more family-friendly :)

I hope you enjoy this video. I can't watch it without, at least, laughing on the inside. It runs a bit long, but, if you stay with it, you won't be disappointed.

Pit-Pat loves you ;)

Cheers,







, Mike


Banner for College Student-Oriented Sites (728 version 1)



Please note that this blog accepts comments via email only. See our Mission And Policy Statement for further details.

Humorous Linux Posters - Part One

To contact us Click HERE

A cheerful, bright and sun-shiney Monday to you,

In our ongoing tradition of scouring the web for funny stuff (to make up for actually having to work, which takes away from blog-writing time ;), here's another collection of humor pieces. Posters, actually. The sentence before last was an attempt to sound highbrow while writing about low art. Not that posters are bad, in principal, but... Well, you be the judge :)

BTW, if the Linux Command Reference poster seems out of place, you can rest assured that it is. There's no joke to find in there. The reason we chose it was because of how very little it seems to actually cover. Pity the sysadmin who tries to get by on that amount of advice. It's got some good stuff in there, but it's not a safety-net by any means. Think of it as equivalent to MS Word's "Grammar Checker" to a non-English-speaking American, writing his new resumé. He can get rid of all those red and green underlines, but, in the end, his job application will be completely unreadable and insane. At best, he'll have a shot at landing a job in a special-needs environment ;)

Enjoy the posters, all pictures are copywrite of their respective creators and, as always, Cheers,



RedHat
Look, A Linux Poster!
Go Get 'Em
Gentoo
Fedora
Birds In Black



, Mike


Banner for College Student-Oriented Sites (728 version 1)



Please note that this blog accepts comments via email only. See our Mission And Policy Statement for further details.

More Funny Linux Posters - Or, Part Two

To contact us Click HERE

I'm leaving this page up, but, as many of you have probably noticed, I've been too busy to write this blog for quite a while. I hope to continue writing again soon. I actually have been writing some fiction, but, for the most part, that doesn't fit the spirit of this blog ;) If you're interested, just look up "Golvach" on Amazon.com or check out this link (The first chapter should be available for free). We'll be talking to you soon. ...after I'm done going through the 40,000+ emails in my inbox ;)

Ahoy,

Another day spent raging against (or in some kind of opposition to) the machine has left me no time to write, if I want to get to know my kids before they grow up ;) I think, given the economy, I may have to break my streak and go to posting 3 or 4 times a week instead of every day (I can't afford to work contracts anymore and I'm not entirely comfortable quitting my full time job and rolling the dice in America's economy just yet ;) I think I'm going to be dropping a 500+ day-or-so streak (I'm too mentally goofed to even add now... yay ;)

Enjoy the rest of the posters. They certainly enjoy you ;)

Cheers,



Ubuntu
Oooobuntu
Please change your password. It smells awful!
Another fake book for idiots who like being called dummies
Alien Idol
God Bless Her




, Mike


Banner for College Student-Oriented Sites (728 version 1)



Please note that this blog accepts comments via email only. See our Mission And Policy Statement for further details.

Command Line Init Script Generator For Linux Or Unix

To contact us Click HERE

Hey There,

To start this week off, we've got another updated script (now that we have over 600 some odd posts, we actually have about 400 some odd loose ends to finish up, as well ;) This script is an update of an earlier post we did to showcase a basic init script generator for Linux or Unix, again hearkening back to 2007. How time flies when you're not paying attention to what you're doing ;)

This script includes several updates (which haven't been tested to perfection - so feel free to write in with complaints ;) such as the ability to use command line arguments to specify a wider variety of options, set some to default and not even enter any (except three) if you don't want to. Actually, the only three required arguments are the name of the program you want to start with the init script you generate, the fully qualified name of the same program and the name of the init script itself. All the other options are easily displayed by just running the command without any arguments, like so:

host # ./rcscript.sh

Options -n -p and -f are required!

Usage: ./rcscript.sh [-h for this help screen]

Required switches:
[-n init script name] [-p name of program to control]
[-f controlled program's fully qualified name]

Optional switches:
[-i init directory] [-3 rc3.d directory] [-0 rc0.d directory
[-s start options for your program]
[-S stop options for your program]
[-k additional programs to kill on stop - space separated]
[-b common binary directory - defaults to /usr/bin]

Be sure to "double quote" any switch arguments with spaces!


Hope you enjoy the updates and this script helps you out in some way or fashion :)

Cheers,

Creative Commons License
rcscript.sh by Mike Golvach is licensed under a Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 United States License.
Based on a work at linuxshellaccount.blogspot.com.
Permissions beyond the scope of this license may be available at http://linuxshellaccount.blogspot.com.

#!/bin/sh
#
# Generic Init Script Creator
# 2009 - Mike Golvach - eggi@comcast.net
#
#Creative Commons License
rcscript.sh by Mike Golvach is licensed under a Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 United States License.
Based on a work at linuxshellaccount.blogspot.com.
Permissions beyond the scope of this license may be available at http://linuxshellaccount.blogspot.com.
#

trap 'rm -f ${init_dir}/${script_name} ${rc3_dir}/${script_name} ${rc0_dir}/${script_name} ${script_name}' 1 2 3 9 15

# Tips for a few command line arguments - setting an argument to zero will not be considered equivalent to not defining it
# a. set init_dir to 0 if you don't want any scripts and links setup - set rc3_dir, rc2_dir and/or init_dir to "0" to not create that link/script.
# b. If any of the init_dir, rc2_dir and/or rc3_dir variables are not set, they will default to the examples below.
# c. options that include 0 in the example do not need to be set and are entirely optional
#

# init_dir= /etc/init.d or 0
# rc3_dir= /etc/rc3.d or 0
# rc0_dir= /etc/rc0.d or 0
# script_name= myStartScript.sh
# program_name= testProgram
# fully_qualified_program_name= /usr/local/sbin/testProgram
# start_options= "start" or 0
# stop_options= "stop" or 0
# sure_kill= "space delimited list of extra programs to kill" or 0
# common_bin_directory= "place where common binaries are on your system" or defaults to /usr/bin
#

function usage()
{
echo
echo "Usage: $0 [-h for this help screen]"
echo
echo "Required switches:"
echo "[-n init script name] [-p name of program to control]"
echo "[-f controlled program's fully qualified name]"
echo
echo "Optional switches:"
echo "[-i init directory] [-3 rc3.d directory] [-0 rc0.d directory"
echo "[-s start options for your program]"
echo "[-S stop options for your program]"
echo "[-k additional programs to kill on stop - space separated]"
echo "[-b common binary directory - defaults to /usr/bin]"
echo
echo "Be sure to \"double quote\" any switch arguments with spaces!"
echo
exit 1
}

while getopts 0:3:b:f:hi:k:n:p:s:S: option
do
case $option in
'i')
if [[ "$OPT_ARG" == "0" ]]
then
init_dir=0
else
init_dir="$OPTARG"
fi
;;
'3')
if [[ "$OPT_ARG" == "0" ]]
then
rc3_dir=0
else
rc3_dir="$OPTARG"
fi
;;
'0')
if [[ "$OPT_ARG" == "0" ]]
then
rc0_dir=0
else
rc0_dir="$OPTARG"
fi
;;
'n')
script_name="$OPTARG"
;;
'p')
program_name="$OPTARG"
;;
'f')
fully_qualified_program_name="$OPTARG"
;;
's')
if [[ "$OPT_ARG" == "0" ]]
then
start_options=""
else
start_options="$OPTARG"
fi
;;
'S')
if [[ "$OPT_ARG" == "0" ]]
then
stop_options=""
else
stop_options="$OPTARG"
fi
;;
'k')
if [[ "$OPT_ARG" == "0" ]]
then
additional_kills=""
else
additional_kills="$OPTARG"
fi
;;
'b')
if [[ "$OPT_ARG" == "0" || -z "$OPT_ARG" ]]
then
common_bin_directory="/usr/bin"
else
common_bin_directory="$OPTARG"
fi
;;
'h')
usage
;;
*)
usage
;;
esac
done

if [[ -z $script_name || -z $program_name || -z $fully_qualified_program_name ]]
then
echo
echo "Options -n -p and -f are required!"
usage
fi

if [[ -z $common_bin_directory ]]
then
common_bin_directory="/usr/bin"
fi

if [[ -e $script_name ]]
then
rm $script_name
fi

cat << EOM >>$script_name

#!/bin/sh

#
# ${program_name} init script
# Usage: $script_name [start|stop|restart]
#

case \$1 in
'start')
echo
echo Starting ${program_name}....
echo
${fully_qualified_program_name} ${start_options} >/dev/null 2>&1 &
${program_name}_running=\`${common_bin_directory}/ps -ef|${common_bin_directory}/grep "${fully_qualified_program_name}"|${common_bin_directory}/grep -v grep|${common_bin_directory}/awk '{print \$2}'\`
if [ "\$${program_name}_running" == "" ]
then
echo "${program_name} start cannot be confirmed. Please check"
echo "system output and application logs for further detail"
else
echo "${program_name} started successfully"
fi
;;
'stop')
echo
echo Stopping ${program_name}....
echo
if [ "$stop_options" != " " ]
then
${fully_qualified_program_name} ${stop_options} >/dev/null 2>&1 &
fi
${program_name}_walking=\`${common_bin_directory}/ps -ef|${common_bin_directory}/grep "${fully_qualified_program_name}"|${common_bin_directory}/grep -v grep|${common_bin_directory}/awk '{print \$2}'\`
if [ "\$${program_name}_walking" == "" ]
then
echo "${program_name} does not appear to be running."
echo "Process not found. Not shut down."
else
counter=5
dead="alive"
echo "Shutting ${program_name} down."
echo "${fully_qualified_program_name} - pid ${program_name}_walking - stopping."
while [ \$counter -gt 0 ]
do
${program_name}_still_walking=\`${common_bin_directory}/ps -ef|${common_bin_directory}/grep "${fully_qualified_program_name}"|${common_bin_directory}/grep -v grep|${common_bin_directory}/awk '{print \$2}'\`
if [ "\$${program_name}_still_walking" != "" ]
then
echo "killing pid \$${program_name}_still_walking "
${common_bin_directory}/kill \$${program_name}_still_walking
counter=\`expr \$counter - 1\`
sleep 1
else
dead="dead"
echo "dead"
counter=0
fi
done
if [ \$dead = "alive" ]
then
echo "Could not kill process after 5 attempts."
echo "Process ${program_name}_walking still active."
${common_bin_directory}/ps -ef|${common_bin_directory}/grep "${fully_qualified_program_name}"|${common_bin_directory}/grep -v grep
fi
fi
EOM
if [[ $additional_kills && ! -z $additional_kills ]]
then
cat << EOM >>$script_name
for aks in `echo $additional_kills`
do
echo
echo Stopping \$aks....
echo
aks_walking=\`${common_bin_directory}/ps -ef|${common_bin_directory}/grep "\$aks"|${common_bin_directory}/grep -v grep|${common_bin_directory}/awk '{print \$2}'\`
if [ "\$aks_walking" == "" ]
then
echo "\$aks does not appear to be running."
echo "Process not found. Not shut down."
else
counter=5
dead="alive"
echo "Shutting \$aks down."
echo "\$aks - pid \$aks_walking - stopping."
while [ \$counter -gt 0 ]
do
aks_still_walking=\`${common_bin_directory}/ps -ef|${common_bin_directory}/grep "\$aks"|${common_bin_directory}/grep -v grep|${common_bin_directory}/awk '{print \$2}'\`
if [ "\$aks_still_walking" != "" ]
then
echo "killing pid \$aks_still_walking "
${common_bin_directory}/kill \$aks_still_walking
counter=\`expr \$counter - 1\`
sleep 1
else
dead="dead"
echo "dead"
counter=0
fi
done
if [ \$dead = "alive" ]
then
echo "Could not kill process after 5 attempts."
echo "Process \$aks_walking still active."
${common_bin_directory}/ps -ef|${common_bin_directory}/grep "\$aks"|${common_bin_directory}/grep -v grep
fi
fi
done
EOM
fi
cat << EOM >>$script_name
;;
'restart')
echo
echo ReStarting ${program_name}....
echo
\$0 stop
\$0 start
;;
*)
echo "Usage: \$0 [start|stop|restart]"
;;
esac
EOM

${common_bin_directory}/chmod 750 ${script_name};
${common_bin_directory}/cp ${script_name} ${init_dir}/${script_name}
${common_bin_directory}/ln -s ${init_dir}/${script_name} ${rc3_dir}/${script_name}
${common_bin_directory}/ln -s ${init_dir}/${script_name} ${rc0_dir}/${script_name}


, Mike


Banner for College Student-Oriented Sites (728 version 1)



Please note that this blog accepts comments via email only. See our Mission And Policy Statement for further details.

Updated Post: Arbsorption Of Knowledge In The Computer Age

To contact us Click HERE

Hello again, --> GENERAL WARNING: If you don't like to read a lot of text online, blow off this post! Also, ZOOM OUT when you're done reading for a nice surprise! It's a tech opinion piece and won't solve any problems that can't be cured by slowing your life down a bit and paying more attention to the moment. That being said, even though this text is meant to be right above the "F" I'm going to put this disclaimer here anyway, just to see how many complaints I get. This post is full of misleading, and often completely incorrect, information and a few typos. For instance, I'm well aware that the square of 25 is not 3. Sometimes, I use the wrong case (we instead of I) on purpose. I don't address some points at all. Depending upon how some folks read
online (based on my own stockpile of comments and responses to posts) you may very
well have either missed what I just wrote or will have forgotten it by the time you
get to the point where I make that false assertion. Hopefully we're below the Adsense block now, so we can begin with the top of the "F."

Today I'm going to follow up on post we did a good long while ago regarding absorption of knowledge in the computer age. And I'm going to get a few things out of the way right off the bat, just in case you're the type of "F" reader they refer to in that previous post (more on that farther down the page ;) I was originally going to post some ridiculously bad code, explain that I was doing it on purpose, and why, with text in the "F pattern" and see how many people still complained about the shoddy quality of the code. Instead, I looked back at some older posts where the code was intentionally bad (in order to illustrate concepts related to the porting of shell to Perl or other programming languages more easily - since if two different languages are more structurally and visually similar, it's generally easier for anyone to process their own translation - my opinion, of course ;) and decided that, since I've already done that, it would be cheap to do it again. Easy for me. Lame for you. Believe it or not, that original series of posts on porting continued to generate complaint mails, even though the follow-up (linked to above) and rationale was spelled out within the top section of the post and is just a small part of a pretty sparse read; especially when compared to the endless lunatic yammering I slap down on the virtual page nowadays ;) If that link generates more complaints about improper or inefficient code we'll be numb with indifference... There's only so much caring one man can do ;) This has been the (possibly slightly goofed up by Adsense) top of the "F."

instead, i'm going to attempt to explain (and have fun with)
one basic concept in the aRticle from our prEvious post on computer reADing habiTs.
tHE writeR begIns the article (quite cleverly, actually, since he's assuming
you'll be the type of reader he describes and packs that information in the
relevant places) exploring the theory that most children (and a lot of teenaGers
and adults) are "f" readers when it comes to reading text on tHe inTernet. the
"f" is Somewhat of a double entendre (I'm going with the strict french translation
of "DoublE understanding" since the term is mOstly used to describe a "phrase"
rather than a single letter ;) in this case, since it's used as both a mnemonic
(the less to remember you by, my dear ;) for "F"ast and as a visual descripTion
of the patH most onlIne reader'S eyes follow when reading books or text on the
comPuter screen. if you've reAd this faR, the remAinder of the post should be
completely uninteresting. we tried to do a few thinGs on purpose to make this
post enteRtAining on more than just a Plain level. wHatever doesn't make sense,
probably will when you see the forest :)

Just for the record, I prefer to read books on paper. Not because reading online
makes me lose control like Patty Duke in the presence of a hot dog (see The Patty Duke Show Theme Song
for the full lyrics to that bizarre reference ;), but I find that reading a computer
screen is generally either uncomfortable (sitting in a chair or trying to balance a
laptop on my knees) or outright painful (bad refresh rates and certain color schemes
make my eyes dry up like juicy oranges and twitch uncontrollably). Bless all of you
who enjoy reading lots of text online. If I can, I go the library and get the book
instead. Unprovoked question: If I can't stand reading lots of text on a computer,
why do I write such long blog posts? Am I sadist, a masochist, both or just oblivious? ;)

Generally, I will read every word on an Internet page if, and only if, I have a
particular reason to. This is parallel to my reading habits offline. If I like
an author's work or I find a book on a subject I find interesting, you can bet I'll
read every single word in that book. Speed reading is fine for some (I guess), but
it seems to contradict any sense of enjoyment. Soaking up lyrical prose at 50 pages
a minute would be, probably, a really wonderful way to have an anxiety attack that
would make Evelynn Wood proud ;)

In much the same way (both online and offline), if I'm just looking for a particular
nugget of information, I'm not sure what letter my eye-scan pattern creates, but I
definitely skim. This is one point where I felt the article fell a bit short of
exploring both sides of the issue. The assumption being that people read "everything"
on the Internet the same way they read their Facebook pages doesn't necessarily hold water.
It's certainly true in some situations.

As a for instance: If, for some strange reason, I was surfing the web (nobody seems to do that any more. They stopped driving down the information superhighway, too. Another example of Howard Johnson's Syndrome, except sometimes under water ;), we didn't know the square root of 25 (that's actually supposed to be the strange part ;) and discovered that the only place it was listed was on an online encyclopedia entry on square roots in general, I'd go there and check it out. One humongous old-school web page that covered everything from origin of the square, the root, why
the square and/or the root may have nothing to do with numbers, the history of the square root, detailed biographies of people involved in the development, application
and sustained nutrition of the Lego-like plant, etc. Now, keeping in mind that I only want to know that the square of 25 is 3, I would, of course, skim that page like crazy; probably looking for a table or list of some sort that listed out common
numbers and their square roots. This activity would be considered "F" type reading. More like "spots on a Dalmatian" reading, but who's counting? ;) I would be reading fast, not because I have the attention span of some dumb animal with a very short attention span (that's another situation of an entirely different colour ;), but because there was only one piece of information on that page that I was actually interested in reading. Taken out of context, this might reflect poorly on me and my reading habits, but, taken within the proper context, it would make me seem reasonably intelligent and somewhat efficient.

Another reason kids (there was a big deal made about how having computers in schools
didn't' help improve a child's education, in and of itself) might read more quickly online (And I am doing my very best to defend all of you complete idiots out there -
I'm just kidding, of course, but I'm ready for the hate mail ;) is that a statistical majority of content available for consumption online is worthless crap.
Phenomena like "Ad blindness" and "F" reading are not convenient fictions designed to make us bookish-folk feel superior. Think about how often you go to the library and just browse a few pages from a couple hundred books. Have you ever done that? Really? And, supposing you did, how many of those books would be plastered with advertising (like the advertisements on this page that, if you read regularly enough, basically cease to exist after a certain amount of time)? Or how many would
spontaneously open other books (in the "Adult" section ;)? Or how many would have titles like "The History and Culture of Ancient Sumeria" and actually be about 500 different ways you can eat Haggis and manage not to vomit?

Also, the 10 to 40 dollars that the average person might pay for
unlimited Internet access per month makes the ability to consume
volumes and volumes of useless information incredibly easy. If you
had to pay 40 dollars for a real book, would you buy the same trash
you spend hours mooning over online? My guess is probably not. In
the offline world, that 40 dollar expenditure on an 800 page book
that promised you (no matter how little marketing experience you had)
that it could teach you a revolutionary new method of selling antique
dildoes to geriatric women (or something else less offensive to geriatric
women ;) would seem like "COST." For your 40 dollar
monthly Internet access fee, that 800 page PDF would seem like
"BENEFIT." No matter how I feel about geriatric women
(for some reason, I just can't stop writing that now - I feel like Norm
McDonald talking about "hookers"
;), the way in which you read that
book in the offline world would, most likely, be much different than you way
you would read it online. Offline you'd probably pay more attention. After
all you just spent your 40 dollars and this is all you have to show for it
(those geriatric women won't be on life-support forever ;). Online, you could
skim the book to find all the relevant information you needed about dildoes and
move along, having, theoretically, spent only a few cents of your 40 dollar
investment. You, and whatever other kinks you're carrying around, would still
have 39 dollars and 98 cents worth of perusing to do ;)

DOG'S IS GOOD FOOD! if you've even scanned down THis far, you
probably rEad that line. why? because it was pRintEd In bold in an article that iS
mostly devoid of bolditude (it's NOt a real word, Look it up in the phonE book ;) did you read that and consider that it didn't make a whole lot of sense. are you wondering, right now, if I having just been jerking you around in a solipsistic pseudo-intellectual diatribe with the sole intention of wasting your time? you're probably right. as a matter of FacT, you are almost definitely parked on the left SIDE-street ;) thIs has beeN an experimenT, after all. tHe thIng that'S really most questionable about this Piece is the question of "why would I go to such lengths just to see whAt happens?" think about it. admitting you've just wRitten An opinion piece that doesn't necessarily Gel on puRpose, provides no reAl value and
may not have even been worth scanning is a risky Proposition for a blog autHor. okay, more directly, it's a risky proposition for a blog author who wants you to continue to read his blog and has a reputation to uphold as a semi-competent working
professional in the field. i'm one of those kind of blog writers. but, now that you've read this post and its half-hearted apology are you more or less likely to trust that the next post you read will contain useful and/or relevant information?

Believe it or not, I'm actually interested in your opinion. Let me know what you think. Was this post as fun for you as it was for me? Did you enjoy finding all the incorrect and goofed-up stuff inside it? Do you think you found it all? And, most importantly, does this little math trick at the end redeem this post in any way
whatsoever? I put it on the bottom of the "F" so it would be easy to find, so here it is:

If you want to multiply any number by 5, divide it by 2 and then move the decimal place one over to the right. If you want to multiply any number by 25, divide it by
4 and move the decimal place to the right two spaces. And, yep, it even works for multiplying any number by 125. To do that divide it by 8 and move the decimal place
over 3 spaces. If you have trouble dividing by any number greater than, but a multiple of 2, just divide by 2 twice (to divide by 4) and divide by 2 three times (to divide by 8). If you can't divide by two, I know a great Elementary school. I can probably get you in on my kid's recommendation ;)

Ex:

133 x 5 = (133/2) = 66.5 = 665
133 x 25 = (133/4) = 33.25 = 3325
133 x 125 = (133/8) = 16.625 = 16625

Cool, yeah? "F" me - It's an "E" ;)

Cheers,

, Mike




Please note that this blog accepts comments via email only. See our Mission And Policy Statement for further details.



Please note that this blog accepts comments via email only. See our Mission And Policy Statement for further details.