Archive for the 'Tools' Category

Locate vs Find

Tonight at the Ubuntu Utah User Group I presented about Locate vs Find.

The slides are here and written in S5.

Kevin Kubasik also presented on Desktop Search in Gnome. It was pretty cool as well.

The presentations went very well and was streamed and recorded by Utah Open Source Foundation.

POW: Bluetooth Improvements in Fedora 8

The POW is going to be the improvements made in the Bluetooth functionality in Fedora 8. I’m actually quite impressed with it as its been a bit of a challenge to keep my little mouse connected in the past.

Fedora 8 provides a new extended technology with its bluez-gnome package. In fact, the simplicity of it is that I only have to be able to click and approve a new device.

When I first turn on my bluetooth mouse and start to move it around, it doesn’t work, but up in the top right hand corner of my GNOME desktop is the bluetooth manager. It has a message for me:

bluetooth-authorize.png

The message indicates a click to authorize the device, namely the bluetooth mouse. (One note here, I was originally unable to use my touchpad, so I had to resort to other tactics [not pretty] to enable my mouse. Probably ought to have some other options available instead of clicking.)

Clicking on the notification window above brings me to an authorization window.

bluetooth3.png

At this point, authorization is quite simple. Click yes for a one time authorization of the mouse (Note the Bluetooth Travel Mouse indicated in the description), and to authorize it more permanently, choose Always Grant Access.

That’s it. My Bluetooth mouse is now enabled and working. I’d say this is much friendlier than what I used to have to do, including running hidd –connect <bluetooth id> after pressing the little connect button on the bottom of the mouse. This is sure nice now!

Its possible, that at some point, disconnecting the device might be necessary. To do this, right-click on the nice little Bluetooth logo at the top right of your screen.

bluetooth5.png

Choose Preferences. Up pops the Bluetooth Preferences window. From this window, three tabs are available. In the first (and also selected) tab, there is a section at the bottom of the window which lists the devices that are currently bonded and/or trusted. Choose the device from the list and then the appropriate action. The choices are Disconnect, Trust or Delete.

bluetooth4.png

In addition to just configuring your devices, it appears it might be possible to do things like Bluetooth DUN with a Treo, or enable data synchronization between laptops. One thing I’ve always wanted to try is to get my bluetooth headset working so I could do Skype or Asterisk phone calls through my headset, to my computer and out through the service.

Cheers,

Herlo

Werewolf (Fedora 8) Upgrade in 3 Easy Steps Using yum

Recently, there was a request in one of my comments on this post. The request was for an easy way to upgrade from Fedora 7 to Fedora 8. So I took this on as a bit of a challenge. I feel pretty comfortable with yum and I thought it would be a good and easy task.

A bit of warning here, make sure your current Moonshine ( Fedora 7 ) release is update by running yum update. Also, it is recommended that backups be made of files being modified. If you don’t backup the file, it may be impossible to fix in the future. YOU HAVE BEEN WARNED

Let’s upgrade Moonshine ( Fedora 7 ) to Werewolf ( Fedora 8 ) in three easy steps:

First things first, lets print out some version info:

$ cat /etc/*release
Fedora release 7 (Moonshine)
Fedora release 7 (Moonshine)
$ uname -r
2.6.23.1-21.fc7

Its easy to tell that this machine is indeed using Moonshine ( Fedora 7 ), so let’s upgrade!

Step 1 - Modify the yum repo files

Located in /etc/yum.repos.d directory are where the yum repository files are stored. We need to modify one line so that yum will know where to look:

$ su -
# vim /etc/yum.repos.d/fedora.repo

Find the first line that starts:

mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-$releasever&arch=$basearch

and change it:

mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-8&arch=$basearch

What changed? Well, the $releasever value is the current value for our version of fedora, in this case 7. By changing it to 8, it’ll load the correct repositories for Werewolf (F8) instead of Moonshine (F7). Save the file, and now we’re ready to move onto the next step.

Step 1 (Alternate)

Since posting this, I’ve learned that another option is available. To update the repositories, its possible to install an rpm to accomplish the same as above and it won’t require Step 3.

Choose your mirror from http://mirrors.fedoraproject.org. I picked University of Oregon’s site because it was close to me.

# rpm -Uvh \
ftp://ftp.osuosl.org/pub/fedora/linux/releases/8/Everything/i386/os/Packages/fedora-release-*.rpm

Your ftp/http line here may be different, that is fine. This command installs the updated repositories for Werewolf ( Fedora 8 )

Step 2 - Upgrade

In this step, we just need to run (as root):

# yum update
fedora               100% |===============| 2.1 kB   00:00
primary.sqlite.bz2   100% |===============| 4.9 MB   00:03
Setting up Update Process
Resolving Dependencies
.. snip ..

A few prompts will appear, after the repository data is loaded, a list of several hundred megs (possibly a gigabyte or more) of packages will be ready to install. This is the moment of truth.

Transaction Summary
============================
Install     88 Package(s)
Update     836 Package(s)
Remove       1 Package(s)

Total download size: 1.0 G
Is this ok [y/N]:

Start the download of over 800 packages (in my case) and install and update your system. If you feel a bit of trepidation, I concur. Its still exciting though, isn’t it?

Is this ok [y/N]: y

Now aren’t you excited! In about 30-45 minutes, you’ll have a newly upgraded Werewolf ( Fedora 8 ).

Downloading Packages:
orca-2.20.0.1-1. 100% |=========================| 1.5 MB    00:01
.. snip ..

Step 3 - Cleanup and Reboot

Welcome to your new Werewolf. Treat it wisely. First things first though, we need to clean up our editing from step 1:

# vim /etc/yum.repos.d/fedora.repo

Find the first line that starts:

mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-8&arch=$basearch

and change it:

mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-$releasever&arch=$basearch

Save the file, or if you prefer, copy the backup you made over the modified repo file.

In addition, there are some items that aren’t in Fedora 8 the same way they were in Fedora 7. For these, read this guide. I didn’t have these problems myself, ymmv.

To get the newly updated kernel and all the new goodness of Werewolf, a reboot is necessary. Enjoy your new Lycanthrope on the flip side.

Cheers,

Herlo

Funny man page for rsyslogd

While doing my normal reading about new features in Fedora, I came across this snippet in the rsyslogd man page. The section I was reading was in regards to how to deal with security threats.

4.     Disabling inet domain sockets will limit risk to the local machine.

5.     Use  step  4  and  if  the  problem persists and is not secondary to a rogue program/daemon get a 3.5 ft (approx. 1 meter)
       length of sucker rod* and have a chat with the user in question.

       Sucker rod def. — 3/4, 7/8 or 1in. hardened steel rod, male threaded on each end.  Primary use  in  the  oil  industry  in
       Western  North  Dakota  and other locations to pump ’suck’ oil from oil wells.  Secondary uses are for the construction of
       cattle feed lots and for dealing with the occasional recalcitrant or belligerent individual.

Quite a good chuckle!

Cheers,

Herlo

POW: Codec Buddy

This week’s Program of the Week is a bit ahead of its release. The package is Codec Buddy, and is currently slated for release in Fedora 8 tomorrow.

Codec Buddy, with a little help from the Fedora and Fluendo development teams has grown into something that could be great. I see Codec Buddy really helping those who want to use and play non-free media sources from within Fedora. If you are currently running rawhide, you probably already know about this, but very soon, many other people will start to understand how Codec Buddy works as well.

One of the goals of the Fedora Project is to be free of any proprietary software. Though I don’t see that many people using Fedora without at least a few proprietary components, media codecs, drivers, etc. Maybe one day…we can always hope.

To that end, I am a big media buff. I regularly watch TV shows and movies that use proprietary codecs. As an example, most people don’t realize that using the reverse engineered DVD encoding provided by DVD Jon could be considered illegal. Fedora doesn’t want to be encumbered by these risks, and truthfully, I don’t blame them one bit. Considering that my backlog of mp3s and DVD rips will require an additional bit of software not normally included with Fedora, I think this is a great software solution. Give the user what they want without compromising the integrity of the project.

Codec Buddy is provided to help the average Joe understand the world of media formats. Its job was originally to provide a short description of why Fedora doesn’t include this in its distribution. Then point to where one might find more information about these formats. Codec Buddy has been altered a little, but attempts to accomplish the same thing using the Fluendo website.

Fluendo is the company that employs many of the individuals that work on the gstreamer project. Its quite a noble project, providing media codecs (installable formats) for many of the audio and video we like to use every day. Its great to have open source companies like Fluendo helping open source grow.

Codec Buddy works by launching a small application when someone tries to access a media codec not currently on the system. For instance, I’ve attempted to play a show I’ve downloaded.

Launch Totem

Opening Totem

Open the file

Opening a media file

Start the video

Start the video

As the video attempts to play, a prompt appears, indicating the media isn’t supported. Codec buddy then provides a few options to enable playback for this particular media format.

Choose your codec wisely, young padawan

The available items are MP3 Audio Decoder, MPEG Playback Bundle and MPEG4 Part 2 Video Decoder. By default only the MP3 Audio Decoder, which is also the only codec that will be installed without payment, is checked. The other two codecs are available for a small fee, which helps Fluendo to provide these codecs.

Clicking the “Get Selected” button will immediately start the download of the MP3 Audio Decoder (if it was selected).

Downloading the MP3 Codec

A license agreement then appears, make sure to read this and if you agree, click Accept.

Agreement

Once the agreement is complete, its time to purchase the remaining codecs. Choose Start Web Browser and in a few moments, the Fluendo website should appear. This should allow you to purchase the remaining codecs needed for the video I want to watch.

Open Web Browser

The Fluendo website has a good list of available codecs beyond the choices available in Codec Buddy.

Fluendo website

The purchase will seem similar to many others on the web, add things to the cart, and pay.

Fluendo is a good start. I’m sure there will be many people interested in purchasing these codecs here. However, I believe however, that the biggest problem is that most people can get these codecs for free on Windows, Mac and even other Linux distributions. So far, the thing I feel is missing here is the explanation for why charge for these codecs and who benefits.

Fluendo is a great resource and provides some kick-ass codecs. If there is no explanation as to why we need to pay for something that one can get for free. Potential customers who don’t understand the reasoning behind it might go elsewhere, or worse even, choose another distro or operating system.

I love fedora for the freedom it gives me to choose my path. I love fedora for its focus on making sure things are free and open, both monetarily and in liberty. I love fedora for trying things like Codec Buddy, I want it to succeed. I hope that with a few suggestions, both fedora and Fluendo can make Codec Buddy the informational tool that it was originally intended.

Cheers,

Herlo

POW: Yum installation by groups

The second in the Program of the Week (POW) is here.

Yum, the Yellowdog Updater Modifer, has a very interesting feature. One which you might find useful if you want to install an entire set of packages for say a new “Windows File Server”.

Yum provides this feature right out of the box these days, and its quite a nice feature. SUSE 10.1 has rug which is a very similar feature, called bundles. I would guess that Ubuntu either already has this feature, or will in the near future.

So how does installation by groups work? Pretty simple really, first we must learn a few new options in yum:

First is “grouplist”. Grouplist will tell you which groups of packages you have installed and which ones haven’t been installed.

$ yum grouplist
Setting up Group Process

Installed Groups:
  Office/Productivity
  Engineering and Scientific
  .. snip ..

Available Groups:
  .. snip ..

  Windows File Server
  .. snip ..

  Development Tools
Done

In my case, you can see that I’ve not yet installed “Windows File Server”. Interestingly enough, I’m not sure what’s in that group of packages, so its time to check:

$ yum groupinfo "Windows File Server"
Setting up Group Process
Group: Windows File Server
 Description: This package group allows you to share files
 between Linux and MS Windows(tm) systems.

 Mandatory Packages:
   samba
   samba-client
 Default Packages:
   system-config-samba

Wow, quite a few packages, there’s also some good information here. We now know that there are 10 optional packages and 1 conditional package that can be installed. To get the details on any of these packages, yum can tell us:

$ yum info samba
  .. snip ..

Available Packages
Name   : samba
Arch   : i386
Version: 3.0.26a
Release: 0.fc7
Size   : 3.1 M
Repo   : updates
Summary: The Samba Suite of programs
Description:Samba is the suite of programs by which a lot of
PC-related machines share files, printers, and other
information (such as lists of available files and printers).
The Windows NT, OS/2, and Linux operating systems support
this natively, and add-on packages can enable the same thing
for DOS, Windows, VMS, UNIX of all kinds, MVS,
and more..

Yum informs us that the “samba” package is useful for setting up file sharing between Windows and Linux. Other packages from the list above will also be installed so we’ll get to play with some of those as well. If desired, ‘yum info’ can be run for each of the packages found in the grouplist. However, for us, lets move on and install the group of packages:

$ su -# yum groupinstall "Windows File Server"
.. snip ..

============================================================
Package               Arch    Version        Repo      Size
============================================================
Installing:
system-config-samba   noarch  1.2.52-1.fc7   updates  287 k
Installing for dependencies:
samba                 i386    3.0.26a-0.fc7  updates  3.1 M
Transaction Summary
============================================================
Install      2 Package(s)
Update       0 Package(s)
Remove       0 Package(s)

Total download size: 3.4 M
Is this ok [y/N]:

At this point, we need to choose whether we’re going to install the 2 packages that will enable samba for us. Hitting enter will answer no, so we need to type a ‘y’ and hit enter. The packages are then downloaded, and installed:

Is this ok [y/N]: y
Downloading Packages:
(1/2): system-config-samb 100% |=============| 287 kB  00:00
(2/2): samba-3.0.26a-0.fc 100% |=============| 3.1 MB  00:02
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: samba                 ################## [1/2]
Installing: system-config-samba   ################## [2/2]
Installed: system-config-samba.noarch 0:1.2.52-1.fc7
Dependency Installed: samba.i386 0:3.0.26a-0.fc7
Complete!

As you can see, its pretty nice to be able to install a group of packages together, letting yum do the work to figure out the details. In another article in the near future, I’ll cover how we create these relationships and build a back end yum server from the ground up.

Cheers,

Herlo

POW: bash-completion - Bash Auto Completion in Fedora using yum (and more)

In an attempt to consistently blog, I am starting a new series here on fedora-tutorials.com. Program of the Week (POW). Hopefully, this will excite and inform all of us about the cool programs available in Fedora. So see you next Wednesday for another program.

Over the past year or so, I’ve been on the hunt for several things that I find in other Linux distros that I cannot find in Fedora. Its not very common, but on occasion I do run into something that’s not there on Fedora. One of them was the ability to automagically complete many of the command lines for many things.

One of them, and probably one of the biggest, was the fact that yum did not have tab completion for available packages. Today is my lucky day! While chatting and helping my students with their labs today, one of them mentioned to me that he could tab complete a particular command on his box. I of course inquired, because it interested me, as to the package name. It turns out my bash tab completion dreams were just about to come true! He told me about this amazing package that would let me use tab completions for things like the service command, man and of course, yum.

I was blown away! So immediately after this discussion, I started searching for this elusive package I’ve never heard of before. Sure enough, as he informed me, bash-completion does exist and does some amazing things. After hunting around a little on google, here’s some of the stuff I found. I’ll also include the links at the bottom of this post.

as root try this: (note [Tab] means you should hit the tab key)

# service ht[Tab]

What you’ll notice is that one of three things happen. If you’ve got the bash-completion package installed already because you’re ahead of the game, it should auto-complete for you. Without bash-completion, this doesn’t happen, but its also possible that since bash already has some completion in place, it might auto complete a directory for you, but that’s definitely not what you want.

If you’ve not already installed bash-completion, I’d suggest you do it now. On Fedora 7, run the following command:

# yum install -y bash-completion
..snip..
Installed: bash-completion.noarch 0:20060301-3.fc7
Complete!

Now that bash-completion is installed, we need to invoke the tools. Normally, this is not needed, and a reboot/re-login will take care of this as well, but since I wanted to use this right away, I did the following as an unprivileged user:

$ source /etc/bash_completion

This doesn’t seem to do much, but its actually quite powerful. The source (or .) will load the environment variables from the /etc/bash_completion script into my current environment. Luckily for us, when we now log into root, /etc/bashrc will accomplish this for us without any intervention. To test that it worked, try running the following command as the same unprivileged user:

$ unalias[Tab]
.=     ll=     ls=     vi=     which=

Note that when I pressed twice, a list of the currently available aliases appeared. Nice ey? Let’s complete this:

$ unalias w[Tab]

Now produces:

$ unalias which

And completes the string as expected. Now we’re getting somewhere! But why did I really want to explain this?

Oh yeah! yum

With bash-completion, yum can now provide us with a list of available packages, similar to the auto completion capability in apt-get or aptitude from Ubuntu or Debian. Say for instance you want to see all of the packages available for install that match what you’re looking for, but don’t want to run yum list or yum search because, in truth, it just takes to long! Now you have an alternative:

# yum -y install bal[Tab]

Produces:

ballbuster.i386  ballz.i386       balsa.i386

Adding another ‘lb’ to the end of that string (and then the tab key of course) should help us to complete to the package we’d like to install.

# yum -y install  ballb[Tab]

Then completes to:

# yum -y install  ballbuster.i386

Hitting enter then installs the ballbuster package, and its quite a fun game!

.. snip ..
Installed: ballbuster.i386 0:1.0-1.fc6
Dependency Installed: ClanLib.i386 0:0.8.0-4.fc7
Complete!

Of course, there are hundreds of others tab completions available (and there’s a good way to list many of them too, even if its a bit cryptic). Try these on for size:

Are you a developer?

$ svn c[Tab]
cat checkout  ci     cleanup   co     commit    copy    cp
$ make [Tab]
all clean dist-clean

What about a systems administrator?

# modprobe -r b[Tab]
battery    bay        blkcipher  bluetooth  bridge     button
$ man cron[Tab]
cron     crond    crontab
$ ssh herlo[Tab]
herlo-f7   herlo-lap  herlo.org
$ grep --[Tab][Tab]
 --after-context=  --directories=   --invert-match   --only-matching
 --basic-regexp    --exclude=       --label=         --perl-regexp
.. snip ..

To help you wade further through, try out the following two commands:

  • complete -p
  • declare -f

Be aware that these are advanced components and can really be confusing if you’re not a developer and just want to use the features. The complete command seems to provides some tools to do additional auto-completion. I also think that its nice to be able to extend this functionality to other applications as well.

As promised, here’s a few links to help your completion introduction. Note: Some of these links provide more than just the simple tab completion:

Sexy Sexy Penguins needs an image

Yes, that’s right folks. I’m looking for a new image to adorn the top of my blog. I’ve got this pretty new theme (not shown on my site yet) but it needs a fresh new coat of penguin love.

So I thought I’d share with the community and see if anyone could come up with a new image for my blog. The general idea is it has to go with my blog title “Sexy Sexy Penguins”. I’m imagining a few “very attractive” penguins or something related in that way. To help generate some interest in helping me with my sexy penguins search, I might offer a bit of a reward, say $50 to the winner.

To help you in your search, I’m planning on using this theme. There could be slight adjustments, but the image should be in several desirable formats, including banner, screensaver, and a any others that might seem useful. The main reason I am doing this is to motivate myself into blogging more, both for your benefit, but also for mine.

Fedora-Tutorials needs a face lift, help the Sexy Sexy Penguin(s) come to life! Thank you all for enjoying my posts, I plan on providing much more in the near future.

Cheers,

Herlo

Gnome’s Online Desktop - Fedora 8

One of the coolest new things coming out for Fedora 8, the Gnome Online Desktop! Its an amazing device, provides a simple interface for working with the new web world in which we live.

It reminds me a bit of spotlight for Mac, but this thing has much more. With all of the web integration it has, including google docs, calendar, last.fm, digg and more, you can’t pass up the opportunity to try out this amazing desktop.

I’ve attached an ogg/vorbis screencast of some of my interaction with it in Fedora 8 Test 3. Although it claims to be just a demo, it sure looks good!

onlinedesktop-screencast - 23MB (could take a while)

Cheers,

Herlo

SCTP - a new replacement for TCP (or UDP)

Recently, I’ve been quite overwhelmed with keeping up with my latest ambition, the Utah Open Source Foundation, which has made it a bit difficult to keep up on my blog here. I’ll be doing some updates to this blog soon and you should start seeing regular updates from me here in the very near future.

In the meantime, I’ve got a post that may knock your sock off! If you’ve not yet heard about it, there’s a new transport protocol on the way, and its called Stream Control Transmission Protocol (SCTP). Its an amazing new way of looking at the network, providing multi-stream transmissions through one port.

Have you ever thought it would be nice to take three network connections, one ethernet, one fiber and one wireless and bond them?  What about using those three connections to stream video?  Or to manage data on one and have a control connection on another?  TCP/UDP can’t really do this for you without some external elements, but SCTP might just be the thing you’re looking for, and its already here.  Currently in testing, SCTP looks to be a great replacement (augmentation) to the already popular TCP and UDP prototols.

Linux Journal is doing a 3 part series on this protocol which started in last months article: Introduction to Stream Control Transmission Protocol.  This article is a quick look into how this protocol works.  The follow-up, in this month’s issue (not yet available for non-subscribers) talks about how the protocol is implemented in the Linux kernel and even gives some good code references.

I suggest you take a look at SCTP if you’ve not yet heard of it.  I am very excited to see where this protocol could take us in the future.

« Previous PageNext Page »