Lnd: Problem with Golang installation documentation for Linux

Created on 18 Jun 2018  路  5Comments  路  Source: lightningnetwork/lnd

Background

The instructions to install golang fail for me

Your environment

  • version of lnd
    NA

  • which operating system (uname -a on *Nix)
    Linux thundroid 4.14.47-132 #1 SMP PREEMPT Sun Jun 3 22:33:16 UTC 2018 armv7l armv7l armv7l GNU/Linux

  • version of btcd, bitcoind, or other backend
    NA

  • any other relevant environment details
    (following along with this tutorial)

Steps to reproduce

apt can't find the golang-1.10-go package:

admin@thundroid:~/download$ sudo apt-get install golang-1.10-go
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package golang-1.10-go
E: Couldn't find any package by glob 'golang-1.10-go'
E: Couldn't find any package by regex 'golang-1.10-go'

I fixed by adding the ppa:gophers/archive according to golang wiki instructions:

$ sudo add-apt-repository ppa:gophers/archive
$ sudo apt-get update
$ sudo apt-get install golang-1.10-go

Expected behaviour

Install golang

Actual behaviour

Doesn't install golang

Most helpful comment

It's still clearly in the install instructions to type in the command as-is. It should be changed to reflect that you have to do something more than just that. Makes it easy for newbies.

EDIT: adding this would solve it for Ubuntu users (most common):

sudo add-apt-repository ppa:longsleep/golang-backports
sudo apt-get update
sudo apt-get install golang-1.11-go

All 5 comments

Well it depends on your distro. We also link _directly_ to the official golang instructions as well, as a fall back, as some distros may not have that proper pacakge.

I ran into the same problem:

Me:~$ sudo apt-get install golang-1.11-go
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package golang-1.11-go
E: Couldn't find any package by glob 'golang-1.11-go'
E: Couldn't find any package by regex 'golang-1.11-go'

And would suggest to replace the guide with

$ sudo apt-get install golang-go

as per golang wiki

The reason we don't use that command is that is isn't guaranteed to install the _latest_ version of Go which we currently require.

It's still clearly in the install instructions to type in the command as-is. It should be changed to reflect that you have to do something more than just that. Makes it easy for newbies.

EDIT: adding this would solve it for Ubuntu users (most common):

sudo add-apt-repository ppa:longsleep/golang-backports
sudo apt-get update
sudo apt-get install golang-1.11-go

Thank you this helped me on my Ubuntu install

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Roasbeef picture Roasbeef  路  3Comments

alec-djinn picture alec-djinn  路  3Comments

AnthonyRonning picture AnthonyRonning  路  3Comments

hxsquid picture hxsquid  路  3Comments

sunnya97 picture sunnya97  路  3Comments