Reputation: 366
Unable to use snd-aloop audio driver in AWS EC2 ubuntu 16.04 instance
On running modprobe on snd-aloop
$modprobe snd-aloop
modprobe: FATAL: Module snd-aloop not found in directory /lib/modules/4.4.0-1052-aws
Kernels in AWS matchine are -
/lib/modules/4.4.0-1049-aws
/lib/modules/4.4.0-1052-aws
/lib/modules/4.4.0-116-generic
Current kernel loaded
$uname -r
4.4.0-1052-aws
"/lib/modules/4.4.0-116-generic" kernel. location - /lib/modules/4.4.0-116-generic/kernel/sound/drivers/snd-aloop.ko
I have already gone through the following doc's
1.https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedKernels.html - Aws doc guide to change kernels.
I can't recall the other links but i have searched a lot.
Please point me in the right direction. How can i use audio driver sdn-aloop in AWS EC2 Ubuntu 16.04 instance?
Upvotes: 6
Views: 11004
Reputation: 16054
EC2 AMIs use aws ubuntu kernel modules instead of the ubuntu generic modules, which omits alsa sound drivers
snd-dummy and other alsa drivers were added to the linux-modules-extras
for Ubuntu Jammy (22.04).
So you will need to use a base ami with this version of ubuntu or later.
To install the extra modules you can run this command:
apt install linux-modules-extra-`uname -r`
After that you can do modprob and modinfo on snd-dummy
Upvotes: 0
Reputation: 47
Jibri on AWS and getting the below issue.
org.jitsi.jibri.capture.ffmpeg.FfmpegCapturer.onFfmpegProcessUpdate() Ffmpeg quit abruptly. Last output line: plug:bsnoop: Input/output error
Solution: changing and updating the kernel boot settings from Linux 4.4.0-xxxx-aws to Linux 4.4.0-xxxx-generic and restarting the instance.
I have fixed by the following steps:
$ grep -A200 submenu /boot/grub/grub.cfg |grep menuentry
Output:
submenu 'Advanced options for Ubuntu' $menuentry_id_option 'gnulinux-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-1107-aws' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-1107-aws-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-1107-aws (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-1107-aws-recovery-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-1106-aws' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-1106-aws-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-1106-aws (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-1106-aws-recovery-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-1105-aws' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-1105-aws-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-1105-aws (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-1105-aws-recovery-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-179-generic' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-179-generic-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menuentry 'Ubuntu, with Linux 4.4.0-179-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.4.0-179-generic-recovery-e6dc6474-8016-46c6-8ab0-0a871bae4cd1' {
menu entry id for Advanced options for Ubuntu is gnulinux-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1 menu entry for Ubuntu, with Linux 4.4.0-179-generic is gnulinux-4.4.0-179-generic-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1
Edit Grub and replace GRUB_DEFAULT with above value
$ nano /etc/default/grub
GRUB_DEFAULT="gnulinux-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1>gnulinux-4.4.0-179-generic-advanced-e6dc6474-8016-46c6-8ab0-0a871bae4cd1"
GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=0
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="console=tty1 console=ttyS0"
GRUB_CMDLINE_LINUX=""
Update and Reboot
$ sudo update-grub $ sudo reboot
After reboot you can test it with uname -a which should give 4.4.0-179-generic
$ uname -a
Linux 4.4.0-179-generic
After this modprobe snd-aloop should work fine.
Upvotes: 5
Reputation: 471
How i did this was run
grep-A100 submenu /boot/grub/grub.cfg |grep menuentry
This lists something like
submenu 'Advanced options for Ubuntu' $menuentry_id_option 'gnulinux-advanced-6156ec80-9446-4eb1-95e0-9ae6b7a46187' {
menuentry 'Ubuntu, with Linux 5.3.0-1017-aws' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.3.0-1017-aws-advanced-6156ec80-9446-4eb1-95e0-9ae6b7a46187' {
menuentry 'Ubuntu, with Linux 5.3.0-1017-aws (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.3.0-1017-aws-recovery-6156ec80-9446-4eb1-95e0-9ae6b7a46187' {
menuentry 'Ubuntu, with Linux 4.15.0-1065-aws' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.15.0-1065-aws-advanced-6156ec80-9446-4eb1-95e0-9ae6b7a46187' {
menuentry 'Ubuntu, with Linux 4.15.0-1065-aws (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.15.0-1065-aws-recovery-6156ec80-9446-4eb1-95e0-9ae6b7a46187' {
menuentry 'Ubuntu, with Linux 4.15.0-99-generic' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.15.0-99-generic-advanced-6156ec80-9446-4eb1-95e0-9ae6b7a46187' {
menuentry 'Ubuntu, with Linux 4.15.0-99-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.15.0-99-generic-recovery-6156ec80-9446-4eb1-95e0-9ae6b7a46187' {
So chose the first menuentryid i.e. gnulinux-advanced-6156ec80-9446-4eb1-95e0-9ae6b7a46187 and the generic id gnulinux-4.15.0-99-generic-advanced-6156ec80-9446-4eb1-95e0-9ae6b7a46187
THen join them with > which will look like this
gnulinux-4.15.0-99-generic-recovery-6156ec80-9446-4eb1-95e0-9ae6b7a46187>gnulinux-4.15.0-99-generic-advanced-6156ec80-9446-4eb1-95e0-9ae6b7a46187
and set this as GRUB_DEFAULT value as above then update-grub and reboot. You should get the desired output.
Upvotes: 0
Reputation: 166
Steps to update default kernel boot item (without modification of /boot/grub/menu.lst):
Find needed menu and sub-menu item in grub.cfg:
cat /boot/grub/grub.cfg
For example you can have menu structure like this (default for AWS Ubuntu 16.04):
In this case if you need to load "Ubuntu, with Linux 4.4.0-116-generic" your default boot setting would be "1>2"
Edit default grub file:
vim /etc/default/grub
and set
GRUB_DEFAULT=“1>2”
Run update-grub
reboot now
to take this in effectuname -a
which should give 4.4.0-116-genericAfter this modprobe snd-aloop
should work fine.
Upvotes: 15