Tuesday, November 18, 2008

A fix for: alsamixer: function snd_ctl_open failed for default: No such device

I recently setup Ubuntu Server 8.10 with RAID and LVM which I plan to use as a file server among other things. 

I also wanted to be able to play audio with the machine since my decent speakers are still attached to this machine. 

So, I installed alsa and pulse audio. You can find that advice on many websites.  Ubuntu has quite a bit of good documentation. That wasn't the tough part.

When I tried to invoke alsamixer this is what I would get:

alsamixer: function snd_ctl_open failed for default: No such device

There are lots of posts about this issue but I didn't find any answers.

Luckily I used to use Slackware; if you don't know Slackware is mainly configured via command line only so I had setup alsa by hand before, albeit quite a while ago. And I recalled that /dev/dsp is going to be owned by root by default. On Ubuntu /dev/dsp is owned by root:audio.

Which means if you aren't root, or in the audio group, the system won't be able to see /dev/dsp.

So, I added my user to the audio group and everything worked after that.

Hope this helps someone.

Cheers,
Yoyar.

Addendum: If you alter the groups you are in, which you have to do as root, you then want to logout from your regular user (i.e. yoyar) and then log back in. This will allow the system to see that you are in the new group (i.e. audio). Otherwise, the system will still behave as if you are not in the audio group.  Just logout and log back in and it'll work.

Wednesday, May 2, 2007

09-f9-11-02-9d-74-e3-5b-d8-41-56-c5-63-56-88-c0

Friday, April 6, 2007

How to download streams using mplayer

My first assumption is that you already have mplayer and mencoder and that you use Linux. Also, you need to know the source url of the media you want to download.

If you don't know about Linux, try searching for Ubuntu Linux and go from there.

This is a simple tip so it won't take long.

The command is as follows:

yoyar@lazyd0g:~$ mplayer -noframedrop \
> -dumpfile <name_of_the_file> \
> -dumpstream <url_of_the_stream>


Example:

yoyar@lazyd0g:~$ mplayer -noframedrop \
> -dumpfile /home/yoyar/Desktop/masters2.wmv \
> -dumpstream mms://some.broadcast.com

In this example, I'm downloading the mms (Windows Media) stream which I've specified via the -dumpstream switch. I've indicated where I want the output stored via the -dumpfile switch. The -noframedrop switch makes sure that the stream is continuous even if my internet connection is slow from time to time during the duration of the stream.

Later on, I can use mplayer to watch the video.

yoyar@lazyd0g:~$ mplayer /home/yoyar/Desktop/masters2.wmv

If you want, you can even start watching the stream via the wmv file before the stream has been completely downloaded but you should probably allow the download to proceed for several minutes before starting to watch the local copy since buffering won't work well. If you want buffered input, just watch the original stream.

Tuesday, February 27, 2007

Science Vs. Faith Flow Chart

Mungo sent this to me:

http://stupidevilbastard.com/Images2/sciencevsfaith.png

The flow chart is a simple and compelling way to show that the two modes of thought do not mix or intersect.

So, next time someone tries to sell you on the idea that 'Intelligent Design' is good science you can just refer them to this picture.

It's also a good way to illustrate the scientific method.

If they can't figure it out then you can just give up. They're not that smart and you are just wasting your time.

Saturday, February 24, 2007

Dell Supports Linux on the Desktop Big-Time

I've been using Linux (Slackware) as my primary OS at home for quite some time now. I'm a hacker so I like Slackware because I can configure it exactly the way I want.

If you aren't a hacker but want to try Linux, just check out Ubuntu. You can try it simply by burning the ISO image to a CD, configuring your computer to boot from the CDROM drive, and then restarting the computer after inserting the CD. Ubuntu will load itself and run right from the CD. It will not touch your existing installation. After you reboot and remove the CD, Ubuntu Linux will be completely gone and your existing install will be exactly the same as it was before.

If you chose to install Ubuntu, you will have options. You can dual boot, or overwrite your existing OS. It's entirely up to you.

If you still think that Linux on the desktop is some distant far off in the future dream, consider that Dell is taking steps to make sure that it can satisfy the demand for non-Windows, Linux-workstation installs. This is despite the fact that Dell will almost certainly face a punitive response from Microsoft that could impact Dell's bottom line. Nonetheless, Dell is looking to the future.

Think about it, in the time it takes you to download a CD ISO image, burn it, and reboot the computer, you could be trying out a free (as in beer) operating system that could change the way you use computers. Well, maybe that is a bit dramatic, but at the worst, at least you would have had an interesting experience in a few short minutes.

Dell acknowledges the strength of demand for Linux workstations.

Still don't think its time to give Linux a try on the desktop? That's OK, you will.

Ubuntu Download Page 

Sunday, February 18, 2007

Microsoft's CEO

Well, just watch this post if you'd like to know more about Microsoft's CEO.

http://www.youtube.com/watch?v=IqUcTvfWgoM

Saturday, February 17, 2007

Arizona Pictures


I opened up a Flickr account. I've posted a number of pictures there. My trip to Arizona was awesome and relaxing. My Dad really liked it too. He needed a vacation.

http://www.flickr.com/photos/lazyd0g/