DreamPi gets assigned an IP but cannot connect to the internet

Online games, how to get online, and anything involving Dreamcast online can be discussed here.
bconnolly
noob
Posts: 3

DreamPi gets assigned an IP but cannot connect to the internet

Post by bconnolly »

RPI Model: 3b+
Modem Model: Conexant USB modem from Dreamcast-Live shop.
Disk Image: DreamPi 1.7
Networking Configuration: wireless

Steps taken so far: Formatted the SD card as FAT32 and imaged with Win32 Disk Imager. After first boot-up, ran the wificonfig utility to connect to wireless network.

Problem: When I boot the RPI, it gets assigned an IP address but seemingly cannot connect to the internet. The left LED on the modem lights up but the right LED never turns on. From the bash prompt on the RPI, I am unable to ping or traceroute to any named URL but I can ping IP addresses like 8.8.8.8 with no issues.

I first noted the following error on start-up:

Code: Select all

Failed to start dhcpcd on all interfaces
and if I interrogate further with "systemctl status dhcpcd.service" i'm met with this:

Code: Select all

Feb 07 21:29:47 dreampi systemd[1]: Starting dhcpcd on all interfaces...
Feb 07 21:29:47 dreampi dhcpcd[280]: Not running dhcpcd because /etc/network/interfaces
Feb 07 21:29:47 dreampi dhcpcd[280]: defines some interfaces that will use a
Feb 07 21:29:47 dreampi dhcpcd[280]: DHCP client or static address
Feb 07 21:29:48 dreampi systemd[1]: dhcpcd.service: Control process exited, code=exited status=6
Feb 07 21:29:48 dreampi systemd[1]: Failed to start dhcpcd on all interfaces.
Feb 07 21:29:48 dreampi systemd[1]: dhcpcd.service: Unit entered failed state.
Feb 07 21:29:48 dreampi systemd[1]: dhcpcd.service: Failed with result 'exit-code'.
Here is the contents of the /etc/network/interfaces file:

Code: Select all

                                 
auto wlan0
allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface default inet dhcp
dns-nameserver 127.0.0.1

manual eth0
allow-hotplug eth0
iface eth0 inet dhcp
dns-nameserver 127.0.0.1
And here is the output of "ifconfig" showing that it has an assigned IP:

Code: Select all

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 88  bytes 5920 (5.7 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 88  bytes 5920 (5.7 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.0.32  netmask 255.255.255.0  broadcast 192.168.0.255
        inet6 fe80::ba27:ebff:fe32:4209  prefixlen 64  scopeid 0x20<link>
        ether b8:27:eb:32:42:09  txqueuelen 1000  (Ethernet)
        RX packets 646  bytes 40566 (39.6 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 536  bytes 66227 (64.6 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        
I am able to successfully ssh into the RPI using "ssh [email protected]" as the connection method so I know it's getting onto the wifi network.

If i look at the syslog while it's running, it just loops this over and over again:

Code: Select all

Feb  7 21:35:10 dreampi Waiting for internet connection...
Feb  7 21:35:10 dreampi dreampi[419]: No internet connection
Feb  7 21:35:10 dreampi dreampi[419]: Traceback (most recent call last):
Feb  7 21:35:10 dreampi dreampi[419]:   File "/usr/local/bin/dreampi", line 50, in check_internet_connection
Feb  7 21:35:10 dreampi dreampi[419]:     socket.socket(socket.AF_INET, socket.SOCK_STREAM).connect((host, port))
Feb  7 21:35:10 dreampi dreampi[419]:   File "/usr/lib/python2.7/socket.py", line 228, in meth
Feb  7 21:35:10 dreampi dreampi[419]:     return getattr(self._sock,name)(*args)
Feb  7 21:35:10 dreampi dreampi[419]: error: [Errno 111] Connection refused
Feb  7 21:35:10 dreampi dreampi[419]: Waiting for internet connection...
Feb  7 21:35:13 dreampi dnsmasq[469]: query[A] 0.debian.pool.ntp.org.Home from 127.0.0.1
Feb  7 21:35:13 dreampi dnsmasq[469]: forwarded 0.debian.pool.ntp.org.Home to 46.101.91.123
Feb  7 21:35:13 dreampi dnsmasq[469]: query[AAAA] 0.debian.pool.ntp.org.Home from 127.0.0.1
Feb  7 21:35:13 dreampi dnsmasq[469]: forwarded 0.debian.pool.ntp.org.Home to 46.101.91.123
Feb  7 21:35:16 dreampi No internet connection#012Traceback (most recent call last):#012  File "/usr/local/bin/dreampi", line 50, in check_internet_connection#012    socket.socket(socket.AF_INET, socket.SOCK_STREAM).connect((host, port))#012  File "/usr/lib/python2.7/socket.py", line 228, in meth#012    return getattr(self._sock,name)(*args)#012error: [Errno 111] Connection refused
Feb  7 21:35:16 dreampi Waiting for internet connection...
Feb  7 21:35:16 dreampi dreampi[419]: No internet connection
Is there some step I'm missing? All the tutorials I've read just say to flash the card, pop it into the RPI and turn it on but I'm not experiencing that level of simplicity here.

User avatar
Xiden
Developer
Posts: 2229
Dreamcast Games you play Online: All the DC games!!

Re: DreamPi gets assigned an IP but cannot connect to the internet

Post by Xiden »

It should be as simple as flashing the image and popping it in the pi and connecting, so could be something in the wifi config thats wonky.

If you're using the wifi utility pc wrote i recommend checking this tread out

https://dreamcast-talk.com/forum/viewtopic.php?t=11686

Otherwise here is the manual config tutorial for wifi

https://youtu.be/F1kcZ_A92BY

Sometimes it may take a min for the 2nd light to turn on btw also if at all possible, its highly recommended to use ethernet for best gameplay experience. If the thread or video doesn't help if recommended sending a pm to pcwzrd13 as hes the expert on this :)

bconnolly
noob
Posts: 3

Re: DreamPi gets assigned an IP but cannot connect to the internet

Post by bconnolly »

I figured out the problem I was having almost immediately after this got approved for posting: I needed to enable DMZ for the RPI's IP address. Once I did that it immediately began to work. :)

User avatar
lozz
core
Posts: 123
Dreamcast Games you play Online: Phantasy Star Online, Quake III, Starlancer, 4x4 Evo, Maximum Pool, Sega Swirl.

Re: DreamPi gets assigned an IP but cannot connect to the internet

Post by lozz »

I'm not all that knowledgeable about these things, but I don't believe it is advisable to DMZ your Pi as this could leave it open to nefarious incoming traffic. You should only have to DMZ your Dreamcast's IP address. Xiden and the like may be able to follow-up and confirm/deny what I've said here. Good luck and stay safe!

User avatar
Londinium
dirty sailor
Posts: 183
Dreamcast Games you play Online: I'm up for anything

Re: DreamPi gets assigned an IP but cannot connect to the internet

Post by Londinium »

I remember a story from a few months ago where someone's Pi got screwed over, but I can't remember if they DMZed their Pi or something else.

Wasn't the user Cinnabyte?
ImageImageImageImageImageImageImageImageImage

User avatar
cbx
shadow
Posts: 12
Location: Germany

Re: DreamPi gets assigned an IP but cannot connect to the internet

Post by cbx »

I would have added a # in front of the first line with this:
dns-nameserver 127.0.0.1

Since the device gets an IP address, it should also get a DNS server, most-likely the router. DMZ has nothing to do with this. Another fix would be starting dnsmasq or check why it doesn't start because it's probably supposed to be the local DNS resolver hence the static assignment of 127.0.0.1.

bconnolly
noob
Posts: 3

Re: DreamPi gets assigned an IP but cannot connect to the internet

Post by bconnolly »

cbx wrote:I would have added a # in front of the first line with this:
dns-nameserver 127.0.0.1

Since the device gets an IP address, it should also get a DNS server, most-likely the router. DMZ has nothing to do with this. Another fix would be starting dnsmasq or check why it doesn't start because it's probably supposed to be the local DNS resolver hence the static assignment of 127.0.0.1.
I commented out the dns-nameserver line and rebooted it and it still does the same thing (RE: "no internet connections", only one light on the modem turns on) if I disable DMZ.

Ideally I wouldn't use DMZ for this but it was the only way I could get both lights on the modem to turn on.

Based on the error log I posted, it appears to be running dnsmasq, though? Isn't that what is generating the errors?

EDIT: Long story short, I futzed around with my modem (the router is built into it) so much that it stopped working and I had my provider reset it using their server-side tools and now all of it works without needing to mess with DMZ.

  • Similar Topics
    Replies
    Views
    Last post