WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: alsa sound not loading properly  (Read 26867 times)

Offline LinuxUser01

  • Full Member
  • ***
  • Posts: 111
Re: alsa sound not loading properly
« Reply #15 on: September 21, 2013, 11:51:11 PM »
Okay, so i deleted that file audio that i created and edited in /.X.d since Juanito stated it was for running x. I then added that command you mentioned sleep 1 & infront of the alsasound start in bootlocal.sh. I then went ahead and sudo alsaconfig and went through the installation process and it loaded the drivers. I then went into my .filetool.1st and made sure etc/modprobe.conf was still there and saved and rebooted. This time the sound works coming back from that reboot. I think we needed that sleep command in the bootlocal.sh that you mentioned in your post since it was stated in the comment section of alsa.tcz. I'll keep you posted. Thank you again.

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: alsa sound not loading properly
« Reply #16 on: September 21, 2013, 11:56:16 PM »
Wohoo! (:
« Last Edit: September 22, 2013, 12:54:06 AM by Misalf »
Download a copy and keep it handy: Core book ;)

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11618
Re: alsa sound not loading properly
« Reply #17 on: September 22, 2013, 12:03:53 AM »
Hi LinuxUser01
Quote
sleep 1 &
I don't think you want that  &  in there since that puts the sleep command in the background to run asynchronously. You
want it in the foreground so it blocks the next command from executing until  it completes.

Offline LinuxUser01

  • Full Member
  • ***
  • Posts: 111
Re: alsa sound not loading properly
« Reply #18 on: September 22, 2013, 12:52:24 AM »
I shut down the system then re-started it to no sound. I then changed that command sleep 1 & to sleep 1 in bootlocal.sh then rebooted and still no sound available. Not sure why its not saving any of this properly because after finding out that there is no sound, i open terminal and type sudo alsaconf and the sound is available.



Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11618
Re: alsa sound not loading properly
« Reply #19 on: September 22, 2013, 01:27:58 AM »
Hi LinuxUser01
Try removing the  &  from your alsa start and restore commands.

Offline LinuxUser01

  • Full Member
  • ***
  • Posts: 111
Re: alsa sound not loading properly
« Reply #20 on: September 22, 2013, 01:41:44 AM »
This is what i have so far in my bootlocal.sh:

#!/bin/sh
/usr/local/etc/init.d/alsasound start sleep 1
/usr/local/sbin/alsactl restore


I've looked over the comment section in alsa.tcz and i can't understand why this is still not working.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11618
Re: alsa sound not loading properly
« Reply #21 on: September 22, 2013, 02:21:51 AM »
Hi LinuxUser01
The  sleep 1  should be on a separate line.

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: alsa sound not loading properly
« Reply #22 on: September 22, 2013, 02:25:46 AM »
Sorry it wasn't clear to me that & puts a command into background. I've seen it many times as an example to delay the start of conky.
Maybe you could just do
Code: [Select]
#!/bin/sh
/bin/sleep 1
/usr/local/etc/init.d/alsasound start
/usr/local/sbin/alsactl restore
or
/bin/sleep 1 && /usr/local/etc/init.d/alsasound start
or
/bin/sleep 1 ; /usr/local/etc/init.d/alsasound start

Rich, please confirm.
Download a copy and keep it handy: Core book ;)

Offline LinuxUser01

  • Full Member
  • ***
  • Posts: 111
Re: alsa sound not loading properly
« Reply #23 on: September 22, 2013, 02:45:43 AM »
I got the bootlocal.sh revised again to:

#!/bin/sh
/usr/local/etc/init.d/alsasound start
/bin/sleep 1
/usr/local/sbin/alsactl restore


and so far the sound has worked both reboots. Not sure about the third one.

Offline LinuxUser01

  • Full Member
  • ***
  • Posts: 111
Re: alsa sound not loading properly
« Reply #24 on: September 22, 2013, 02:48:20 AM »
Damn!

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: alsa sound not loading properly
« Reply #25 on: September 22, 2013, 03:13:48 AM »
Put it above alsasound start.
If this still wont work, increase the number.

Be aware that sleep 2 would make the bootlocal.sh to stay inactive for 2 (two) seconds so you probably might not want to use very high value.
Download a copy and keep it handy: Core book ;)

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11618
Re: alsa sound not loading properly
« Reply #26 on: September 22, 2013, 10:02:52 AM »
Hi Misalf
Quote
Rich, please confirm.
Yes, those look fine.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11618
Re: alsa sound not loading properly
« Reply #27 on: September 22, 2013, 10:07:14 AM »
Hi LinuxUser01
You might want to try adding the  syslog  boot code. When alsa fails, look through  /var/log/messages  for messages
related to the sound system.

Offline LinuxUser01

  • Full Member
  • ***
  • Posts: 111
Re: alsa sound not loading properly
« Reply #28 on: September 22, 2013, 10:09:22 PM »
Okay, i'll look for any messages related to alsa when it fails in /var/log/messages and keep you updated. So for the bootlocal.sh either one would work?

#!/bin/sh
/bin/sleep 1 && /usr/local/etc/init.d/alsasound start
/usr/local/sbin/alsactl restore


or

#!/bin/sh
/bin/sleep 1 ; /usr/local/etc/init.d/alsasound start
/usr/local/sbin/alsactl restore


or

#!/bin/sh
/bin/sleep 1
/usr/local/etc/init.d/alsasound start
/usr/local/sbin/alsactl restore


And i'm not sure what you mean by adding the syslog boot code.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11618
Re: alsa sound not loading properly
« Reply #29 on: September 22, 2013, 11:21:38 PM »
Hi LinuxUser01
All three would work. My preference is one command per line.
Quote
And i'm not sure what you mean by adding the syslog boot code.
You've seen boot codes before, like waitusb=5 home=sda1 nodhcp norestore etc. In this case add  syslog  to your
bootloader.