Funny support call

Sometimes I honestly feel like this when I call tech support and I get "John" (who’s real name is "Habeeb")

Jing Project: Simple “MindShare”

It’s not common for me to find a tool that’s really useful these days. Especially with the advent of spyware, software has just become too cumbersome for something free to spark my interest. Sure, I’ve used many a screen capture utility but nothing has really stuck out. Co-workers always ask for explanations on how to do things and it can be nice to write up a handy document for repeatable tasks but it’s never really as easy as it should be; until now.

 

So, What is it?

The application I spoke about was Jing. This application is a spin-off free product of Camtasia (TechSmith) and allows you to capture screenshots and allows you to easily upload them to a specified FTP server for sharing. I really enjoy this concept because it closes the gap between screen capture and presentation. Previously I would have to capture what I was thinking and then open the FTP program, then upload it, then copy and paste the URL… then send it to the person in need. With Jing I just capture, and press one button. The Image/Video (yes, VIDEO) is now on my clipboard and ready for presentation.

 

imageWhat Can It Do?

Jing can capture images and video (up to 5 minutes) and automagically FTP them to your server. Other transport mechanisms are available like Screencast.com, Flickr and simple saving to a file on local storage. The interface is very straight forward and easy to use. On the right you can see how the FTP configuration page looks.

 

Check out Jing today and see how easy sharing your mind can be!

Time Warner Cable: 2.8Mbit Upstream

Hey- Apparently Time Warner Cable doesn’t rate-limit UDP packets (as far as I can tell).

 

Here is the scenario:

Time Warner Turbo (15Mbit down / 1Mbit up) connected to OpenVPN (10mbit limit) at a local data center.

 

Here is what the connection path looks like:

Time Warner Cable –> OpenVPN –> Squid Proxy –> Website

 

At first I didn’t know what to think – I can normally achieve around 1Mbps up but I was getting over 2.8Mbit/sec upstream! I thought to myself “This has to be Squid caching the upload test data” so I altered the Squid configuration to explicitly NOT cache the data from SpeakEasy’s test site.

 

Here’s what I found:

 

Before
image
After (10Mbit limited by OpenVPN)
image

 

How can this be? Well it might have to do with the fact that Time Warner doesn’t monitor UDP traffic (at least to OpenVPN UDP 1194). After reading many documents, it’s evident that traffic shaping TCP is easy and TCP comes with traffic shaping mechanisms and UDP does not. My speculation is that Time Warner simply drops packets when rates are too high, causing TCP to (inherently) re-send data that is lost.

 

Quick HowTo

The first thing you should do is grab a copy of Untangle. It’s quick and easy to set up OpenVPN out of the box.

  1. Obtain OpenVPN
  2. Bring OpenVPN online at a Data Center or as a VM on your leased server at a Data Center.
  3. Connect to OpenVPN from your Time Warner connection.
  4. Start a VM with Squid caching proxy running. Make sure that you have access to this VM from your VPN client (configured in Untangle)
  5. Start Squid
  6. Open your favorite browser and point it to the squid proxy (private IP address via OpenVPN)
  7. Access speed test sites (all OpenVPN traffic is UDP so you should be able to achieve speeds without using Squid)

Which is better? Firefox 3 or IE 7

image

Well now that Firefox 3 is out does IE7 have a chance? Personally I’ve used Firefox 3 quite a bit faster (even in its release candidate stages) than IE7.

 

Please vote below and show us who really is the winner.

{democracy:2}

GiveawayoftheDay.com – Xilisoft Video Converter

imageToday I downloaded and installed Xilisoft Video Converter. It seems to be a pretty promising tool as it can convert almost any video/audio format to another video/audio format. This becomes very helpful when converting those old VHS tapes to DVD’s or trying to get your favorite format to your iPod or iPhone.

Better hurry – This download won’t last long as they have you activate it during the offer. Keep in mind that applications on givawayoftheday.com typically aren’t supported (because they’re free).

http://www.giveawayoftheday.com/xilisoft-video-converter/

Where’s FireFox 3.0?

Well, I woke up today and I remembered that today is “Download Day”  but wait…. spreadfirefox.com is still the same… where’s my FireFox? Here’s what they have to say:

image

Check out the Mozilla wiki that tracks their process.

Linux SysAdmin Toolbox

imageWorking with Linux over the years has really exposed me to many useful and unique tools. I’ll show you a few of the tools that help me get through my day a bit quicker and more efficiently. 

Moving/Grabbing FIles

Getting files to your Linux system can be easily achieved using the tools below.

wget

The wget command allows you to retrieve files from an FTP/HTTP or HTTPs source. Typically use this command to get new packages or new tarballs to your server.

Usage:
# wget <source>
# wget http://us2.php.net/get/php-5.2.6.tar.gz/from/this/mirror

scp

SCP allows you to transfer files over SSH (TCP Port 22). You can even transfer files between two servers over SSH.

Usage:

# scp <source> [email protected]:/path/on/remote/host

Looking for FIles

Lose a file? Need to list all files modified after a certain date? Want to remove all files with "foobar" in the name? Check out the commands below.

find

The find command allows you to search for a specific file by name, size or modified time. The criteria mentioned before is just part of what you can do with find. To see full functionality type "man find" to view the manual page.

# find / -name foo.atxt (this command finds all files named "foo.txt" starting in the root directory)

Another usage of find which is quite handy is the -exec flag.

# find / -name foo.txt -exec ls -lth {} \;

This command will list all files named foo.txt and run the command "ls -lth" on each file. This can be useful to apply a command to all files that match a certain string.

locate

Use the locate command to find a specific file quickly. This is more primitive than the before mentioned find command. It relies on a database of files which it performs its lookups. To update this database run a command, appropriately named, "updatedb".

Usage:
# locate foo.txt

Sorting Results

Since a Linux Administrator typically needs to sort through massive log files, show certain fields and manipulate output; an admin needs to know about the tools below.

sort

The sort command allows you to sort the results of your output. To sort the results by the first regular character (not a symbol). Here is an example of how to use sort with the locate command:

# locate bin | sort

Piping the output of locate to sort will show all results in order.

uniq

Uniq is short for, you guessed it, unique. Uniq accepts input from STDIN (Standard Input) and shows only unique lines of text. This command basically strips duplicates.

# cat foo.txt | uniq

awk

Awk is a pattern scanning engine. The most common usage is to separate rows of text into chunks. The chunks, by default, are separated by spaces. For instance this sentence: "The quick brown fox" when piped to this command: "awk {‘print $2’}" will print simply "quick".

# echo "The quick brown fox" | awk {‘ print $3 ‘}
brown

This command can be very useful when combining it with long field-driven lists.

wc

wc (Word Count) will count the number of words, newlines and bytes in a file. Typically this command is used with the "-l" flag to count the lines if output. This command accepts input from STDIN (Standard Input).

# cat foo.txt | wc -l
300

This means that the file "foo.txt" contains 300 lines.

Running Commands (that may take a while)

Since the command line interface (CLI) usually offers no progress bar (except for certain apps like wget), you’ll sometimes need to run a program for a long time. Searching through millions of files? Removing a directory containing large quantities of data/files? What if you get disconnected while running one of these commands in the foreground? Use one of the solutions below to run your commands.

Starting Commands in the Background

It is generally useful to start a command, which takes a long time, in the background. Think of these programs as "service" programs which run without a terminal (ssh session, or physical terminal) attached. To start a program in the background simply add a space and the ampersand (&) after the command.

# sleep 1000 &

The above command will be executed in the background. The command waits 1000 seconds to end. Check the progress if your command by issuing "ps aux | grep sleep" to view the PID and status of your command.

To force a command currently running in the foreground to run in the background press "CTRL + Z". You will then be presented the PID. Disregard the "Stopped" message. This indicates the foreground process has stopped and is now running in the background.

screen

Using the program called "screen" allows you to run multiple virtual terminals behind the scenes. This can be useful for programs (and commands) that can’t be ran in the background. Instead of running multiple SSH sessions you can simply type "screen" to initiate a new screen. Press "CTRL + AD" to detach the current screen. Type "screen -r" to reattach to the screen(s) currently active. To install screen on CentOS/RHEL issue the following command:

# yum -y install screen

Department of Homeland Security Scraping Sites?

imageRecently I noticed that one of the web servers for my business, Admo.net, had a higher than normal load. Normally this means that someone has exploited a PHP script and is mass-mailing everyone on the ‘net. This time, however, it looks like there was an IP address 204.248.24.163, from a OrgName DHS/BSL002A. This netblock belonged to "dhs.gov”. I quickly wondered what this was and pulled up the site.

Apparently the Department of Homeland Security has been scraping a harmless gaming community’s forums for some type of information. The alarming thing was that the requests came in at 5-10 request per second. Why must they scrape the sites? If they do, why can’t they do it at a more comfortable rate? This is crazy!

 

CentOS 4.x – But I want PHP5 and MySQ5

This sometimes can be an issue. I want PHP5 but I only have CentOS 4.6. What can I do? It seems like the CentOS repository doesn’t have PHP5, only PHP4. Enter “–-enablerepo centosplus”. Just add “—enablerepo centosplus” after yum and you’ll be able to install PHP 5, Apache 2.0 and MySQL 5 in no time.

# yum –enablerepo=centosplus –y install php httpd mysql php-mysql php-gd

The above also works for upgrades by substituting “install” for “upgrade”.

Linux Command: diff – What’s the difference?

Sometimes it’s necessary to quickly determine the difference between two files. The command “diff” can be particularly useful if you find yourself in this situation.

The most simple usage of diff is “diff <oldfile> <newfile>”.

The output looks like this:
image

The output of diff is really how to alter the original file to match the new file. “1a2” means to add a new line to the old file after line 1. This line should be “bar” as signified by the “>” mark.

Often patches are distributed using the diff file. PHPBB usually offers this as a way to patch their open source code. In short, using diff can save you time and offer a way to compare to configuration files to see their differences.