While installing Homebrew, connection failed error comes up when run this command " sudo apt-get install build-essential". What to do about it? - homebrew

I am just starting with web3 development. I have installed WSL. Then I opened Ubuntu and installed Homebrew. When the installation is almost complete it asks for next steps which is providing the path and installing the dependencies. After providing the path when I ran this command "
sudo apt-get install build-essential" it gave me connection failed error as shown in the pic.
Then I turned Windows Defender off and tried again but didn't work.
Then I tried to paste the same url in my browser but it didn't work. My guess is that url is different or wrong, but I don't know.
I also tried running this command "sudo apt-get update" but it also gives the same error.
Same error with this as well "sudo apt-get install build-essential procps curl file git"
Any idea what to do about this?
Note:- Just wanted to let you know that When I check "brew -version" it shows me my version 3.4.11. And my Ubuntu version is 20.04.

Related

OpenCV error zlib.h: no such file or directory

I am trying to follow this website to install opencv4 on Ubuntu 18.04.
https://www.learnopencv.com/install-opencv-4-on-ubuntu-18-04/
But I get this error after make
In file included from /home/gosztolai/opencv/3rdparty/libpng/pngpriv.h:913:0,
from /home/gosztolai/opencv/3rdparty/libpng/png.c:14:
/home/gosztolai/opencv/3rdparty/libpng/pngstruct.h:30:10: fatal error: zlib.h: No such file or directory
#include "zlib.h"
I tried sudo apt install zlib1g-dev but the system says that it is already isntalled
Could someone help what is going on?
libpng uses the zlib library for image compression. To install it in Ubuntu, run the following code in your bash terminal:
sudo apt-get install zlib1g-dev
But because you already have it installed, and need a newer version, you need to update the library. Try to upgrade your packages, using this code:
sudo apt update
sudo apt upgrade -y
Or you can try to remove it using apt and install again.

Unable to install Phusion Passenger on Ubuntu Server 18.04

Running on a fresh install of Ubuntu Server 18.04 on Virtualbox, Windows 10 as the host OS. Ran the instructions on the Phusion Passenger site here
This is the error I'm getting:
steve#heartypet-staging:~$ sudo apt-get install -y libnginx-mod-http-passenger
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
libnginx-mod-http-passenger : Depends: passenger (= 1:5.3.4-1~bionic1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Oddly enough, the exact same instructions work fine on the desktop version.
Get default source list from here
https://askubuntu.com/a/1036749
Replace /etc/apt/source.list with the file in the link above.
Then sudo apt update and sudo apt upgrade
And go ahead...
If you having problems with the previous solution, one option is run this command:
sudo nano /etc/apt/sources.list.d/passenger.list
and comment all the lines in this file, then run the command
sudo apt-get install passenger

Can't locate 'hdf5.h' during test

I tried to install the HDF5 library. I followed this guide Install_HDF5. In particular, I used:
sudo apt-get install libhdf5-serial-dev
sudo apt-get install libhdf5-mpich-dev
sudo apt-get install libhdf5-openmpi-dev
Up to this moment all the installations were successful. I tried to test it (make test) still following the guide, but I get:
fatal error hdf5.h no such file or directory
Could it concern a problem with my ~/.bashrc, i.e. with some missing path to hdf5?
P.S. I tested the Python module of HDF5 and it is working. I only received a warning message that I got rid of by using:
sudo python2.7 -m pip install git+https:://github.com/h5py/h5py.git --upgrade

Install td-agent (treasure data fluentd) on ubuntu 16.04

From http://docs.fluentd.org/v0.12/articles/install-by-deb, I can only find the instructions to install td-agent 2.3.5 where as I need to install td-agent 2.3.4 as there are some plugins which I needed tested only on 2.3.4.
I looked at the sources list /etc/apt/sources.list.d/treasure-data.list and also https://td-agent-package-browser.herokuapp.com/2/ubuntu/, but couldn't figure out how to get this version installed.
Can you please someone help on how to install td-agent 2.3.4?
Found the packages at https://td-agent-package-browser.herokuapp.com/2/ubuntu/trusty/pool/contrib/t/td-agent
and could able to install the old version with these instructions
sudo dpkg -i /tmp/td-agent_2.3.4-0_amd64.deb
sudo apt-get install -f

Installing ruby sudo make command not found (Vagrant, Virtualbox)

I am trying to get a development environment up and running. I installed virtualbox and then used vagrant with the hashicorp/precise32 box. I access the VM through ssh and am trying to install the latest version of ruby.
I pasted
wget -O ruby-install-0.5.0.tar.gz https://github.com/postmodern/ruby-install/archive/v0.5.0.tar.gz
tar -xzvf ruby-install-0.5.0.tar.gz
cd ruby-install-0.5.0/
sudo make install
into the command line from https://github.com/postmodern/ruby-install#readme
The prompt shows sudo make install and when I hit enter I get a message that says "sudo: make: command not found."
What am I doing wrong?
I know there are boxes with ruby already setup but I wanted to go through the process myself so learn a bit along the way.
A separate issue I came across was that this box has an outdated version of ubuntu. When I try to upgrade it warns me not to do it over SSH. Is there a better way?
Thanks
Maybe you don't have make installed on Ubuntu. You can install the package build-essential which will install make and other building tools.
sudo apt-get install build-essential
also, here's a good reference on installing Ruby, Ruby on Rails, and other tools on Ubuntu.

Resources