Featured Posts

Sendmail Test Script A simple script to verify Sendmail is properly configured: #!/usr/local/bin/perl print “Content-type: text/htmlnn”; open (MAIL, “|/usr/lib/sendmail -t”); print MAIL “To: user@domainn”; print...

Read more

PERL Test Page A simple PERL test page: #!/usr/bin/perl print “content-type: text/html nn”; print “This PERL test was successful!”;

Read more

Killing Defunct Processes A defunct process, also known as a "zombie", is a child process which has not been terminated by the parent process that created it.  A defunct process can only be killed by the parent process that created...

Read more

Passing Health Care Reform, A Lesson from 210 B.C.

Posted by Kyle Blankenship | Posted in Political | Posted on 25-01-2010

Tags: , ,

0

In Dan Ariely’s book, Predictably Irrational, the author takes note of a historical lesson that leadership needs only to provide the proper motivation:

In 210 BC, a Chinese commander named Xiang Yu led his troops across the Yangtze River to attack the army of the Qin (Ch’in) dynasty. Pausing on the banks of the river for the night, his troops awakened in the morning to find, to their horror, that their ships were burning. They hurried to their feet to fight off the attackers, but soon discovered that it was Xiang Yu himself who had set their ships on fire, and that he had also ordered all the cooking pots crushed.With no route for retreat, the army had no choice but to be victorious or perish.

Democrats could learn a lot from this Chinese Commander. While this Congressional fight hasn’t resulted in any blood shed, losing this battle will leave many Democrats seeing their districts painted red.

GD Test Script

Posted by Kyle | Posted in Testing | Posted on 14-01-2010

Tags: ,

0

A simple script to ensure GD is installed:

<?
$array=gd_info ();
foreach ($array as $key=>$val) {

if ($val===true) {
$val=”Enabled”;
}

if ($val===false) {
$val=”Disabled”;
}

echo “$key: $val <br />n”;

}
?>

PERL Test Page

Posted by Kyle | Posted in Testing | Posted on 14-01-2010

Tags: ,

0

A simple PERL test page:

#!/usr/bin/perl

print “content-type: text/html nn”;

print “This PERL test was successful!”;

Sendmail Test Script

Posted by Kyle | Posted in Testing | Posted on 14-01-2010

Tags: ,

0

A simple script to verify Sendmail is properly configured:

#!/usr/local/bin/perl
print “Content-type: text/htmlnn”;
open (MAIL, “|/usr/lib/sendmail -t”);
print MAIL “To: user@domainn”;
print MAIL “From: user@domain.comn”;
print MAIL “Subject: Sendmail testnn”;
print MAIL “This is a test of sendmailn”;
close (MAIL);
print “Message sent”;
exit;

PHP Mail Test Page

Posted by Kyle | Posted in Testing | Posted on 14-01-2010

Tags: , ,

0

In order to ensure PHP Mail is properly configured on your server, you can create a simple PHP file with the following code:

<?php

$to = “user@domain.com”;
$subject = “Test mail”;
$message = “Hello! This PHP Mail test is successful!”;
$from = “sender@sendingdomain.com”;
$headers = “From: $from”;
mail($to,$subject,$message,$headers);
echo “Mail Sent.”;

?>

This page will send the email to the specified address upon being loaded in your web browser.

Killing Defunct Processes

Posted by Kyle | Posted in Linux | Posted on 14-01-2010

Tags: , ,

0

A defunct process, also known as a “zombie”, is a child process which has not been terminated by the parent process that created it.  A defunct process can only be killed by the parent process that created it or by killing by the parent process entirely.  To find the parent process, open terminal and run:

ps -fe | grep defunctprocessname | awk ‘{print $3}’

This displays a list of the PIDs of the parent process(es) that will need to be killed in order to terminate the child process.  To kill each of these process, open terminal and run:

kill PID

If you are unable to kill these processes using the normal kill command, using the -9 switch will force the process to terminate:

kill -9 PID