Page 1 of 1

Help please. Unable to connect to GitHub - specifying network gateway address

Posted: Sat Jul 18, 2020 7:50 am
by g3yjr
When I tried to upgrade the Portsdown software I was getting: "Unable to connect to GitHub to check the latest version".

In console mode, I went to the Linux command line. route -n showed no gateway address. I could ping my router on at 192.168.2.1 so the connection to my local private network was working, but pinging google at 172.217.169.3 failed.

I found a suggestion from Arpit Agarwal who suggested route add default gw 192.168.2.1 eth0. I found
sudo route add default gw 192.168.2.1 eth0 worked. route -n showed the gateway address. I tried a Portsdown software update & it worked fine.

So that gave me a work-around.

My problem is that the gateway address is lost again after a reboot. I've tried modifying the ip= command in the cmdline.txt file (see viewtopic.php?f=103&t=6742) to specify a gateway address, but I didn't get it to work.

How can I make my gateway address persist?

Graham

Re: Help please. Unable to connect to GitHub - specifying network gateway address

Posted: Sat Jul 18, 2020 8:16 am
by G4FRE
i have mine set set statically in :-

/etc/dhcpcd.conf

static routers=192.168.0.1
static domain_name_servers=192.168.0.1

which works fine and persists

Dave
g4fre

Re: Help please. Unable to connect to GitHub - specifying network gateway address

Posted: Sat Jul 18, 2020 5:37 pm
by g3yjr
I tried your suggestion, but it made no difference.

Then I tried removing my ip= command from /boot/cmdline.txt , in case it was overriding your commands, but still no joy.

Then I re-edited /etc/dhcpcd.conf so that it had the commands:

interface eth0
static ip_address 192.168.2.47
static routers=192.168.2.1
static domain_name_servers=192.168.2.1


route -n now shows I have a gateway!

This is probably all obvious to you. Not to me though.

Thank you for your prompt help Dave.

73 Graham