This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Eggdrop can't connect to irc servers [SOLVED]

General support and discussion of Eggdrop bots.
Post Reply
s
shellx
Voice
Posts: 9
Joined: Thu Mar 12, 2009 9:49 pm

Eggdrop can't connect to irc servers [SOLVED]

Post by shellx »

Eggdrop Conf File:

Code: Select all

set offset "5"
set my-hostname "localhost"
set my-ip "192.168.0.5"
addlang "english"
set max-logs 5
set max-logsize 0
set quick-logs 0
set log-time 1
set keep-all-logs 4
set logfile-suffix ".%d%b%Y"
set switch-logfiles-at 300
set quiet-save 0
set console "mkcobxs"
set pidfile "pid.${botnet-nick}"
set sort-users 1
set help-path "help/"
set text-path "text/"
set temp-path "tmp/"
set motd "text/motd"
set telnet-banner "text/banner"
set userfile-perm 0600
set remote-boots 2
set share-unlinks 1
set protect-telnet 0
set dcc-sanitycheck 0
set ident-timeout 5
set require-p 0
set open-telnets 0
set stealth-telnets 0
set use-telnet-banner 0
set connect-timeout 15
set dcc-flood-thr 3
set telnet-flood 5:60
set paranoid-telnet-flood 1
set resolve-timeout 15
#set firewall "!sun-barr.ebay:3666"
set nat-ip "83.***.***.*"
#set reserved-portrange 2010:2020
set ignore-time 15
# set hourly-updates 15
set hourly-updates 00
set notify-newusers "$owner"
set whois-fields "url birthday"
set die-on-sighup 0
set die-on-sigterm 1
unbind dcc n tcl *dcc:tcl
unbind dcc n set *dcc:set
set must-be-owner 1
unbind dcc n simul *dcc:simul
set max-dcc 50
set enable-simul 1
set allow-dk-cmds 1
set dupwait-timeout 5
set mod-path "modules/"
set ban-time 240
set exempt-time 60
set invite-time 60
set force-expire 0
set share-greet 0
set use-info 1


set global-flood-chan 5:10
set global-flood-deop 3:10
set global-flood-kick 3:10
set global-flood-join 5:60
set global-flood-ctcp 3:60
set global-flood-nick 5:60
set global-aop-delay 5:30
set global-idle-kick 0
set global-chanmode "nt-mlik"
set global-stopnethack-mode 0
set global-revenge-mode 3
set global-chanset {
        -autoop         -autovoice
        -bitch          +cycle
        -dontkickops    +dynamicbans
        +dynamicexempts +dynamicinvites
        -enforcebans    +greet
        -inactive       -nodesynch
        +protectfriends -protectops
        +revenge        +revengebot
        -secret         -seen
        +shared         +statuslog
        +userbans       +userexempts
        +userinvites
}
set net-type 0
set init-server { putserv "MODE $botnick +i-ws" }
set default-port 6667
set keep-nick 1
set strict-host 0
set quiet-reject 1
set lowercase-ctcp 0
set answer-ctcp 3
set flood-msg 5:60
set flood-ctcp 3:60
set never-give-up 1
set strict-servernames 0
set server-cycle-wait 60
set server-timeout 60
set servlimit 0
set check-stoned 1
set use-console-r 0
set debug-output 0
set serverror-quit 1
set max-queue-msg 300
set trigger-on-ignore 0
set double-mode 0
set double-server 0
set double-help 0
set optimize-kicks 1
#set check-mode-r 1
#set nick-len 9
loadmodule ctcp
set ctcp-mode 0
loadmodule irc
set bounce-bans 1
set bounce-modes 0
set max-bans 20
set max-modes 30
set kick-fun 0
set ban-fun 0
set learn-users 0
set wait-split 600
set wait-info 180
set mode-buf-length 200
unbind msg - ident *msg:ident
unbind msg - addhost *msg:addhost
set no-chanrec-info 0
set bounce-exempts 0
set bounce-invites 0
set max-exempts 20
set max-invites 20
#set use-exempts 0
#set use-invites 0
set prevent-mixing 1
#set kick-method 1
#set modes-per-line 3
#set include-lk 1
#set use-354 0
#set rfc-compliant 1
set max-dloads 3
set dcc-block 1024
set copy-to-tmp 1
set xfer-timeout 30
#set allow-resync 0
#set resync-time 900
#set private-global 0
#set private-globals "mnot"
#set private-user 0
#set override-bots 0
set share-compressed 1
#set compress-level 9
set upload-to-pwd 0
set filedb-path ""
set max-file-users 20
set max-filesize 1024
set max-notes 50
set note-life 60
set allow-fwd 0
set notify-users 1
set notify-onjoin 1
set console-autosave 1
set force-channel 0
set info-party 0
source scripts/alltools.tcl
source scripts/action.fix.tcl
source scripts/compat.tcl
source scripts/userinfo.tcl
loadhelp userinfo.help

#####################################
# Eggdrop .conf creator version 0.1 #
#####################################


set username "test"
set admin "body <email: body@body.com>"
set network "FreeNode"
set timezone "EST"
set userfile "test.user"
set botnet-nick "test"
listen 7777 users
listen 8888 bots
listen 9999 all
set owner "body"
set default-flags "hp"
set chanfile "test.chan"
set nick "test"
set altnick "test2"
set realname "test"
logfile mco * "logs/eggdrop.log"
logfile jpk #test "logs/channel.log"
set files-path "/home/lamer/eggdrop/filesys"
set incoming-path "/home/lamer/eggdrop/filesys/incoming"
set servers {
irc.freenode.net:6667}
channel add #test {
chanmode "+nt-lkims"
idle-kick 0
stopnethack-mode 0
revenge-mode 0
aop-delay 5:30
need-op { putserv "PRIVMSG CS :op #test" }
need-invite { putserv "PRIVMSG CS: inv #test" }
need-unban { putserv "PRIVMSG CS: unban #test" }
flood-chan 5:10
flood-deop 3:10
flood-kick 3:10
flood-join 5:60
flood-ctcp 3:60
flood-nick 5:60
}
channel set #test -enforcebans
channel set #test +dynamicbans
channel set #test +userbans
channel set #test +dynamicexempts
channel set #test +userexempts
channel set #test +dynamicinvites
channel set #test +userinvites
channel set #test +greet
channel set #test -protectops
channel set #test +protectfriends
channel set #test -statuslog
channel set #test +revenge
channel set #test +revengebot
channel set #test -autovoice
channel set #test +cycle
channel set #test -dontkickops
channel set #test -autoop
channel set #test -bitch
channel set #test -secret
channel set #test +shared
#loadmodule dns
loadmodule channels
loadmodule server
loadmodule transfer
loadmodule share
#loadmodule compress
#loadmodule filesys
#loadmodule notes
loadmodule console
#loadmodule woobie
#loadmodule seen
loadmodule blowfish
#loadmodule assoc
loadmodule wire
loadmodule uptime
Router Port Forwarding Image:
Image

Code: Select all

test@shell:~/eggdrop$ ./eggdrop -m eggdrop.conf

Eggdrop v1.6.19 (C) 1997 Robey Pointer (C) 2008 Eggheads
[08:53] --- Loading eggdrop v1.6.19 (Fri Mar 13 2009)
[08:53] Module loaded: server
[08:53] Module loaded: ctcp
[08:53] Module loaded: channels
[08:53] Module loaded: irc
[08:53] Userinfo TCL v1.07 loaded (URL BF GF IRL EMAIL DOB PHONE ICQ).
[08:53] use '.help userinfo' for commands.
[08:53] Listening at telnet port 7777 (users).
[08:53] Listening at telnet port 8888 (bots).
[08:53] Listening at telnet port 9999 (all).
[08:53] Module loaded: transfer         (with lang support)
[08:53] Module loaded: share
[08:53] Module loaded: console          (with lang support)
[08:53] Module loaded: blowfish
[08:53] Module loaded: wire             (with lang support)
[08:53] Module loaded: uptime


STARTING BOT IN USERFILE CREATION MODE.
Telnet to the bot and enter 'NEW' as your nickname.
OR go to IRC and type:  /msg test hello
This will make the bot recognize you as the master.

[08:53] === test: 1 channels, 0 users.
Launched into the background  (pid: 32048)
Please Help Me :(
Last edited by shellx on Sun Mar 15, 2009 8:01 am, edited 2 times in total.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Did you try telneting into your bot and check out what is happening?
s
shellx
Voice
Posts: 9
Joined: Thu Mar 12, 2009 9:49 pm

Post by shellx »

Sir_Fz wrote:Did you try telneting into your bot and check out what is happening?
Can't connect with telnet.

Code: Select all

Trying 192.168.0.5...
Connected to 192.168.0.5.
Escape character is '^]'.
:?
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

First off, don't do this:

Code: Select all

set my-hostname "localhost"
set my-ip "192.168.0.5"
Localhost will in most cases point to 127.0.0.1, and when setting both my-ip and my-hostname (which both affect the very same setting, upon which ip/interface any socket will be created) it may lead to some confusion as to which takes precedence (with current eggdrops, my-ip will take precedence, overriding any my-hostname settings).

Secondly, do you really need to set either my-ip or my-hostname?
Generally, this should only be set if your eggdrop is unable to figure out which IP address to use (most common with windrops), or if you are using a "multihomed" system and wich to control which IP address should be presented to the irc network (this also affects listen-ports and may cause unexpected behaviours with bot linking).

I see you've set nat-ip, which is good since you're behind a NAT-router. Also, you've done some extensive port forwarding. I would suggest you have a look at the reserved-portrange setting, which allows you to restrict the ports used by your eggdrop for dcc communications and botnet userfile transfers. This would allow you to limit the port range you forward to your system (if needed).

Also, you've got some awkward ordering of settings and module loadings in your config. Be aware that some modules will actually replace any existing settings with default ones upon loading. In fact, you actually try to add channels first, and then load the channels module. I'm puzzled you actually got this bot running in the first place.
Rather than using some config file generator, I'd suggest you start fresh using the example config that should've come with your eggdrop. Yes, it's huge and overwhelming, but it keeps settings in a proper order and will work without too much hazzle.
Worth noting: In your case, you actually set the serverlist before loading the servers module, which in fact will wipe the servers list. This is most likely why your eggdrop won't show up on irc...
NML_375
s
shellx
Voice
Posts: 9
Joined: Thu Mar 12, 2009 9:49 pm

Post by shellx »

nml375 wrote:First off, don't do this:

Code: Select all

set my-hostname "localhost"
set my-ip "192.168.0.5"
Localhost will in most cases point to 127.0.0.1, and when setting both my-ip and my-hostname (which both affect the very same setting, upon which ip/interface any socket will be created) it may lead to some confusion as to which takes precedence (with current eggdrops, my-ip will take precedence, overriding any my-hostname settings).

Secondly, do you really need to set either my-ip or my-hostname?
Generally, this should only be set if your eggdrop is unable to figure out which IP address to use (most common with windrops), or if you are using a "multihomed" system and wich to control which IP address should be presented to the irc network (this also affects listen-ports and may cause unexpected behaviours with bot linking).

I see you've set nat-ip, which is good since you're behind a NAT-router. Also, you've done some extensive port forwarding. I would suggest you have a look at the reserved-portrange setting, which allows you to restrict the ports used by your eggdrop for dcc communications and botnet userfile transfers. This would allow you to limit the port range you forward to your system (if needed).

Also, you've got some awkward ordering of settings and module loadings in your config. Be aware that some modules will actually replace any existing settings with default ones upon loading. In fact, you actually try to add channels first, and then load the channels module. I'm puzzled you actually got this bot running in the first place.
Rather than using some config file generator, I'd suggest you start fresh using the example config that should've come with your eggdrop. Yes, it's huge and overwhelming, but it keeps settings in a proper order and will work without too much hazzle.
Worth noting: In your case, you actually set the serverlist before loading the servers module, which in fact will wipe the servers list. This is most likely why your eggdrop won't show up on irc...
I try with original conf file, without my-hostname, my-ip, but does not work :cry: PLEASE HELP ME ..
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

First step then, would be to start your eggdrop using -nt flags:

Code: Select all

 ./eggdrop -m -nt eggdrop.conf
This will prevent your eggdrop from dropping into background, and allows you to monitor log messages and similar in realtime.
Those messages should help us figure out why it's not connecting properly.
NML_375
s
shellx
Voice
Posts: 9
Joined: Thu Mar 12, 2009 9:49 pm

Post by shellx »

nml375 wrote:First step then, would be to start your eggdrop using -nt flags:

Code: Select all

 ./eggdrop -m -nt eggdrop.conf
This will prevent your eggdrop from dropping into background, and allows you to monitor log messages and similar in realtime.
Those messages should help us figure out why it's not connecting properly.

Code: Select all

test@shell:~/eggdrop$ ./eggdrop -mn eggdrop.conf

Eggdrop v1.6.19 (C) 1997 Robey Pointer (C) 2008 Eggheads
[21:02] Allocated bind table unld (flags 1)
[21:02] Allocated bind table time (flags 1)
[21:02] Allocated bind table note (flags 0)
[21:02] Allocated bind table nkch (flags 1)
[21:02] Allocated bind table load (flags 1)
[21:02] Allocated bind table link (flags 1)
[21:02] Allocated bind table filt (flags 1)
[21:02] Allocated bind table disc (flags 1)
[21:02] Allocated bind table dcc (flags 0)
[21:02] Allocated bind table chpt (flags 1)
[21:02] Allocated bind table chon (flags 1)
[21:02] Allocated bind table chof (flags 1)
[21:02] Allocated bind table chjn (flags 1)
[21:02] Allocated bind table chat (flags 1)
[21:02] Allocated bind table bot (flags 0)
[21:02] Allocated bind table bcst (flags 1)
[21:02] Allocated bind table away (flags 1)
[21:02] Allocated bind table act (flags 1)
[21:02] Allocated bind table evnt (flags 1)
[21:02] --- Loading eggdrop v1.6.19 (Fri Mar 13 2009)
[21:02] Listening at telnet port 7777 (bots).
[21:02] Listening at telnet port 8888 (users).
[21:02] Listening at telnet port 9999 (all).
[21:02] Module loaded: blowfish
[21:02] Module loaded: dns
[21:02] Module loaded: channels
[21:02] Allocated bind table wall (flags 1)
[21:02] Allocated bind table raw (flags 1)
[21:02] Allocated bind table notc (flags 1)
[21:02] Allocated bind table msgm (flags 1)
[21:02] Allocated bind table msg (flags 0)
[21:02] Allocated bind table flud (flags 1)
[21:02] Allocated bind table ctcr (flags 1)
[21:02] Allocated bind table ctcp (flags 1)
[21:02] Module loaded: server
[21:02] Module loaded: ctcp
[21:02] Allocated bind table topc (flags 1)
[21:02] Allocated bind table splt (flags 1)
[21:02] Allocated bind table sign (flags 1)
[21:02] Allocated bind table rejn (flags 1)
[21:02] Allocated bind table part (flags 1)
[21:02] Allocated bind table nick (flags 1)
[21:02] Allocated bind table mode (flags 1)
[21:02] Allocated bind table kick (flags 1)
[21:02] Allocated bind table join (flags 1)
[21:02] Allocated bind table pubm (flags 1)
[21:02] Allocated bind table pub (flags 0)
[21:02] Allocated bind table need (flags 1)
[21:02] Module loaded: irc
[21:02] LANG: Section loaded: notes
[21:02] LANG: 42 messages of 47 lines loaded from ./language/notes.english.lang
[21:02] LANG: 42 adds, 0 updates to message table
[21:02] Module loaded: notes            (with lang support)
[21:02] LANG: Section loaded: console
[21:02] LANG: 10 messages of 15 lines loaded from ./language/console.english.lang
[21:02] LANG: 10 adds, 0 updates to message table
[21:02] Module loaded: console          (with lang support)
[21:02] Module loaded: uptime
[21:02] Userinfo TCL v1.07 loaded (URL BF GF IRL EMAIL DOB PHONE ICQ).
[21:02] use '.help userinfo' for commands.


STARTING BOT IN USERFILE CREATION MODE.
Telnet to the bot and enter 'NEW' as your nickname.
OR go to IRC and type:  /msg test hello
This will make the bot recognize you as the master.

[21:02] === test: 0 channels, 0 users.
[21:02] main: entering loop
[21:02] Trying server irc.freenode.net:6667
[21:02] DNS resolved irc.freenode.net to 140.211.166.4
[21:02] net: connect! sock 11
[21:02] Connected to irc.freenode.net
[21:02] -NOTICE- *** Looking up your hostname...
[21:02] -NOTICE- *** Checking ident
[21:02] -NOTICE- *** Your forward and reverse DNS don't match
[21:02] NICK IN USE: Trying 'test2'
[21:02] -NOTICE- *** Your host is niven.freenode.net[niven.freenode.net/6667], running version hyperion-1.0.2b
[21:02] net: connect! sock 7
[21:02] DNS resolved 85.190.0.3 to proxyscan.freenode.net
[21:02] Telnet connection: proxyscan.freenode.net/50572
[21:02] -NickServ (NickServ@services.)- This nickname is registered. Please choose a different nickname, or identify via /msg NickServ identify <password>.
[21:02] net: connect! sock 14
[21:02] net: eof!(write) socket 14 (Connection refused,111)
[21:02] Timeout/EOF ident connection
[21:02] net: connect! sock 7
[21:02] DNS resolved 85.190.0.3 to proxyscan.freenode.net
[21:02] Telnet connection: proxyscan.freenode.net/41162
[21:02] net: connect! sock 15
[21:02] net: eof!(write) socket 15 (Connection refused,111)
[21:02] Timeout/EOF ident connection
[21:02] net: eof!(read) socket 13
[21:02] Lost telnet connection to telnet@proxyscan.freenode.net/50572
[21:02] net: eof!(read) socket 14
[21:02] Lost telnet connection to telnet@proxyscan.freenode.net/41162
:?
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

Your eggdrop uses a registered nickname, and nickserv is complaining and either changing it's nick, or simply killing it.
Start with trying a different nickname.
NML_375
s
shellx
Voice
Posts: 9
Joined: Thu Mar 12, 2009 9:49 pm

Post by shellx »

nml375 wrote:Your eggdrop uses a registered nickname, and nickserv is complaining and either changing it's nick, or simply killing it.
Start with trying a different nickname.
I try on my network, but does not work. Eggdrop can't connect to server and can't telneting :cry:
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

Please refrain from bumping! (I will remove the bump-post this time).

Regarding your last post, do you get any error messages or logs?
Were you running it in foreground (using -n or -nt)?

The post you made earlier suggests it fully capable of connecting to freenode.net when running in foreground. This suggests you are either suffering from network issues (routing tables, firewall rules, etc), or a known issue with Tcl8.5 and threads. If you do as I suggested, changing the nickname and starting it in foreground - do you see it coming online and responding?
NML_375
s
shellx
Voice
Posts: 9
Joined: Thu Mar 12, 2009 9:49 pm

Post by shellx »

nml375 wrote:Please refrain from bumping! (I will remove the bump-post this time).

Regarding your last post, do you get any error messages or logs?
Were you running it in foreground (using -n or -nt)?

The post you made earlier suggests it fully capable of connecting to freenode.net when running in foreground. This suggests you are either suffering from network issues (routing tables, firewall rules, etc), or a known issue with Tcl8.5 and threads. If you do as I suggested, changing the nickname and starting it in foreground - do you see it coming online and responding?
When ./eggdrop -n -m eggdrop.conf its works and i can connect to telnet, but when start with ./eggdrop -m eggdrop.conf can't connect to server and i can't telneting .. :?
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

Thank you.
Then you are suffering from the issue with threaded tcl.

The quickfix is as follows:
  • Download/unpack eggdrop source.
  • Run ./configure
  • Edit config.h, locate the HAVE_TCL_THREADS macro:

    Code: Select all

    /* Define for Tcl that has threads. */
    /* #undef HAVE_TCL_THREADS */
    Alter that into this:

    Code: Select all

    /* Define for Tcl that has threads. */
    #define HAVE_TCL_THREADS 1
  • Run make config
  • Run make
  • Run make install
If you'd like to know more about this issue, you'll find several threads regarding this in the forum. A search for "threaded tcl" should pick most of them.
NML_375
s
shellx
Voice
Posts: 9
Joined: Thu Mar 12, 2009 9:49 pm

Post by shellx »

Thank you very very very much nml375. :D
Post Reply