[Webinar] Streamline your web hosting managementRegister Today

x
?
Solved

want to hear youtube freeBSD

Posted on 2008-01-25
29
Medium Priority
?
2,006 Views
Last Modified: 2013-11-22
my youtube is now working visually, but there is no sound.

kv_bsd# uname -a
FreeBSD kv_bsd 6.2-RELEASE FreeBSD 6.2-RELEASE #0: Fri Jan 12 10:40:27 UTC 2007     root@dessler.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386
kv_bsd#

i followed these instructions:

install www/firefox      
install print/acroread7      
install java/diablo-jdk15
install www/linux-flashplugin7      
kldload linux
echo "none            /compat/linux/proc      linprocfs       rw      0      
0" >> /etc/fstab
mount -a
echo "linux_enable=\"YES\"" >> /etc/rc.conf                      
nspluginwrapper -v -a -i


now i found a webpage:

http://www.erata.net/weblog/freebsd/2006/10/16/flash-plugin-on-freebsd/

and was doing those instructions when something funny happened:
kv_bsd# cd /usr/src
kv_bsd# patch -p0 < rtld_dlsym_hack.diff
Hmm...  Looks like a unified diff to me...
The text leading up to this was:
--------------------------
|--- libexec/rtld-elf/rtld.c.orig       Fri Sep 24 08:04:52 2004
|+++ libexec/rtld-elf/rtld.c    Sun Oct 17 03:37:44 2004
--------------------------
File to patch:


not sure what to tell it about what File to patch
0
Comment
Question by:kayvey
  • 15
  • 14
29 Comments
 

Author Comment

by:kayvey
ID: 20748150
You have mail.
kv_bsd# cd /usr/src
kv_bsd# patch -p0 < rtld_dlsym_hack.diff
Hmm...  Looks like a unified diff to me...
The text leading up to this was:
--------------------------
|--- libexec/rtld-elf/rtld.c.orig       Fri Sep 24 08:04:52 2004
|+++ libexec/rtld-elf/rtld.c    Sun Oct 17 03:37:44 2004
--------------------------
File to patch: +
No file found--skip this patch? [n]
File to patch: +++
No file found--skip this patch? [n]
File to patch: libexec/rtld-elf/rtld.c
No file found--skip this patch? [n] y
Skipping patch...
Hunk #1 ignored at 129.
Hunk #2 ignored at 178.
Hunk #3 ignored at 1738.
3 out of 3 hunks ignored--saving rejects to libexec/rtld-elf/rtld.c.rej
Can't create libexec/rtld-elf/rtld.c.rej, output is in /tmp//patchr61NAyV: No such file or directory
done
kv_bsd#
0
 
LVL 62

Expert Comment

by:gheist
ID: 20773009
Is there any sound at all? Like KDE bell?

0
 

Author Comment

by:kayvey
ID: 20773496
yes
0
Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 

Author Comment

by:kayvey
ID: 20773500
remember, we tested my sound hardware a long time ago, it all works perfectly. i can use command
line to listen to natalie merchant.
0
 
LVL 62

Expert Comment

by:gheist
ID: 20773722
Please post output of kldstat, so I know what your sound module is and make up parameters for it.
Do you run Gnome Or KDE? They take over sound hardware. We have two choices - make them silent and release sound hardware, or allow kernel to mix multiple attachments to sound card.
0
 

Author Comment

by:kayvey
ID: 20773754
kv_bsd# kldstat
Id Refs Address    Size     Name
 1   12 0xc0400000 6f6544   kernel
 2    1 0xc0af7000 5fa0     snd_ich.ko
 3    2 0xc0afd000 22b88    sound.ko
 4    1 0xc0b20000 59f20    acpi.ko
 5    1 0xc4f4c000 6000     linprocfs.ko
 6    1 0xc4f52000 16000    linux.ko
kv_bsd#


gnome
0
 
LVL 62

Expert Comment

by:gheist
ID: 20773775
I see your kernel is able to play sound, including from linux emulation. We will be making this ability into reality.
Do you run KDE or GNOME or neither? Do you get sound out of one you use?
0
 

Author Comment

by:kayvey
ID: 20773781
i said gnome.  yes.
0
 
LVL 62

Accepted Solution

by:
gheist earned 2000 total points
ID: 20773809
Prime up gnome terminal and inside it type either
esdwrapper firefox
or
esdwrapper linux-firefox
or
esdwrapper firefox-linux

i.e. the real firefox that has flash plugin working.

That will enable gnome's esd software to capture all sound playback requests and send it to soundcard it has locked.

Do you hear sound when firefox is launched this way?
0
 

Author Comment

by:kayvey
ID: 20773839
i can't find any such thing "esdwrapper"


kv_bsd# find / -name esdwrapper
kv_bsd#
0
 
LVL 62

Assisted Solution

by:gheist
gheist earned 2000 total points
ID: 20773849
Ooops - Gnomes audio wrapper is called esddsp - not esdwrapper.
Use esddsp to launch firefox
0
 

Author Comment

by:kayvey
ID: 20773953
hey!  i think that works!  heaven666.org works now!  is it possible to put this
in startup so i don't have to remember esddsp ?
0
 
LVL 62

Expert Comment

by:gheist
ID: 20773984
It is impossible to put this in startup. You have to alter every shortcut starting silent application. Skype and Opera+Flash comes in mind.

Now let us try kernel virtual sound devices. If it works this way then adding at startup will be easy as pie.

As root: sysctl -w hw.pcm.snd0.vchans=4
As user - run firefox without esddsp

Do you hear?

If yes:
Make change permanent:
echo hw.pcm.snd0.vchans=4 >> /etc/sysctl.conf

There was a bug in at least 5.x when one closed down linux app while it plays sound it wasted kernel audio virtual channel. If you encounter this bug still take care to report to bugs list. (i.e if firefox again becomes silent after couple of launches and only esddsp is able to continue to play if you got lucky)

0
 

Author Comment

by:kayvey
ID: 20774017
something is wrong with vchans

kv_bsd# sysctl -w hw.pcm.snd0.vchans=4
sysctl: unknown oid 'hw.pcm.snd0.vchans'
kv_bsd# sysctl -w hw.pcm.snd0.vchan=4
sysctl: unknown oid 'hw.pcm.snd0.vchan'
kv_bsd#

in order to follow your instructions, i just created a user.  i have just been logging on as root all the
time up until now.

Lock out the account after creation? [no]:
Username   : kayve
Password   : *****
Full Name  : Kayven Riese
Uid        : 1001
Class      :
Groups     : wheel
Home       : /usr/home/kayve
Shell      : /usr/local/bin/bash
Locked     : no
OK? (yes/no): yes
adduser: INFO: Successfully added (kayve) to the user database.
Add another user? (yes/no): no
Goodbye!
kv_bsd# su kayve
[kayve@kv_bsd /home/kayve/public_html]$ firefox
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified


(firefox-bin:2035): Gtk-WARNING **: cannot open display:  
[kayve@kv_bsd /home/kayve/public_html]$


that's weird.
0
 

Author Comment

by:kayvey
ID: 20774020
maybe it is because when i start up, gnome gives me login immediately.  i am in root window now.
0
 
LVL 62

Expert Comment

by:gheist
ID: 20774036
X11 does not work over 'su'

Please post outputs of sysctl hw.pcm and sysctl dev.pcm and sysctl dev.pcm0
I do not have 6.2 at hand so I am guessing all out of RELENG_7
0
 
LVL 62

Expert Comment

by:gheist
ID: 20774050
Running graphics as root is unsafe - one hack from bad website may backdoor or destroy your operating system.
0
 
LVL 62

Expert Comment

by:gheist
ID: 20774053
"root window" is X11 window covering whole desktop. Did you mean that?
0
 

Author Comment

by:kayvey
ID: 20774055
one says "mplayer plugin stopped"

maybe i should learn to cvsup now  {:}  i will ask another question for that later.. for now

kv_bsd# dmesg | psm
psm: Command not found.
kv_bsd# sysctl hw.pcm
sysctl: unknown oid 'hw.pcm'
kv_bsd# sysctl dev.pcm
dev.pcm.0.%desc: Intel ICH4 (82801DB)
dev.pcm.0.%driver: pcm
dev.pcm.0.%location: slot=31 function=5 handle=\_SB_.PCI0.AUDI
dev.pcm.0.%pnpinfo: vendor=0x8086 device=0x24c5 subvendor=0x1043 subdevice=0x1713 class=0x040100
dev.pcm.0.%parent: pci0
kv_bsd# ssyctl dev.pcm0
ssyctl: Command not found.
kv_bsd# sysctl dev.pcm0
sysctl: unknown oid 'dev.pcm0'
kv_bsd#
0
 

Author Comment

by:kayvey
ID: 20774058
btw, i booted up again now i am using user kayve.  i haven't found any problems except mplayer
0
 
LVL 62

Expert Comment

by:gheist
ID: 20774086
Lets use cannon to shoot the fly:
sysctl -a | egrep 'pcm.0|pcm0|vchan'
And post what is shown, i will post stsctl addition required

For mplayer - use console to run it. It displays lots of diagnostics and hints. As this is irrelevant to initial subject take this answer for side question as final and do a less-than-500pts question giving exactly what you need in subject and question and do not let anyone including you move away from initial subject. Thank you for understanding.
0
 
LVL 62

Expert Comment

by:gheist
ID: 20774170
Since we have not yet enabled multiple audio virtual channels it is expected that 2nd application stays silent.
0
 

Author Comment

by:kayvey
ID: 20780210
%sysctl -a | egrep 'pcm.0|pcm0|vchan'
hw.snd.maxautovchans: 0
hw.snd.pcm0.buffersize: 16384
hw.snd.pcm0.vchans: 0
hw.snd.pcm0.ac97rate: 48000
dev.pcm.0.%desc: Intel ICH4 (82801DB)
dev.pcm.0.%driver: pcm
dev.pcm.0.%location: slot=31 function=5 handle=\_SB_.PCI0.AUDI
dev.pcm.0.%pnpinfo: vendor=0x8086 device=0x24c5 subvendor=0x1043 subdevice=0x1713 class=0x040100
dev.pcm.0.%parent: pci0
%
0
 

Author Comment

by:kayvey
ID: 20790077
ummm.. are we done?  do i give you points now?
0
 
LVL 62

Expert Comment

by:gheist
ID: 20793011
hw.snd.maxautovchans=4
hw.snd.pcm0.vchans=4
into /etc/sysctl.conf
That should enable mplayer and flash alongside esd
0
 

Author Comment

by:kayvey
ID: 20793176
kv_bsd#cat /etc/sysctl.conf
# $FreeBSD: src/etc/sysctl.conf,v 1.8 2003/03/13 18:43:50 mux Exp $
#
#  This file is read when going to multi-user and its contents piped thru
#  ``sysctl'' to adjust kernel values.  ``man 5 sysctl.conf'' for details.
#

# Uncomment this to prevent users from seeing information about processes that
# are being run under another UID.
#security.bsd.see_other_uids=0
hw.snd.maxautovchans=4
hw.snd.pcm0.vchans=4
kv_bsd#
0
 

Author Comment

by:kayvey
ID: 20793360
i don't see errors.  should i give you points?

but my terminal sees errors

ERROR: ld.so: object '/usr/local/lib/libesd.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesddsp.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesd.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesddsp.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesd.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesddsp.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesd.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesddsp.so' from LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/usr/local/lib/libesd.so' from LD_PRELOAD cannot be preloaded: ignored.
0
 
LVL 62

Expert Comment

by:gheist
ID: 20795069
Terminal you launch firefox? I doubt.
Some program is linked against different esd version. portupgrade -R that program.
0
 
LVL 62

Expert Comment

by:gheist
ID: 20795071
Sound is working no further discussion, please.
0

Featured Post

Take Control of Web Hosting For Your Clients

As a web developer or IT admin, successfully managing multiple client accounts can be challenging. In this webinar we will look at the tools provided by Media Temple and Plesk to make managing your clients’ hosting easier.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article you will learn how to create a free basic website on Bitbucket, a git service provider. Polymer creates dynamic HTML components, which allow more flexibility than static HTML. This tutorial uses Ubuntu Linux but can also be done on W…
How does storytelling impact the web? What goes into a great story on the web? And how can it be used for marketing purposes? All of these questions will be answered.
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
The purpose of this video is to demonstrate how to set up the WordPress backend so that each page automatically generates a Mailchimp signup form in the sidebar. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome…
Suggested Courses
Course of the Month11 days, 3 hours left to enroll

612 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question