Linux
linux
A little busy today
Submitted by jacob on Wed, 10/28/2009 - 10:22amload average: 139.66, 112.91, 59.18
But not too busy to post this. The machine is still responding great.
top - 10:27:11 up 2 days, 3:02, 3 users, load average: 139.66, 112.91, 59.18
Tasks: 461 total, 6 running, 454 sleeping, 0 stopped, 1 zombie
Cpu(s): 8.4%us, 10.1%sy, 44.1%ni, 36.6%id, 0.7%wa, 0.1%hi, 0.0%si, 0.0%st
Mem: 8077204k total, 7940096k used, 137108k free, 150324k buffers
Swap: 1911608k total, 139204k used, 1772404k free, 3818652k cached
Linus and Windows
Submitted by jacob on Sat, 10/24/2009 - 11:40amGmail as the KDE default email client
Submitted by jacob on Fri, 10/23/2009 - 10:52pmI just got GMail working as the default email client for KDE. To do this, go to KDE Menu -> Computer -> System Settings and click on Default Applications.
There are plenty of notes on getting this working out there, but getting the subject and body working can be tricky. Select the radio button next to Use a different email client: and enter the following:
/opt/google/chrome/chrome https://mail.google.com/mail/?view=cm&fs=1&tf=1&to=%t&su=%s&%u
replacing /opt/google/chrome/chrome with the command for your browser.
Get unique lines in file using bash
Submitted by jacob on Mon, 10/19/2009 - 9:54pmI had to take a closer look at a distributed attack on one of our web servers today. The attack only involved around 50 hosts which seemed to be testing our URL parameters for injection susceptibility. Coldfusion has some protection against SQL injection, and we take extra steps, as every programmer should, to guard against it.
After identifying the attack vector, I was able to grep the log file for the signature of the attack which was present in the URL information.
Google Chrome..very fast
Submitted by jacob on Mon, 09/28/2009 - 11:18amI installed Google Chrome for Linux, the developer build, just to see what it was like.
It's fast; It is extremely fast. I wasn't planning on using it day to day, but I find myself clicking on it more often than Firefox.
The fact that it has no easy ability to block advertisements is pretty much overshadowed by the browser's sheer speed and usability.
And I don't like advertisements. I wonder if this is what Google is banking on.
Have you mooed today?
Submitted by jacob on Thu, 09/17/2009 - 10:12pmjacob@jakes-laptop:~$ apt-get moo (__) (oo) /------\/ / | || * /\---/\ ~~ ~~ ...."Have you mooed today?"...
Uptime
Submitted by jacob on Wed, 09/02/2009 - 10:59amtop - 10:51:06 up 733 days, 18:37, 1 user, load average: 0.00, 0.00, 0.00
Tasks: 59 total, 1 running, 58 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.0% us, 0.0% sy, 0.0% ni, 100.0% id, 0.0% wa, 0.0% hi, 0.0% si
Mem: 1020096k total, 963936k used, 56160k free, 234152k buffers
Swap: 2104504k total, 10536k used, 2093968k free, 598820k cached
My new laptop and the frustration of Windows
Submitted by jacob on Tue, 08/18/2009 - 9:21pmI'm typing this on the second laptop I've ever owned, and the first one that actually shows the color red on the screen. I purchased an IBM Thinkpad R51e on craigslist for $150.00. There's nothing really special about it. It's a very solid machine, has a 2.6 GHZ Pentium M with over a gig of RAM, a CDRW drive, and a 15" screen. It does have a 4200 RPM, 40 GB hard drive, but I can buy a 5400 RMB, 120 GB hard drive for less than $70.00 new.
Recovering deleted files from NTFS image
Submitted by jacob on Mon, 06/01/2009 - 9:25amSometimes, it becomes necessary to recover deleted files from an NTFS image. Using linux, a free utility called ntfsundelete can be used.
If the image is still mounted, you will need to unmount it:
$ sudo umount tmpmount
Then, you will want to use the losetup utility to associate a loop with a regular file (our image):
$ sudo losetup -o 15443968 /dev/loop0 /media/2Big/hd.img
The -o is the offset calculated from the last post (the start of the partition listed in fdisk * 512). The ntfsundelete utility can then be used:
$ ntfsundelete -s /dev/loop0