LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-10-2017, 10:00 AM   #1
phantom0929
LQ Newbie
 
Registered: Feb 2017
Posts: 2

Rep: Reputation: Disabled
Syslog-ng: Error binding socket; addr='AF_INET(0.0.0.0:1234)', error='Address already in use (98)'


syslog-ng error

Module loaded and initialized successfully; module='syslogformat'
Error binding socket; addr='AF_INET(0.0.0.0:1234)', error='Address already in use (98)'
Error initializing message pipeline;

Version of syslog-ng

3.5.6

output of syslog-ng --version

syslog-ng 3.5.6
Installer-Version: 3.5.6
Revision: 3.5.6-2+b1 [@416d315] (Debian/unstable)
Compile-Date: Oct 1 2014 18:23:11
Available-Modules: afprog,linux-kmsg-format,csvparser,afamqp,afsql,afstomp,cryptofuncs,afsocket,afuser,afsocket-notls,afmongodb,afsmtp,redis,json-plugin,dbparser,confgen,affile,system-source,afsocket-tls,tfgeoip,syslogformat,basicfuncs
Enable-Debug: off
Enable-GProf: off
Enable-Memtrace: off
Enable-IPv6: on
Enable-Spoof-Source: on
Enable-TCP-Wrapper: on
Enable-Linux-Caps: on
Enable-Pcre: on

Platform

Debian 8.7

Issue

Trying to setup syslog-ng host to recieve log mesages from client s by listening on port 1234 via tcp

Failure

Module loaded and initialized successfully; module='syslogformat'
Error binding socket; addr='AF_INET(0.0.0.0:1234)', error='Address already in use (98)'
Error initializing message pipeline;



Configuration

@version: 3.5.6
@include "scl.conf"
options {
time-reap(30);
mark-freq(10);
keep-hostname(yes);
};

source s_local { system(); internal(); };

source s_network { syslog(ip(0.0.0.0) transport("tcp") port(1234) ); };

destination d_logs {
file(
"/var/log/syslog-ng/logs.txt"
owner("root")
group("root")
perm(0777)
); };
log { source(s_local); source(s_network); destination(d_logs); };

log { source(s_network); destination(d_logs); };
 
Old 02-10-2017, 10:22 AM   #2
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Code:
lsof -p 1234
 
Old 02-10-2017, 03:03 PM   #3
phantom0929
LQ Newbie
 
Registered: Feb 2017
Posts: 2

Original Poster
Rep: Reputation: Disabled
Habitual: that didnt work

I ran the "lsof -p 1234", which releases the port, but the port gets reclaimed automatically. Still get same error after resarting syslog-ng: Error binding socket; addr='AF_INET(0.0.0.0:1234)', error='Address already in use (98)'
Error initializing message pipeline;
 
Old 02-10-2017, 03:24 PM   #4
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
"reclaimed automatically" by syslog-ng?

0.0.0.0 typically represents "use all interfaces", (unconfigured, possibly?)
Perhaps that is the clue?

Sorry, that's all I got.
 
Old 03-24-2017, 11:08 PM   #5
bazsi77
LQ Newbie
 
Registered: Mar 2017
Posts: 1

Rep: Reputation: Disabled
You might also have two sources in your configuration that binds to the same port.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ERROR writing to socket: Bad address gajananh999 Linux - Newbie 5 08-06-2012 08:00 PM
AF_LOCAL domain socket versus AF_INET socket performance zzaappp Linux - General 0 06-19-2008 07:50 AM
unix-socket error:bind: Address already in use sweetytweety Linux - Newbie 2 05-12-2008 01:13 AM
ERROR reading from socket: Bad address cynthia_thomas Programming 1 02-18-2006 07:02 AM
error binding address/port blackzone Linux - Networking 1 09-03-2004 02:23 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:21 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration