Sunday 20 January 2008

Lost Sound when Plugging in USB flash

I was playing an .avi in kaffeine, and at the same time I plugged in a 512MB USB flash drive. Immediately I lost sound in Kaffeine, though video was still playing. I check Youtube via Firefox, same thing.

I used to have a problem in Amarok where if Amarok crashed, it would mute the sound without my noticing. Thankfully I remembered to check this in Kaffeine, but that was not the problem.

I don't mess with the sound settings often, so I had a fun time trying to find them (turns out they're not in your system or settings menu... try looking for KMix in the Multimedia menu instead.)

I log on to the freenode IRC channel #kubuntu, and a couple nice folks there had some suggestions for me.

I was told to pay special attention to KMix lines: master, master mono, PCM. These were all fine (at or near the top).

(You can also open alsamixer via the command line)
alsamixer
I was then advised to restart ALSA.
sudo /etc/init.d/alsa-utils restart
This did not work. I tried closing all my programs which might be using sound, and running the command again. This did not work either.

I ran the command, and then rebooted. This works! Now I have my sound back.

Tuesday 15 January 2008

Mounting ntfs Drives in Kubuntu

Find the device and its partition in a terminal window:
sudo fdisk -l
Bootable devices will be marked. The actual drive used to boot will have partitions split up into swap space. IDE devices often (but not always) start with 'h', SATA devices and USB flash drives start with 's'. fdisk will indicate which file format the drive is formatted in. Hard drive letters indicate a specific device (i.e. a hard drive), numbers represent different partitions used in that device. Subsequent letters indicate addtional devices, and will likely be added incrementally (for example, if you have a SATA hard drive mounted first and then attach a USB flash drive, the hard drive should be sda, and the flash drive should end up being sdb.)

Numbers indicate a partition of that particular mounted device. Linux will reserve room for swap space and a boot sector in addition to the filesystem where you will store your files.

Mount the device to a destination folder. Replace 'hda1' below with the drive you wish to mount, and change the '/home/...' directory to where you want to mount the files to (the directory in this case will act like a link or bookmark). The folder in the home user's directory will be "ubuntu" (not your computer name) if it's running off a live cd.
sudo mount /dev/hda1 /home/ubuntu/Desktop/folder -t ntfs
-o nls=utf8,umask=0222
This is for mounting ntfs drives only!

(I've found other commands to "mount an ntfs drive", but they don't seem to work.)