Ubuntu and Darkice

Status
Not open for further replies.

ScanWI

MN & WI DB Admin
Database Admin
Joined
Feb 6, 2009
Messages
929
Location
Wisconsin
I have been running a secondary laptop on Linux for a while now and I wanted to switch my feeds over to it, however I am new to linux and using a non-Dos terminal. I believe I have gotten everything setup correctly but it does not seem to do any thing. Here is my Configuration file. It would be great if someone could check it to see if there is anything wrong.

# sample DarkIce configuration file, edit for your needs before using
# see the darkice.cfg man page for details

# this section describes general aspects of the live streaming session
[general]
duration = 0 # duration of encoding, in seconds. 0 means forever
bufferSecs = 2 # size of internal slip buffer, in seconds
reconnect = yes # reconnect to the server(s) if disconnected

# this section describes the audio input that will be streamed
[input]
device = dev/audio # OSS DSP soundcard device for the audio input
sampleRate = 11025 # sample rate in Hz. try 11025, 22050 or 44100
bitsPerSample = 16 # bits per sample. try 16
channel = 1 # channels. 1 = mono, 2 = stereo

# this section describes a streaming connection to an IceCast server
# there may be up to 8 of these sections, named [icecast-0] ... [icecast-7]
# these can be mixed with [icecast2-x] and [shoutcast-x] sections

# If you want to send to your own icecast server, you basically copy
# this whole section and put in the values to point the feed to your own
# server instead of the RR information below

# Don't forget, the name [icecast2-0] needs to change to [icecast2-1]
# and 2 and 3 as you add more feed destinations.

[icecast2-0]
# The audio format to encode to, we're using mp3 here
format = mp3

# The bit rate mode to use, the commented out lines are for a fixed bit
# rate "constant bit rate" at 16 bits. I prefer the variable bit rate
# for the sound quality it has and the throughput is very similar on avg

#bitrateMode = cbr
#bitrate = 16

bitrateMode = vbr

# Quality at .1, max is 1.0, but as you increase, so does the bandwidth
# used. For mono scanner audio .1 is totally fine.
quality = 0.5

# Takes the input and mixes it down to a mono output for the feed.
channel = 1

# Cuts frequency response over 5kHz. For scanner feed this mostly
# eliminates hiss and harshness on paging tones. Saves a bunch of
# bandwidth as well.
lowpass = 5000

# Server shown on your RR feed owner page that hosts your feed
# You need to log in to RR, go to Account -> My Live Audio Feeds ->
# click the feed owner page icon at the far right of your feed listing.
# Then you will see all this information.

# From Feed Technical Details, the "Server"
server = audio3.radioreference.com

# From Feed Technical Details, the "Port"
port = 80 # port of the IceCast server, usually 8000

# From Feed Technical Details, the Password exactly as shown
password = 1fkh0swc

# From Feed Technical Details, the mount...remove the leading "/", it's
# not needed in this file. So if it is /999999 make it just 999999
mountPoint = /162376812

# name of the strea
# On My Live Audio Feeds, it's the first part ending in a colon ":"
name = Jefferson and Dodge County, and Watertown Police and FIRE

# On My Live Audio Feeds, it's the part in parentheses in the Feed name
description =

# I don't think this is really needed because RR takes care of links
url = http://api.radioreference.com/js/?key=XXXXXXX&feedId=XXXX
genre = Public Safety
public = yes
When I go into the terminal this is what I enter and get:

:confused:
Code:
aaron@UbuntuAD:~$ sudo darkice -c /home/aaron/Documents/sc_rr_v014/rr.cfg
DarkIce 0.20.1 live audio streamer, http://darkice.tyrell.hu/
Copyright (c) 2000-2007, Tyrell Hungary, http://tyrell.hu/

Using config file: /home/aaron/Documents/sc_rr_v014/rr.cfg
DarkIce: DarkIce.cpp:150: no section [general] in config [0]
aaron@UbuntuAD:~$
:confused:

This is the point were I am not sure if anything is right.
 

eddie555

Member
Joined
Oct 5, 2015
Messages
45
Location
Cincinnati, Ohio
I have been running a secondary laptop on Linux for a while now and I wanted to switch my feeds over to it, however I am new to linux and using a non-Dos terminal. I believe I have gotten everything setup correctly but it does not seem to do any thing. Here is my Configuration file. It would be great if someone could check it to see if there is anything wrong.

When I go into the terminal this is what I enter and get:

:confused:
Code:
aaron@UbuntuAD:~$ sudo darkice -c /home/aaron/Documents/sc_rr_v014/rr.cfg
DarkIce 0.20.1 live audio streamer, http://darkice.tyrell.hu/
Copyright (c) 2000-2007, Tyrell Hungary, http://tyrell.hu/

Using config file: /home/aaron/Documents/sc_rr_v014/rr.cfg
DarkIce: DarkIce.cpp:150: no section [general] in config [0]
aaron@UbuntuAD:~$
:confused:

This is the point were I am not sure if anything is right.

I'm about six years behind the curve on this one, my Icecast2 server seems to start but, I get this error message when I try to start Darkice with:

uber-user@uberuser-MacBookPro:~$ darkice -c /src/darkice-1.3/darkice.cfg
DarkIce 1.3 live audio streamer, Google Code Archive - Long-term storage for Google Code Project Hosting.
Copyright (c) 2000-2007, Tyrell Hungary, Tyrell Hungary Corporation
Copyright (c) 2008-2013, Akos Maroy and Rafael Diniz
This is free software, and you are welcome to redistribute it
under the terms of The GNU General Public License version 3 or
any later version.

Using config file: /src/darkice-1.3/darkice.cfg
DarkIce: DarkIce.cpp:155: no section [general] in config [0]

I've edited the .cfg file

[general]
duration = 0 # duration of encoding, in seconds. 0 means forever
bufferSecs = 5 # size of internal slip buffer, in seconds
reconnect = yes # reconnect to the server(s) if disconnected


[input]
device = /dev/dsp # ALSA DSP soundcard device for the audio input
sampleRate = 22050 # sample rate in Hz. try 11025, 22050 or 44100
bitsPerSample = 16 # bits per sample. try 16
channel = 2 # channels. 1 = mono, 2 = stereo


[icecast2-0]
bitrateMode = abr # average bit rate
format = mp3 # format of the stream: mp3
bitrate = 96 # bitrate of the stream sent to the server
server = yp.yourserver.com
# host name of the server
port = 8000 # port of the IceCast2 server, usually 8000
password = passw # source password to the IceCast2 server
mountPoint = sample96 # mount point of this stream on the IceCast2 server
name = DarkIce trial
# name of the stream
description = This is only a trial
# description of the stream
url = yourserver.com
# URL related to the stream
genre = my own # genre of the stream
public = no # advertise this stream?
localDumpFile = dump.mp3 # local dump file

# this section describes a streaming connection to an IceCast server
# there may be up to 8 of these sections, named [icecast-0] ... [icecast-7]
# these can be mixed with [icecast2-x] and [shoutcast-x] sections
[icecast-0]

bitrateMode = cbr # constant bit rate
bitrate = 96 # bitrate of the mp3 stream sent to the server
quality = 0.8 # encoding quality
server = yp.yourserver.com
# host name of the server
port = 8000 # port of the IceCast server, usually 8000
password = passw # source password to the IceCast server
mountPoint = sample96 # mount point of this stream on the IceCast server
name = DarkIce trial
# name of the stream
description = This is only a trial
# description of the stream
url = http://192.168.0.19:8000
# URL related to the stream
genre = my own # genre of the stream
public = no # advertise this stream?

# this section describes a streaming connection to a ShoutCast server
# there may be up to 8 of these sections, named [shoutcast-0] ... [shoutcast-7]
# these can be mixed with [icecast-x] and [icecast2-x] sections
[shoutcast-0]
bitrateMode = vbr # variable bit rate mode
quality = 0.5 # encoding quality
server = yp.yourserver.com
# host name of the server
port = 8001 # source port of the ShoutCast server, usually 8001
password = hackme # source password to the ShoutCast server
name = DarkIce trial
# name of the stream
url = yourserver.com
# URL related to the stream
genre = my own # genre of the stream
public = yes # advertise this stream?
irc = irc.yourserver.com
# IRC info related to the stream
aim = aim here # AIM info related to the stream
icq = I see you too
# ICQ info related to the stream

Ubuntu 14.04

.
 
Last edited:

DC31

Member
Feed Provider
Joined
Feb 19, 2011
Messages
1,547
Location
Massachusetts
It is telling you that it can't find the [general] section of the darkice configuration file. The cfg text the you have posted definitely has the [general] section in it. So, when starting darkice, are you pointing the program to the correct .cfg file? I believe the default location it looks in is /etc/darkice.cfg. Unless you are specifying another path that is the file it is reading.

Once you get past that point, i think you want cbr rather than vbr for bcfy.
 

eddie555

Member
Joined
Oct 5, 2015
Messages
45
Location
Cincinnati, Ohio
OK, I start the server

uber-user@uberuser-MacBookPro:~$ sudo /etc/init.d/icecast2 start
[sudo] password for uber-user:
Starting icecast2: uber-user@uberuser-MacBookPro:~$

Next, I try to start darkice:

uber-user@uberuser-MacBookPro:~$ darkice -c /etc/darkice.cfg
DarkIce 1.3 live audio streamer, Google Code Archive - Long-term storage for Google Code Project Hosting.
Copyright (c) 2000-2007, Tyrell Hungary, Tyrell Hungary Corporation
Copyright (c) 2008-2013, Akos Maroy and Rafael Diniz
This is free software, and you are welcome to redistribute it
under the terms of The GNU General Public License version 3 or
any later version.

Using config file: /etc/darkice.cfg
Using OSS DSP input device: /dev/dsp
Could not set POSIX real-time scheduling, this may cause recording skips.
Try to run darkice as the super-user.
DarkIce: DarkIce.cpp:1273: can't open connector [0]
sudo dark^Z
[2]+ Stopped darkice -c /etc/darkice.cfg
uber-user@uberuser-MacBookPro:~$ sudo darkice -c /etc/darkice.cfg
[sudo] password for uber-user:
DarkIce 1.3 live audio streamer, Google Code Archive - Long-term storage for Google Code Project Hosting.
Copyright (c) 2000-2007, Tyrell Hungary, Tyrell Hungary Corporation
Copyright (c) 2008-2013, Akos Maroy and Rafael Diniz
This is free software, and you are welcome to redistribute it
under the terms of The GNU General Public License version 3 or
any later version.

Using config file: /etc/darkice.cfg
Using OSS DSP input device: /dev/dsp
Using POSIX real-time scheduling, priority 4
DarkIce: DarkIce.cpp:1273: can't open connector [0]
uber-user@uberuser-MacBookPro:~$ sudo darkice -c /etc/darkice.cfg
[sudo] password for uber-user:
DarkIce 1.3 live audio streamer, Google Code Archive - Long-term storage for Google Code Project Hosting.
Copyright (c) 2000-2007, Tyrell Hungary, Tyrell Hungary Corporation
Copyright (c) 2008-2013, Akos Maroy and Rafael Diniz
This is free software, and you are welcome to redistribute it
under the terms of The GNU General Public License version 3 or
any later version.

Using config file: /etc/darkice.cfg
Using OSS DSP input device: /dev/dsp
Using POSIX real-time scheduling, priority 4
DarkIce: DarkIce.cpp:1273: can't open connector [0]
uber-user@uberuser-MacBookPro:~$

Code:
[quote]
# sample DarkIce configuration file, edit for your needs before using
# see the darkice.cfg man page for details

# this section describes general aspects of the live streaming session
[general]
duration        = 0         # duration of encoding, in seconds. 0 means forever
bufferSecs      = 5         # size of internal slip buffer, in seconds
reconnect       = yes       # reconnect to the server(s) if disconnected

# this section describes the audio input that will be streamed
[input]
device          = /dev/dsp  # OSS DSP soundcard device for the audio input
sampleRate      = 44100     # sample rate in Hz. try 11025, 22050 or 44100
bitsPerSample   = 16        # bits per sample. try 16
channel         = 2         # channels. 1 = mono, 2 = stereo

# this section describes a streaming connection to an IceCast2 server
# there may be up to 8 of these sections, named [icecast2-0] ... [icecast2-7]
# these can be mixed with [icecast-x] and [shoutcast-x] sections
[icecast2-0]
bitrateMode     = cbr       # average bit rate
format          = mp3       # format of the stream: mp3
bitrate         = 128       # bitrate of the stream sent to the server
server          = yp.yourserver.com
                            # server name
                            # host name of the server
port            = 8000      # port of the IceCast2 server, usually 8000
password        = passw     # source password to the IceCast2 server
mountPoint      = sample96  # mount point of this stream on the IceCast2 server
name            = DarkIce trial
                            # name of the stream
description     = This is only a trial
                            # description of the stream
url             = 192.168.0.19:8000
                            # URL related to the stream
genre           = my own    # genre of the stream
public          = no        # advertise this stream?
localDumpFile	= dump.mp3  # local dump file

# this section describes a streaming connection to an IceCast server
# there may be up to 8 of these sections, named [icecast-0] ... [icecast-7]
# these can be mixed with [icecast2-x] and [shoutcast-x] sections
[icecast2-0]
bitrateMode     = cbr       # constant bit rate
format		= mp3       # format of the stream: mp3
bitrate         = 96        # bitrate of the mp3 stream sent to the server
quality         = 0.8       # encoding quality
server          = yp.yourserver.com
                            # host name of the server
port            = 8000      # port of the IceCast server, usually 8000
password        = passw     # source password to the IceCast server
mountPoint      = sample96  # mount point of this stream on the IceCast server
name            = DarkIce trial
                            # name of the stream
description     = This is only a trial
                            # description of the stream
url             = http://192.168.0.19:8000
                            # URL related to the stream
genre           = my own    # genre of the stream
public          = no        # advertise this stream?

# this section describes a streaming connection to a ShoutCast server
# there may be up to 8 of these sections, named [shoutcast-0] ... [shoutcast-7]
# these can be mixed with [icecast-x] and [icecast2-x] sections
[shoutcast-0]
bitrateMode     = vbr       # variable bit rate mode
quality         = 0.5       # encoding quality
server          = yp.yourserver.com
                            # host name of the server
port            = 8001      # source port of the ShoutCast server, usually 8001
password        = passw     # source password to the ShoutCast server
name            = DarkIce trial
                            # name of the stream
url             = http://192.168.0.19:8001
                            # URL related to the stream
genre           = my own    # genre of the stream
public          = no        # advertise this stream?
irc             = irc.yourserver.com
                            # IRC info related to the stream
aim             = aim here  # AIM info related to the stream
icq             = I see you tooo
                            # ICQ info related to the stream

.
 

DC31

Member
Feed Provider
Joined
Feb 19, 2011
Messages
1,547
Location
Massachusetts
I don't think that I am at the one to help you solve this one but I will point out some things to maybe get you going in the right direction:

1. Don't use sudo to start darkice. Ignore the warning about recording skips.
2. Make sure that you have this part right:
device = /dev/dsp # OSS DSP soundcard device for the audio input
That might be the connector that it can't open.
3. You have 3 output sections (icecast2-0) (icecast2-0) and (shoutcast-0) Delete the second and third sections leaving only the first 2-0 section. Darkice definitely doesn't like having two sections named 2-0 and the shoutcast section would only screw things up further. If you are running an icecast server it wants an icecast section.
4. Try changing yp.yourserver.com to localhost.
5. when you set up the icecast server on your laptop, you should have set a password. make sure that matches the password in your configuration file (passw).
6. Have a read through this document for some more basic information: https://stmllr.net/blog/live-mp3-streaming-from-audio-in-with-darkice-and-icecast2-on-raspberry-pi/

Good Luck
 
Status
Not open for further replies.
Top