Skip to content

Use loopback address instead of localhost to fix gethostbyname error#1

Open
thunderysteak wants to merge 1 commit into
comigor:masterfrom
thunderysteak:master
Open

Use loopback address instead of localhost to fix gethostbyname error#1
thunderysteak wants to merge 1 commit into
comigor:masterfrom
thunderysteak:master

Conversation

@thunderysteak

Copy link
Copy Markdown

Darkice has issues when localhost is used in its configuration while in a docker container, resulting in "gethostbyname error". Using a loopback address instead fixes the issue.

Starting pulseaudio...
Starting pulseaudio...
Starting Icecast2...
 * Starting streaming media server icecast2
   ...done.
[2021-05-04  00:31:14] WARN CONFIG/_parse_root Warning, <hostname> not configured, using default value "localhost". This will cause problems, e.g. with YP directory listings.
[2021-05-04  00:31:14] WARN CONFIG/_parse_root Warning, <location> not configured, using default value "Earth".
[2021-05-04  00:31:14] WARN CONFIG/_parse_root Warning, <admin> contact not configured, using default value "icemaster@localhost".
Starting spotifyd...
Starting darkice...
DarkIce 1.3 live audio streamer, http://code.google.com/p/darkice/
Copyright (c) 2000-2007, Tyrell Hungary, http://tyrell.hu/
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: /home/user/darkice.cfg
Using ALSA DSP input device: pulse
Could not set POSIX real-time scheduling, this may cause recording skips.
Try to run darkice as the super-user.
DarkIce: TcpSocket.cpp:226: gethostbyname error [0]

You can prevent DarkIce to attempt to look for a hostname by using a loopback address instead.

Tested by copying the cfg from the docker container, modifying the value and then copying the file back into the container

Fix for "gethostbyname error"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant