egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

two connections available - how to set up the used one?

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Eggdrop Help
View previous topic :: View next topic  
Author Message
desired
Voice


Joined: 12 Sep 2011
Posts: 31

PostPosted: Tue Sep 13, 2011 12:57 pm    Post subject: two connections available - how to set up the used one? Reply with quote

I have two ways to connect to the internet available (WiFi and GPRS).

How can I tell the eggdrop, which connection it shall use?

At the moment it uses WiFi and GPRS as a fallback if WiFi isn't available. This isn't very good, because I turn off my router while I am not on PC, so the bot always loses connection...

I also dislike to turn off WiFi permanently, because I need it for some other stuff...

Would be better if the bot would always use GPRS. (Data quota is not a problem, I have unlimited GPRS. Connection speed and ping seams also good enough.)

Just need to tell the bot, which connection it shall use. How can I do so?
_________________
eggdrop running on Android powered mobile phone - Yes, it is possible! - Very reliable.
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2853

PostPosted: Tue Sep 13, 2011 1:45 pm    Post subject: Reply with quote

Use the "my-ip" setting, and set it to the IP of the interface you'd like to use. Be adviced that your eggdrop will only use this IP, while it's set, regardless of the GPRS-link state.
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
desired
Voice


Joined: 12 Sep 2011
Posts: 31

PostPosted: Tue Sep 13, 2011 4:38 pm    Post subject: Reply with quote

I'll show you the output of ifconfig.

Code:
lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:11 errors:0 dropped:0 overruns:0 frame:0
          TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:1331 (1.2 KiB)  TX bytes:1331 (1.2 KiB)

wlan0     Link encap:Ethernet  HWaddr 30:17:c8:be:5c:af
          inet addr:192.168.2.100  Bcast:192.168.2.255  Mask:255.255.255.0
          inet6 addr: fe80::3217:c8ff:febe:5caf/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:47950 errors:0 dropped:0 overruns:0 frame:0
          TX packets:27540 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:27053868 (25.8 MiB)  TX bytes:5472117 (5.2 MiB)


Started eggdrop with -n (this does normally work, with -n and without, -n just for debugging) and set my-ip to 127.0.0.1.
Code:

[20:26] main: entering loop
[20:26] Trying server irc.quakenet.org:6667
[20:26] Failed connect to irc.quakenet.org (Invalid argument)
[20:26] net: connect! sock 11
[20:26] net: eof!(read) socket 11
[20:26] (@) EOF socket 11, not a dcc socket, not anything.

As I expected, set my-ip 127.0.0.1 does not work at all.

set my-ip 192.168.2.100 does work but then it's WiFi with GPRS as fallback, not like I wanted.

My worry is, that the underlying Android system (which is also based on linux) does decide which connection will be used. The rmnet0 adapter, I can only see in ifconfig, if WiFi is disabled.

Any idea?
_________________
eggdrop running on Android powered mobile phone - Yes, it is possible! - Very reliable.
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2853

PostPosted: Tue Sep 13, 2011 5:18 pm    Post subject: Reply with quote

I'm not that at home with Android, though it sounds reasonable that the system won't bring up the GPRS connection for as long as the WiFi connection is still alive. I don't suppose you could simply "ifup rmnet0" ?
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
desired
Voice


Joined: 12 Sep 2011
Posts: 31

PostPosted: Tue Sep 13, 2011 6:16 pm    Post subject: Reply with quote

nml375 wrote:
I don't suppose you could simply "ifup rmnet0" ?

Says "ignoring unkown interface rmnet0=rmnet0".

But was a great idea! I wasn't aware of that function.

I guess ifup does not work, because the underlying Android is not debian.

Somehow it must be possible to activate that interface. I just need to find out how.
_________________
eggdrop running on Android powered mobile phone - Yes, it is possible! - Very reliable.
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2853

PostPosted: Tue Sep 13, 2011 6:32 pm    Post subject: Reply with quote

Well, since GPRS/UMTS-connections are established using the standard Point-to-Point Protocol, as long as you can find all the dialling parameters, you could always start pppd manually.
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
desired
Voice


Joined: 12 Sep 2011
Posts: 31

PostPosted: Fri Sep 30, 2011 11:16 pm    Post subject: Reply with quote

nml375 wrote:
Well, since GPRS/UMTS-connections are established using the standard Point-to-Point Protocol, as long as you can find all the dialling parameters, you could always start pppd manually.


Could you help me with that please?

So far I found no one on google who created his own pppd connection using Android.

I even have no idea how to find out the name of the device (modem), how?
_________________
eggdrop running on Android powered mobile phone - Yes, it is possible! - Very reliable.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Eggdrop Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber