It’s again time for the fourth and final question in the $25 Amazon Gift Card Giveaway. apokalyptik, Ben P., Mahmoud, and Olivers won week 3 by answering our question most accurately.  To recap, every week we are asking a Linux question.  We want readers to post their answer in the comments section at the bottom of the post.  At the end of this week the person who has answered the most questions correctly will win a $25 Amazon Gift card.  If there are four different winners each week, a winner within the winners will be chosen at random.  If there is a tie, the winner will be determined based on who posted their answers the fastest.  Go here for the complete rules.

Question 4 : Week 4

From the command line, how do you remove all the blank lines from example_file1 and output the results into example_file2?  Note, you want to preserve example_file1.

The most complete and straightforward answer will win!

Post your answers at the bottom of this post in the comments!

Remember, subscribe to the RSS feed to get notified of the answer.  To prevent copying of answers, you will not see any comments until the end of the week.

It’s time for the third question in the $25 Amazon Gift Card Giveaway. Chaoslica won week 2 by answering our question most accurately.  To recap, every week we are asking a Linux question.  We want readers to post their answer in the comments section at the bottom of the post.  At the end of week four the person who answers the most questions correctly will win a $25 Amazon Gift card.  If there are four different winners each week, a winner within the winners will be chosen at random.  If there is a tie, the winner will be determined based on who posted their answers the fastest.  Go here for the complete rules.

Question 3 : Week 3

From the command line, how would you get the size of all files and directories and output them from highest to lowest size?

The most complete and straightforward answer will win!

Post your answers at the bottom of this post in the comments!

Remember, subscribe to the RSS feed to get notified of the answer as well as the next question!  I will update this post every few days with the progress of the contest.  To prevent copying of answers, you will not see any comments until the end of the week.

* Update *

Congratulations to week 3 winners: apokalyptik, Ben P., Mahmoud, and Olivers.  Each answer was a bit different, but all of them are acceptable.  See the comments for the answers. Also, please note, Ben is the only contestant to have won twice thus far, putting him in the lead to win the gift card.

Check the home page soon to see the final week 4 question.

So you want to do something nice for your mother on the glorified Mothers Day holiday?  Flowers are always an easy, unthoughtful gift.  Why not step outside the box and create mom something really cool?  Theres an awesome guide on creating a digital picture frame from an old laptop computer running Linux.

The author of the guide explains how he bought a 500Mhz PIII processor, with 128MB of ram, a 4GB hard drive and a wireless card for $75.  He then installed Damn Small Linux and went to work configuring some scripts to automatically perform some tasks.  Finally, he shows how he reconstructed the laptop to fit the look of an actual picture frame by taking away pieces of it.

What’s really neat about this idea is if you can set up an internet connection on it, you could essentially configure it so you can remotely update it via SCP or RSYNC with pictures from anywhere so your Mom can always be up to date with pictures from you.

It’s time for the second question in the $25 Amazon Gift Card Giveaway.  Ben P. and John Stevens won week 1 by answering our question most accurately.  To recap, every week we are asking a Linux question.  We want readers to post their answer in the comments section at the bottom of the post.  At the end of week four the person who answers the most questions correctly will win a $25 Amazon Gift card.  If there are four different winners each week, a winner within the winners will be chosen at random.  If there is a tie, the winner will be determined based on who posted their answers the fastest.  Go here for the complete rules.

Question 2 : Week 2

How would you set up a recurring task of “task.sh” to run every day at 8:00am?

The most complete and straightforward answer will win!

Post your answers at the bottom of this post in the comments!

Remember, subscribe to the RSS feed to get notified of the answer as well as the next question!  I will update this post every few days with the progress of the contest.  To prevent copying of answers, you will not see any comments until the end of the week.

* Friday Update *

We’re still looking for people to submit answers!  You have until Sunday afternoon.

* Sunday Update *

I’ve approved all of the comments so you can see everyones answers.  The best, and most complete answer goes to chaoslica for remembering to make sure the task.sh file was excutable.

Congratulations to chaoslica for winning week 2.

Check back this week, or subscribe to the rss feed to get the week 3 question!

If you’re looking to get rid of the annoying system beep in Ubuntu, here is how to do it from both the command line, and from the Gnome desktop.

Disable the System Beep from the Command Line

#sudo vi /etc/modprobe.d/blacklist

And then add:

#pc speaker beep

blacklist pcspkr

Save and quit the file:

:wq

Now, remove the pcspkr module:

sudo rmmod pcspkr

Disable the System Beep in Ubuntu from the Gnome Desktop

This way is much easier.  Simply navigate to System -> Preferences -> Sound then navigate to the System Beep tab.  Uncheck the box labeled “Enable the System Beep” and click close.

Disable the System Beep from the Ubuntu Desktop

Here is a quick Linux tip to block incoming access to port 80 using iptables.

iptables -A INPUT -j DROP -p tcp --destination-port 80 -i eth0

The code above will drop all tcp packets coming into your Linux computer on device eth0 on port 80.  If your Internet connection runs through a device other than eth0, go ahead and make the adjustment.

To remove the iptables rule use the following code:

iptables -D INPUT -j DROP -p tcp --destination-port 80 -i eth0

For more information on using iptables visit the iptables man page.

Monitor Unix and Linux with Microsoft

Sean Michael Kerner is at Interop in Las Vegas where Microsoft has announced that their new Microsoft System Center Operations Manager allows you to monitor Unix and Linux systems.

Shilmover showed a live demo of Microsoft’s tool actually managing a Red Hat Enterprise Linux Server, SUSE Linux Enterprise Server and a MySQL database server. To be honest I’ve never seen anything like it before –  Microsoft demonstrating how it can manage Linux and Open Source technologies.

Microsoft is finally acknowledging that the open source and Linux/Unix world is slowly becoming the norm.  Instead of sitting back, they are coming up with new business models to adapt.  I suppose this is a good thing, but who really wants to use Windows to manager their Linux and Unix servers?

Read Sean Kerners article here.

How To Enable BCM43xx in Ubuntu 8.04

Here is a question I’ve been seeing pop up over the past few days:

My Broadcom bcm4306 Wireless card wont work in Ubuntu 8.04.  How do I fix it?

The most common reason is simply because Ubuntu did not enable the restricted driver.  If your Ubuntu 8.04 installation did not enable your Broadcom Corporation BCM4306 Wireless LAN Controller, here is how to enable it.

First, you need to make sure the b43-fwcutter package is installed.

sudo apt-get install b43-fwcutter

Next, navigate to System -> Administration -> Hardware Drivers

bcm4306 wireless driver in ubuntu 8.04

You should see your Broadcom 4306 device listed.  Check the box to enable it.

Now your bcm43xx Broadcom Wireless card should be working in Ubuntu 8.04!

One of our goals is to provide Linux administrators and users alike a place to quickly learn and develop their Linux skills. In keeping with this goal we are starting a Linux contest. Every week we will ask a Linux question, introduce a problem, or offer a challenge. Readers who want to participate must post their answer in the comments section corresponding with the question. At the end of four weeks the person who answers the most questions correctly will win a $25 Amazon Gift card.

So, in short, here is how the contest will work:

  • One question will be posted every week on the Foogazi homepage (Subscribe to the RSS feed to receive updates whenever we post a new question)
  • It is up to YOU to answer the question by posting a comment
  • Comments will not be approved until two days after the question is posted to ensure everyone has a fair chance and to prevent copying.
  • The best answer submitted to the comments after 2 days will be displayed in the main post and a winner will be declared
  • The person who answers the question correctly and most accurately will win that weeks question challenge
  • At the end of the four week challenge, the person who has the most questions answered correctly will win a $25 Amazon gift card
  • In the event of a tie, the winner will be determined based on the time it took to post their answers, with the fastest person being declared the winner
  • Speed is not as important as the quality of the answer!

The idea is to learn through challenges. So let’s get started!

The questions will start simple and increase in difficulty as the weeks go on.

Question 1 : Week 1

From the command line, how do you disable a user from logging in via FTP?

Post your answers in the comments!

Remember, subscribe to the RSS feed to get notified of the answer as well as the next question!

*Wednesday Update*

There have only been a total of 5 submissions since Monday. I am not approving comments until Friday so you still have a chance to submit an answer and win!

*Thursday Update*

If you think you know the answer to the question above, post it in the comments!  The answers will be revealed sometime this weekend and Monday we will have a new question!

*Sunday Update*

I’ve approved all of the comments so you can see everyones answers.  We didn’t have much of a turn out for week 1, so be sure to pass on the word that we’re running a contest.

The best answer from week 1 was submitted by Ben P and John Stevens.

The answer is: echo username >> /etc/ftpusers or "username"

Congratulations to Ben and John.  Check back this week, or subscribe to the rss feed to get the week 2 question!

Wubi Is Just Not Ready

Over the past few weeks prior to the Ubuntu 8.04 “Hardy Heron” release, I was skeptical about Ubuntu fully endorsing and officially supporting Wubi in Ubuntu 8.04. Previously, Ubuntu 7.04 and 7.10 included Wubi, but unofficially. I’ve tested Wubi on a few different computers, and have had varied results. It works sometimes, other times it fails completely. I’ve heard the same stories over and over from multiple Linux users that Wubi either works or doesn’t work at all. The inconsistency of Wubi is what worries me.

Wubi is supposed to be a way for potentially new Linux users to try out Ubuntu without needing to partition a drive, or know anything technical at all, right from the Windows desktop.  A few clicks, and magically, Ubuntu is installed.  However, it’s proven not to be the case for a lot of users.

Originally, I thought Wubi becoming “official” would be great for Ubuntu, and the Linux Desktop in general.  If users can easily install a Linux distribution that “just works”, then the Linux desktop is on the right track to becoming a much more mainstream operating system.  Wubi is an awesome project, don’t get me wrong.  I’m all for users being able to install a Linux distribution without having to bother with partition information, right from their Windows desktop.  Among the many advantages, Wubi helps pull in a new crowd of potential computer users that just may make the switch from Windows to Linux if they see how easy it can be.  However, if these potential users are installing Ubuntu with Wubi and getting errors, how does that make Linux look? Bad.  Buggy.  “Linux doesn’t work!”.  Right?

I’m amazed that Ubuntu has provided Wubi in the Long Term Release with such an inconsistent success rate.  Each new user that tries out installing Ubuntu with Wubi faces the chance of Wubi failing.  It makes Ubuntu, and Linux in general look bad.  Heck, even Mark Shuttleworth himself called out for users to test Wubi before the actual release of Hardy Heron so that developers could fix any last minute issues. Obviously everything wasn’t fixed.  A quick glance at the Ubuntu Wiki for Wubi, shows over twenty known issues. From boot problems, to crashes, to random error messages.  It’s just not ready to be supported officially.