Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a debian system that I use, amongst other things, as a fileserver and for playing music. My problem is that as soon as the harddisk gets used slightly more intensely -- i.e. Copying a biggish file across the network or from one partition to another -- music playback starts skipping. It's not really bad, but still bad enough to drive me up the wall.
Here's my system:
- I use xmms to play music. It also skips if I play internet radio. I have the sound set to realtime priority in KDE.
- I use arts.
-My system is fast 1.8 GHZ + with 500 MB RAM
- Kernel is 2.4.25
Probably the cache in your hdd is not big enough, a drive with 8mb cache would probably solve your problem. And if that's what you have... then well I don't know.
Originally posted by caspar_wrede I have a debian system that I use, amongst other things, as a fileserver and for playing music. My problem is that as soon as the harddisk gets used slightly more intensely -- i.e. Copying a biggish file across the network or from one partition to another -- music playback starts skipping. It's not really bad, but still bad enough to drive me up the wall.
Here's my system:
- I use xmms to play music. It also skips if I play internet radio. I have the sound set to realtime priority in KDE.
- I use arts.
-My system is fast 1.8 GHZ + with 500 MB RAM
- Kernel is 2.4.25
Hmm, can't think of any more useful information.
Any ideas?
Almost sounds like DMA is not enabled on the the drive. Install hdparm and use something like this to check the settings.
And something like this to see the modes supported and set.
Code:
[HappyTux:/home/stephen]# hdparm -i /dev/hda
/dev/hda:
Model=WDC WD1200JB-00EVA0, FwRev=15.05R15, SerialNo=WD-WMAEK2297036
Config={ HardSect NotMFM HdSw>15uSec SpinMotCtl Fixed DTR>5Mbs FmtGapReq }
RawCHS=16383/16/63, TrkSize=57600, SectSize=600, ECCbytes=74
BuffType=DualPortCache, BuffSize=8192kB, MaxMultSect=16, MultSect=16
CurCHS=4047/16/255, CurSects=16511760, LBA=yes, LBAsects=234441648
IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
PIO modes: pio0 pio1 pio2 pio3 pio4
DMA modes: mdma0 mdma1 mdma2
UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5
AdvancedPM=no WriteCache=enabled
Drive conforms to: device does not report version:
* signifies the current active mode
Now if DMA is not set and is supported then you would need to edit the file /etc/hdparm.conf and put a section in there for your drive and it will be set every time you boot, you can use hdparm -d1 /dev/hda to set it immediately then let the config file take care of it on next boot. The comments are fairly good in the file so you should be able to figure out what you need. Oh and if you want to test the speed of the drive then.
Code:
[HappyTux:/home/stephen]# hdparm -Tt /dev/hda
/dev/hda:
Timing buffer-cache reads: 804 MB in 2.00 seconds = 401.26 MB/sec
Timing buffered disk reads: 132 MB in 3.04 seconds = 43.40 MB/sec
The smaller number is the really important one for everyday use. All this as root of course.
So far so good. Doing the second command suggested by Mr. HappyTux gives me this:
Code:
root@kronos public# hdparm -i /dev/hda
/dev/hda:
Model=WDC WD2500JB-00EVA0, FwRev=15.05R15, SerialNo=WD-WMAEH2433533
Config={ HardSect NotMFM HdSw>15uSec SpinMotCtl Fixed DTR>5Mbs FmtGapReq }
RawCHS=16383/16/63, TrkSize=57600, SectSize=600, ECCbytes=74
BuffType=DualPortCache, BuffSize=8192kB, MaxMultSect=16, MultSect=16
CurCHS=4047/16/255, CurSects=16511760, LBA=yes, LBAsects=268435455
IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
PIO modes: pio0 pio1 pio2 pio3 pio4
DMA modes: mdma0 mdma1 mdma2
UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5
AdvancedPM=no WriteCache=enabled
Drive conforms to: device does not report version:
* signifies the current active mode
I have next to no idea what all this means. Anyway, heading on I ran into a problem:
Code:
root@kronos public# hdparm -d1 /dev/hda
/dev/hda:
setting using_dma to 1 (on)
HDIO_SET_DMA failed: Operation not permitted
using_dma = 0 (off)
Operation not permitted? I have no idea if my drive has DMA support. It has 250 GB and was purchased less than a year ago. Is it a standard feature by now?
And here are my statistics. They seem low -- well, the second reading anyway:
Code:
root@kronos public# hdparm -Tt /dev/hda
/dev/hda:
Timing buffer-cache reads: 932 MB in 2.00 seconds = 466.00 MB/sec
Timing buffered disk reads: 20 MB in 3.31 seconds = 6.04 MB/sec
Thanks for your help. Your personally preferred Prime Mover is smiling upon you.
Originally posted by caspar_wrede Thanks people for your help.
It seems my DMA is not enabled:
I have next to no idea what all this means. Anyway, heading on I ran into a problem:
Code:
root@kronos public# hdparm -d1 /dev/hda
/dev/hda:
setting using_dma to 1 (on)
HDIO_SET_DMA failed: Operation not permitted
using_dma = 0 (off)
Operation not permitted? I have no idea if my drive has DMA support. It has 250 GB and was purchased less than a year ago. Is it a standard feature by now?
The drive definitely supports DMA it is from the same series as mine only twice as large and from the looks of that output it looks like the chipset for the motherboard or dma is not enabled or compiled as modules.
Quote:
And here are my statistics. They seem low -- well, the second reading anyway:
Code:
root@kronos public# hdparm -Tt /dev/hda
/dev/hda:
Timing buffer-cache reads: 932 MB in 2.00 seconds = 466.00 MB/sec
Timing buffered disk reads: 20 MB in 3.31 seconds = 6.04 MB/sec
Thanks for your help. Your personally preferred Prime Mover is smiling upon you.
Caspar
Way too low it should be pretty much the same range as mine try this with the config file for your kernel and see if you have similar output.
Code:
>$ grep -i dma /boot/config-2.6.8.1-ck6
CONFIG_GENERIC_ISA_DMA=y
CONFIG_BLK_DEV_IDEDMA_PCI=y
# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
CONFIG_IDEDMA_PCI_AUTO=y
# CONFIG_IDEDMA_ONLYDISK is not set
CONFIG_BLK_DEV_ADMA=y
CONFIG_BLK_DEV_IDEDMA=y
# CONFIG_IDEDMA_IVB is not set
CONFIG_IDEDMA_AUTO=y
# CONFIG_SOUND_DMAP is not set
And if you know what motherboard chipset you have do the same for instance mine is a via based board so I have this set.
Code:
>$ grep -i via /boot/config-2.6.8.1-ck6
# CONFIG_MVIAC3_2 is not set
CONFIG_BLK_DEV_VIA82CXXX=y <----- motherboard chipset
CONFIG_VIA_RHINE=m
# CONFIG_VIA_RHINE_MMIO is not set
# CONFIG_VIA_VELOCITY is not set
CONFIG_AGP_VIA=m
# CONFIG_I2C_VIA is not set
CONFIG_I2C_VIAPRO=m
CONFIG_SENSORS_VIA686A=m
CONFIG_SND_VIA82XX=m
CONFIG_SOUND_VIA82CXXX=m
CONFIG_MIDI_VIA82CXXX=y
Now I look again I see you refer to your processor as a 1.8 so you probably have intel so use grep PIIX /boot/config-2.?.?? replace the ?'s with the output you see from uname -r when doing the above commands for the 2.6.8.1-ck6 I have as well.
Here is the result of grepping for DMA in the config file
Code:
root@kronos bootd# uname -r
2.4.25
root@kronos boot# grep -i dma config-2.4.25
CONFIG_BLK_DEV_IDEDMA_PCI=y
# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
CONFIG_IDEDMA_PCI_AUTO=y
# CONFIG_IDEDMA_ONLYDISK is not set
CONFIG_BLK_DEV_IDEDMA=y
# CONFIG_IDEDMA_PCI_WIP is not set
# CONFIG_BLK_DEV_ADMA100 is not set
# CONFIG_HPT34X_AUTODMA is not set
CONFIG_IDEDMA_AUTO=y
# CONFIG_IDEDMA_IVB is not set
# CONFIG_DMA_NONPCI is not set
# CONFIG_SCSI_EATA_DMA is not set
There seem to be several things that are not set that are set for you. I have never gone this far below the surface before. Does changing the config file require a kernel recompilation or will a reboot do?
As for my motherboard, I have an ASRock K7S8X. In the manual it mentions a "Northbridge K7S8X chipset". I also have an Athlon processor. I dont know what to grep for in the config file.
Here is the result of grepping for DMA in the config file
Code:
root@kronos bootd# uname -r
2.4.25
root@kronos boot# grep -i dma config-2.4.25
CONFIG_BLK_DEV_IDEDMA_PCI=y
# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
CONFIG_IDEDMA_PCI_AUTO=y
# CONFIG_IDEDMA_ONLYDISK is not set
CONFIG_BLK_DEV_IDEDMA=y
# CONFIG_IDEDMA_PCI_WIP is not set
# CONFIG_BLK_DEV_ADMA100 is not set
# CONFIG_HPT34X_AUTODMA is not set
CONFIG_IDEDMA_AUTO=y
# CONFIG_IDEDMA_IVB is not set
# CONFIG_DMA_NONPCI is not set
# CONFIG_SCSI_EATA_DMA is not set
There seem to be several things that are not set that are set for you. I have never gone this far below the surface before. Does changing the config file require a kernel recompilation or will a reboot do?
Changing the config requires you to compile a new kernel and the DMA I have set are just all the ones I thought I would need when I compiled my first 2.6 kernel reading the help files.
Quote:
As for my motherboard, I have an ASRock K7S8X. In the manual it mentions a "Northbridge K7S8X chipset". I also have an Athlon processor. I dont know what to grep for in the config file.
Greetings from Berlin,
Caspar.
Alright so you have an Athlon XP then and according to this page I found with a quick google search on your motherboard's name it says you have a SIS 746FX chipset which a grep of my config leads to this from the help for the CONFIG_BLK_DEV_SIS5513 it only lists as you can see a 745 and then 750 for the next highest supported chipset.
Code:
CONFIG_BLK_DEV_SIS5513:
This driver ensures (U)DMA support for SIS5513 chipset family based
mainboards.
The following chipsets are supported:
ATA16: SiS5511, SiS5513
ATA33: SiS5591, SiS5597, SiS5598, SiS5600
ATA66: SiS530, SiS540, SiS620, SiS630, SiS640
ATA100: SiS635, SiS645, SiS650, SiS730, SiS735, SiS740, SiS745, SiS750
You may want to try using modconf and going to the section block devices then selecting the SiS5513 to have the driver loaded on boot that is if you compiled it when you did your kernel. I say this because that kernel name (2.4.25 should be 2.4.25-?-??) is definitely not a Debian one you got from the archives. The module does exist in a 2.4 series kernel you would want to compile it in instead of as a module.
If you're still having a problem, post the output of 'lspci -v' or, if not available, 'cat /proc/pci'. This should eliminate the need for any guesswork. There're a few SiS chipsets that linux does not like.
Oops, I've made my computer unbootable. I tried getting the latest 2.4 kernel source from Debian and after compiling and installing it my computer refused to come back to life. My lilo is not set up to give me a choice of kernels, rather stupidly.
Anyway, now I have to sort out this mess first. I am in the process of downloading a live CD image, then I will get back to the original problem.
First I rescued my system. Then I had a hard look at the whole kernel compilation thingamabob, and then after several false starts it worked. DMA is now switched on and I now have much better hdparm test values:
Code:
root@kronos wrede# hdparm -Tt /dev/hda
/dev/hda:
Timing cached reads: 1104 MB in 2.00 seconds = 552.00 MB/sec
Timing buffered disk reads: 114 MB in 3.00 seconds = 38.00 MB/sec
Now I can transfer large files to the hardisk of my file server and the music indeed no longer skips. I am amazed.
I am also amazed by this whole linux forum issue. I get individually tailored advice from experts for free. What I'm trying to say is thank you. I promise to do my part when my time comes.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.