Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Multimedia
  • Search

Alsa reset on reboot in 2.6

Help with creation, editing, or playback of sounds, images, or video. Amarok, audacious, mplayer, grip, cdparanoia and anything else that makes a sound or plays a video.
Post Reply
Advanced search
21 posts • Page 1 of 1
Author
Message
phunni
Apprentice
Apprentice
User avatar
Posts: 214
Joined: Mon May 05, 2003 9:55 pm
Location: Bristol, UK

Alsa reset on reboot in 2.6

  • Quote

Post by phunni » Tue Feb 03, 2004 11:58 am

I have seen this mentioned several times, but not found an answer - if I've missed something, I apologise - please direct me to the appropriate thread

Whenever I reboot, I lose my alsa settings. I used to have alsasound enabled for when I was running a 2.4 kernel, but with 2.6 I would just get errors as the modules were loaded twice.

I have not at any point specified that I want the alsa modues loaded (although I do) so I can't simply remove that from some config file.

How can I get my sound settings persist beyond a reboot in an automatic way? (i.e. not manually saving and restoring the settings)
Old School is the way forward!
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

Re: Alsa reset on reboot in 2.6

  • Quote

Post by agent_jdh » Tue Feb 03, 2004 12:03 pm

phunni wrote:I have seen this mentioned several times, but not found an answer - if I've missed something, I apologise - please direct me to the appropriate thread

Whenever I reboot, I lose my alsa settings. I used to have alsasound enabled for when I was running a 2.4 kernel, but with 2.6 I would just get errors as the modules were loaded twice.

I have not at any point specified that I want the alsa modues loaded (although I do) so I can't simply remove that from some config file.

How can I get my sound settings persist beyond a reboot in an automatic way? (i.e. not manually saving and restoring the settings)
The alsasound script included with recent alsa-utils packages has been fixed so as not to give the error messages w/ 2.6 kernels.

Remember, those errors were not actually a problem anyway, it was just the script trying ot load modules that had already been loaded.

BTW do you compile ALSA stuff as modules or into the kernel?
Jingle Jangle Jewellery
Top
phunni
Apprentice
Apprentice
User avatar
Posts: 214
Joined: Mon May 05, 2003 9:55 pm
Location: Bristol, UK

  • Quote

Post by phunni » Tue Feb 03, 2004 1:38 pm

I did it as modules.

Which package must I re-emerge to get the updated script?
Old School is the way forward!
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Tue Feb 03, 2004 2:00 pm

phunni wrote:I did it as modules.

Which package must I re-emerge to get the updated script?
alsa-utils, although it's only in the more recent versions you get the updated script. What version do you get when you do an emerge -p alsa-utils?

Latest is v1.0.2

You'll probably want to use this in conjunction with mm-sources (or poss gentoo-dev-sources, I use mm-sources), as they come with newer ALSA drivers in the kernel than the stock kernel (development-sources).

You might need to pass the ~x86 option to get the latest stuff.
Jingle Jangle Jewellery
Top
phunni
Apprentice
Apprentice
User avatar
Posts: 214
Joined: Mon May 05, 2003 9:55 pm
Location: Bristol, UK

  • Quote

Post by phunni » Tue Feb 03, 2004 2:54 pm

Using the dev-sources, not sure which versions of the modules they provide.

Currently emerging alsa-utils 1.0.2 now

Thanks for the help
Old School is the way forward!
Top
mvr_rennes
Apprentice
Apprentice
User avatar
Posts: 155
Joined: Wed Oct 23, 2002 11:04 pm

  • Quote

Post by mvr_rennes » Tue Feb 03, 2004 5:13 pm

Hi,
try erasing your /etc/asound.state, adjusting your controls and doing an

Code: Select all

#alsactl store 
afterwards
Cheers,
M
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Tue Feb 03, 2004 5:30 pm

mvr_rennes wrote:Hi,
try erasing your /etc/asound.state, adjusting your controls and doing an

Code: Select all

#alsactl store 
afterwards
Cheers,
M
He'll want to run alsamixer first to unmute the relevant outputs and set levels.

You need to run both these as root btw.
Jingle Jangle Jewellery
Top
phunni
Apprentice
Apprentice
User avatar
Posts: 214
Joined: Mon May 05, 2003 9:55 pm
Location: Bristol, UK

  • Quote

Post by phunni » Tue Feb 03, 2004 5:37 pm

mvr_rennes wrote:Hi,
try erasing your /etc/asound.state, adjusting your controls and doing an

Code: Select all

#alsactl store 
afterwards
Cheers,
M
Does this not require manually running

Code: Select all

alsactl restore
? I was hoping to find an "automatic" solution
Old School is the way forward!
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Tue Feb 03, 2004 6:01 pm

phunni wrote:
mvr_rennes wrote:Hi,
try erasing your /etc/asound.state, adjusting your controls and doing an

Code: Select all

#alsactl store 
afterwards
Cheers,
M
Does this not require manually running

Code: Select all

alsactl restore
? I was hoping to find an "automatic" solution
You only need to do this once, after which the alsa init script will take care of it when you startup/shutdown.

Remember to

Code: Select all

rc-update add alsasound boot
Jingle Jangle Jewellery
Top
ett_gramse_nap
Apprentice
Apprentice
User avatar
Posts: 252
Joined: Wed Oct 01, 2003 6:54 am
Location: Göteborg, Sweden

  • Quote

Post by ett_gramse_nap » Tue Feb 03, 2004 6:25 pm

I'm so totally confused about these runlevels... why should I want to add alsa to runlevel 'boot' and not to 'default'? (Besides that the gentoo doc wants me to add it to 'boot', obviously... :P )
Don't bother!
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Tue Feb 03, 2004 7:40 pm

ett_gramse_nap wrote:I'm so totally confused about these runlevels... why should I want to add alsa to runlevel 'boot' and not to 'default'? (Besides that the gentoo doc wants me to add it to 'boot', obviously... :P )
You've answered your own question there. The reason you have to put it in 'boot' and not 'default' is because the Gentoo docs tell you to do that. It won't work properly if you don't.

My personal take on it is this - you can probably add it to the default runlevel, but there might be other init stuff there that requires alsa to have been started before it, which you can only guarantee to have happened by putting the alsa init script in the boot runlevel.

A quick check on the Gentoo homepage shows the Doc stuff there about Gentoo's runlevels-

http://www.gentoo.org/doc/en/rc-scripts.xml
Jingle Jangle Jewellery
Top
phunni
Apprentice
Apprentice
User avatar
Posts: 214
Joined: Mon May 05, 2003 9:55 pm
Location: Bristol, UK

  • Quote

Post by phunni » Tue Feb 03, 2004 9:23 pm

re-instating the alsasound script has returned me to the same modules errors (although my settings do now persist)

I realise these aren't a serious problem - but I would be happier without them

Using alsa-utils 1.0.2
Old School is the way forward!
Top
link97381
n00b
n00b
Posts: 34
Joined: Sat Mar 29, 2003 10:38 am
Location: Silverton Oregon

  • Quote

Post by link97381 » Tue Feb 03, 2004 11:15 pm

I just updated to kernel 2.6 with alsa compiled in and it works fine with out any run level scripts but I have to unmute it after every reboot.....is that what the run level scripts do? Because I get an error message with the script.
Top
GentooNub
n00b
n00b
Posts: 42
Joined: Sun Jan 25, 2004 9:47 pm

  • Quote

Post by GentooNub » Tue Feb 03, 2004 11:43 pm

link97381 wrote:I just updated to kernel 2.6 with alsa compiled in and it works fine with out any run level scripts but I have to unmute it after every reboot.....is that what the run level scripts do? Because I get an error message with the script.
I'm attempting to run 2.4.2 and 2.6.1 side by side. Having some problems with my video drivers and can't even get into x to test the sound in 2.6.1. Lately tho I've had the above happening in the 2.4.2 kernel. I have to reset the amixer levels on reboot among a few other things.I get error messages on boot that may be related. You can view those in this post. It's in the last paragraph on the second post.
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Wed Feb 04, 2004 1:04 am

link97381 wrote:I just updated to kernel 2.6 with alsa compiled in and it works fine with out any run level scripts but I have to unmute it after every reboot.....is that what the run level scripts do? Because I get an error message with the script.
Yes. If you don't use the script in boot runlevel, it won't save and restore your mixer settings, so that is why you have to unmute at each boot. Depending on the alsa version you have, the error messages can be ignored. If it loads/saves your mixer settings and your sound works, you can chalk it down in the 'minor irritant' category.

If you use the scripts, remember to run alsactl store after using alsamixer to set your levels etc.
Last edited by agent_jdh on Wed Feb 04, 2004 1:09 am, edited 1 time in total.
Jingle Jangle Jewellery
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Wed Feb 04, 2004 1:08 am

GentooNub wrote:
link97381 wrote:I just updated to kernel 2.6 with alsa compiled in and it works fine with out any run level scripts but I have to unmute it after every reboot.....is that what the run level scripts do? Because I get an error message with the script.
I'm attempting to run 2.4.2 and 2.6.1 side by side. Having some problems with my video drivers and can't even get into x to test the sound in 2.6.1. Lately tho I've had the above happening in the 2.4.2 kernel. I have to reset the amixer levels on reboot among a few other things.I get error messages on boot that may be related. You can view those in this post. It's in the last paragraph on the second post.
I've not looked at your other post, but running 2.4 and 2.6 kernels side-by-side is a major headache if you use ALSA and (I'm making an assumption here) the nvidia-kernel driver.

It'll melt yer heid trying to work out what's been installed where under what kernel and how it's supposed to work.
Jingle Jangle Jewellery
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Wed Feb 04, 2004 1:11 am

phunni wrote:re-instating the alsasound script has returned me to the same modules errors (although my settings do now persist)

I realise these aren't a serious problem - but I would be happier without them

Using alsa-utils 1.0.2
What kernel are you using? Maybe one with downlevel drivers. I always try and make sure that the ALSA drivers in the kernel I'm using correspond w.r.t. version numbers as the alsa-lib and alsa-utils ebuilds I have installed. You can check the ALSA driver version by running cat /proc/asound/version

Or possibly there is still some cruft on your system which has caused the latest script not to get installed. Try rc-update'ing again (well, del alsasound first then add it again).
Jingle Jangle Jewellery
Top
GentooNub
n00b
n00b
Posts: 42
Joined: Sun Jan 25, 2004 9:47 pm

  • Quote

Post by GentooNub » Wed Feb 04, 2004 2:49 am

agent_jdh wrote:
GentooNub wrote:
link97381 wrote:I just updated to kernel 2.6 with alsa compiled in and it works fine with out any run level scripts but I have to unmute it after every reboot.....is that what the run level scripts do? Because I get an error message with the script.
I'm attempting to run 2.4.2 and 2.6.1 side by side. Having some problems with my video drivers and can't even get into x to test the sound in 2.6.1. Lately tho I've had the above happening in the 2.4.2 kernel. I have to reset the amixer levels on reboot among a few other things.I get error messages on boot that may be related. You can view those in this post. It's in the last paragraph on the second post.
I've not looked at your other post, but running 2.4 and 2.6 kernels side-by-side is a major headache if you use ALSA and (I'm making an assumption here) the nvidia-kernel driver.

It'll melt yer heid trying to work out what's been installed where under what kernel and how it's supposed to work.
No assumptions made you hit it all on the head. The only reason I'm running a 2.4 beside a 2.6 kernel is so I have a working system. Everything so far seams to be easily worked out with ALOT of research. But I can handle researching. Not finding answers is what drives me insane. Figuring out whats installed where hasn't been a problem since I learned how to properly symlink /usr/src/linux :) :). One thing that is still bugging me tho is I have the alsa drivers built into the 2.6 kernel because that seams to be a new feature both stated in the install page and just within the kernel config file. So I'm not quite sure why the alsa install is even buggin out on the 2.4 kernel. Makes no sense to me maybe someone can explain it? Because if it's built into the kernel doesn't it get everything it needs from the kernel therefore leaving the install in 2.4 that I'm using an a module, alone?
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Wed Feb 04, 2004 3:24 am

GentooNub wrote:
agent_jdh wrote:
GentooNub wrote:
link97381 wrote:I just updated to kernel 2.6 with alsa compiled in and it works fine with out any run level scripts but I have to unmute it after every reboot.....is that what the run level scripts do? Because I get an error message with the script.
I'm attempting to run 2.4.2 and 2.6.1 side by side. Having some problems with my video drivers and can't even get into x to test the sound in 2.6.1. Lately tho I've had the above happening in the 2.4.2 kernel. I have to reset the amixer levels on reboot among a few other things.I get error messages on boot that may be related. You can view those in this post. It's in the last paragraph on the second post.
I've not looked at your other post, but running 2.4 and 2.6 kernels side-by-side is a major headache if you use ALSA and (I'm making an assumption here) the nvidia-kernel driver.

It'll melt yer heid trying to work out what's been installed where under what kernel and how it's supposed to work.
No assumptions made you hit it all on the head. The only reason I'm running a 2.4 beside a 2.6 kernel is so I have a working system. Everything so far seams to be easily worked out with ALOT of research. But I can handle researching. Not finding answers is what drives me insane. Figuring out whats installed where hasn't been a problem since I learned how to properly symlink /usr/src/linux :) :). One thing that is still bugging me tho is I have the alsa drivers built into the 2.6 kernel because that seams to be a new feature both stated in the install page and just within the kernel config file. So I'm not quite sure why the alsa install is even buggin out on the 2.4 kernel. Makes no sense to me maybe someone can explain it? Because if it's built into the kernel doesn't it get everything it needs from the kernel therefore leaving the install in 2.4 that I'm using an a module, alone?
I think the simplest solution for you is to find a 2.6 kernel that just works, be it development-sources, gentoo-dev-sources, or mm-sources, and stick with it for a bit until things settle down. You could create symlinks in /boot for bzImage and edit your -bootloader of choice- to include entries for your 'latest kernel' and 'last known kernel where everything worked'. Compiling the 2.6 ALSA stuff as modules, and editing /etc/make.conf to leave the nvidia-kernel source unpacked then copying it to a different location and installing by hand has worked for me. The nvidia bit isn't straightforward though, you need to manually create a symlink Makefile pointing to Makefile.nvidia iirc.

Like I said, running multiple kernels leads to multiple confusion.
Jingle Jangle Jewellery
Top
agent_jdh
Veteran
Veteran
Posts: 1783
Joined: Thu Aug 08, 2002 8:23 am
Location: Scotland

  • Quote

Post by agent_jdh » Wed Feb 04, 2004 3:38 am

Through all of this, I've forgotten to mention the requirement of having a correct /etc/modules.d/alsa file and running update-modules after getting this file sorted out, then rebooting (or /etc/init.d/alsasound restart).

So if it doesn't work for you, check that file out. The ALSA homepage has driver-specific entries for that file that goes beyond the Gentoo install info (a combination of the two should result in ALSA working).

And, unless I forget, there's an /etc/make.conf entry for ALSA which may, or may not, be reduntant these days (ALSA_CARDS='whatever')
Jingle Jangle Jewellery
Top
GentooNub
n00b
n00b
Posts: 42
Joined: Sun Jan 25, 2004 9:47 pm

  • Quote

Post by GentooNub » Wed Feb 04, 2004 5:24 am

I've understood it all and I've done that. And I've done all of itl. My sound muting itself didn't start though until I recompiled my 2.6.1 with support for devfs and my nic support.Other than that I didn't change anything. I havn't tried installing alsa onto 2.6, because for one it's built in and seams to load. And 2 I had no reason to change anything on my 2.4 kernel. I didn't add a module loader to the 2.6.1 kernel, hence everything should have remained as is on it. Because the 2.6.1 kernel has had the alsa drivers built in since the first compile and I didn't have the problems of the mixers muting themselves which is why I'm confused. I know that running the two beside eachother is confusing and difficult but I've read at least 20 threads on it and other people seam to have gotten them working with my current setup.

If only my nvidia module would work I wouldn't have to boot back into 2.4 and this wouldn't even be a problem. I'm just keeping 2.4 around as a backup in case something I havn't tested goes wrong in 2.6 and if it doesn't after about a month I'll just remove the 2.4 kernel or back it up and save it. So this isn't really a huge problem whereas my nvidia drivers giving me a hassle is. :) But that is going to be another thread. Hehe. Thanks for your help agent_jdh. And the good advice.
Top
Post Reply

21 posts • Page 1 of 1

Return to “Multimedia”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic