docker Error with pre-create check: "We support Virtualbox starting with version 5 - docker

I'm trying to create docker machine host using the following command in fedora OS version 25.
docker-machine create -driver=virtualbox host01
I get below error while executing the command.
Error with pre-create check: "We support Virtualbox starting with version 5. Your VirtualBox install is \"WARNING:
The vboxdrv kernel module is not loaded.
Either there is no module available for the current kernel (4.10.12-200.fc25.x86_64) or it failed to load.
Please try load the kernel module by executing as root
dnf install akmod-VirtualBox kernel-devel-4.10.12-200.fc25.x86_64 akmods --kernels 4.10.12-200.fc25.x86_64 && systemctl restart systemd-modules-load.service
You will not be able to start VMs until this problem is fixed.\\n5.1.26r117224\".
Please upgrade at https://www.virtualbox.org"
I have already virtualbox latest version installed. Running the command suggested by
sudo dnf install akmod-VirtualBox kernel-devel-4.10.12-200.fc25.x86_64 akmods --kernels 4.10.12-200.fc25.x86_64 && systemctl restart systemd-modules-load.service
I got the below error
Last metadata expiration check: 0:48:35 ago on Thu Aug 17 22:38:47 2017.
Package akmods-0.5.6-7.fc25.noarch is already installed, skipping.
No package --kernels available.
No package 4.10.12-200.fc25.x86_64 available.
Any suggestions?

I also had this problem and for this I upgrade Virtual box to 5.2 using following commands. This link help me
sudo apt-get remove virtualbox virtualbox-5.1
sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian xenial contrib" >> /etc/apt/sources.list.d/virtualbox.list'
wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | sudo apt-key add -
wget -q https://www.virtualbox.org/download/oracle_vbox.asc -O- | sudo apt-key add -
sudo apt-get update
sudo apt-get install virtualbox-5.2
Hope this helps.

For windows users, in 2022 such problem still exists. So for those who use last build (now it is virtualBox-6.1.32-149290-Win), try to use version that starts with prefix 5. But not all '5' versions work. For example, for me worked only version 5.2.42 while versions: 5.2.18, 5.2.20, 5.2.44 didn't work
Helped for win 11 x64

Related

How do I install erlang OTP 25 on ubuntu?

I am trying to install erlang 25 (and elixir 1.13) on my ubuntu VM, but the default version installed by apt is erlang 24.
I've tried both :
sudo wget https://packages.erlang-solutions.com/erlang-solutions_1.0_all.deb && sudo dpkg -i erlang-solutions_1.0_all.d
sudo apt update
and
sudo wget https://packages.erlang-solutions.com/erlang-solutions_2.0_all.deb && sudo dpkg -i erlang-solutions_2.0_all.d
sudo apt update
but in both case, running apt-cache policy esl-erlang didn't show the desired version. I have recently installed erlang 25 on a identical vm, and I don't remember struggling at all, so I'm guessing there's a simple way of doing it that I just forgot ?
I hope you can help me, thank you !
From the Erlang OTP repo, you should do:
apt-get install erlang
If you decide to compile from source:
git clone https://github.com/erlang/otp.git
cd otp
git checkout maint-25 # current latest stable version
./configure
make
make install
Alternatively, you can use Kerl:
curl -O https://raw.githubusercontent.com/kerl/kerl/master/kerl
chmod a+x kerl
and place kerl in your PATH so that you can invoke it from the terminal (remember to source your .bashrc or similar if you update your PATH variable there, or open a new terminal to reload the PATH env), i.e.,
export PATH=<path-to-kerl>:$PATH
Instructions on how to use it here.
I would recommend the usage of the Erlang Version Manager, thanks to which you can compile and install any Erlang OTP version you need, regardless of what the default version is currently available for your Linux distro.
Installation of Erlang Version Manager:
$ git clone https://github.com/robisonsantos/evm /tmp/evm/
$ cd /tmp/evm/
$ /tmp/evm/install
$ echo 'source ~/.evm/scripts/evm' >> ~/.bashrc
$ bash
Installation of the specific Erlang OTP version:
$ evm install 25.1.1 -y
$ evm default 25.1.1

Can't find any man pages in Fedora Docker Image

After installing the man pages via dnf, I still can't find them inside /usr/share/man.
docker run --rm -it fedora bash -c "dnf install -y man-pages && ls -lR /usr/share/man"
Did I miss something?
The default configuration for the docker version of fedora disable the installation of documentation.
cat /etc/dnf/dnf.conf
Check out the last line :
[main]
gpgcheck=1
installonly_limit=3
clean_requirements_on_remove=True
best=False
skip_if_unavailable=True
tsflags=nodocs
However, it is still possible to change the last line or override it like below command :
dnf install -y man-pages --setopt='tsflags='
I would liked to contribute as I was looking for the answer and I found the answer, from the link here
Confirm the below line is removed from /etc/dnf/dnf.conf
tsflags=nodocs
and remove and reinstall the man pages using dnf
dnf install man man-pages man-db

Docker: Openjdk:14 RHEL based imaged, cannot install yum/wget/netstat

In my dockerfile, I need a maven builder (3.6 at least) working on a OpenJDK (J14 is required).
FROM maven:3.6.3-openjdk-14 as builder
The problem is simple: I need netstat command because it is used in several scripts. The OpenJDK official image is RHEL based, so it comes without any of this package installed.
I tried to download it or yum via wget command but, as you can guess, it is not installed. I feel trapped because it seems like you cannot you can't install any package on it.
That image is actually based on Oracle
$ podman run -it maven:3.6.3-openjdk-14 /bin/bash -c 'cat /etc/os-release'
NAME="Oracle Linux Server"
VERSION="8.2"
ID="ol"
ID_LIKE="fedora"
VARIANT="Server"
VARIANT_ID="server"
VERSION_ID="8.2"
PLATFORM_ID="platform:el8"
PRETTY_NAME="Oracle Linux Server 8.2"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:oracle:linux:8:2:server"
HOME_URL="https://linux.oracle.com/"
BUG_REPORT_URL="https://bugzilla.oracle.com/"
ORACLE_BUGZILLA_PRODUCT="Oracle Linux 8"
ORACLE_BUGZILLA_PRODUCT_VERSION=8.2
ORACLE_SUPPORT_PRODUCT="Oracle Linux"
ORACLE_SUPPORT_PRODUCT_VERSION=8.2
And this is actually a "slim" variant where dnf or yum aren't installed, but microdnf is. Try using that, instead:
RUN microdnf install /usr/bin/netstat
Or
RUN microdnf install net-tools

WSL: Can't install docker on WSL 2, Ubuntu 18.04

I've searched lots of related posts on here and other site but anything didn't solve my problem.
As mentioned on title I'm struggling to install docker on linux subsystem on window OS
I'm with win 10 home edition so I've already installed Docker tool box, and my wsl is version 2 with Ubuntu 18.04
I was following the instructions and everything was fine until I did:
~$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
gpg: can't connect to the agent: IPC connect call failed
Is there anyone who had same difficulty but solved this problem?
Thank you in advance!
The issue is because of a real-time clock issue with the Glibc library under the WSL v1 setup. WSL v2 may fix this under the hood and you may not run into the issue in future.
Now you can fix Glibc manualy:
$ sudo add-apt-repository ppa:rafaeldtinoco/lp1871129
$ sudo apt update
$ sudo apt install libc6=2.31-0ubuntu8+lp1871129~1 -y
$ sudo apt-mark hold libc6
//Remove "-y" if needed on above step #3.
//And when asked, give "y" and hit enter.
The above set of commands will add the latest version of the Glibc library and put the stable library on hold, until needed to reenable.
You can track this issue https://github.com/microsoft/WSL/issues/5125

Integrating InfluxDB with ONOS

I have followed all the steps in https://wiki.onosproject.org/display/ONOS/InfluxDB+Report+and+Query+Application , but I can't integrate ONOS with InfluxDB.
After configuring all that's in the documentation, I execute "SHOW MEASUREMENTS" in InfluxDB and nothing is showing, because the database I created is empty, ONOS does not publish the metrics in it.
Is there anything any configuration file I must edit in order to run correctly?
Thank you so much for your help.
I tried the documentation, it has some missing information. Here is what i did:
My OS is Ubuntu:
yavuz#ubuntu:/opt/onos/apache-karaf-3.0.8/data/log$ uname -a
Linux ubuntu 4.4.0-83-generic #106-Ubuntu SMP Mon Jun 26 17:54:43 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
I've installed influxdb version 0.10.0
Note that ONOS supports InfluxDB up to 0.10.3. The InfluxDB which has
higher version number will not work properly with ONOS.
curl -sL https://repos.influxdata.com/influxdb.key | sudo apt-key add -
source /etc/lsb-release
echo "deb https://repos.influxdata.com/${DISTRIB_ID,,} ${DISTRIB_CODENAME} stable" | sudo tee /etc/apt/sources.list.d/influxdb.list
sudo apt-get update
sudo apt-get install influxdb=0.10.0+dfsg1-1
sudo service influxdb start
sudo apt-get install influxdb-client
Create onos database on influx
yavuz#ubuntu$ influx
Visit https://enterprise.influxdata.com to register for updates, InfluxDB server management, and monitoring.
Connected to http://localhost:8086 version 0.10.0
InfluxDB shell 0.10.0
CREATE DATABASE onos
use onos
CREATE USER onos WITH PASSWORD 'onos.password' WITH ALL PRIVILEGES
Now, influxdb is ready. Then, I installed ONOS 1.10.2:
cd /opt
sudo wget -c http://downloads.onosproject.org/release/onos-1.10.2.tar.gz
sudo tar xzf onos-1.10.2.tar.gz
sudo mv onos-1.10.2 onos
sudo /opt/onos/bin/onos-service start
Be sure to run ONOS with sudo, otherwise influxdb gives permission
errors.
After getting ONOS console install influxdb feature: (this is missed in documentation)
feature:install onos-apps-influxdbmetrics
Activate application
app activate org.onosproject.influxdbmetrics
Last trick, default influxdb address is localhost and it causes parsing errors, you can set this value to 127.0.0.1
cfg set org.onosproject.influxdbmetrics.InfluxDbMetricsConfig address 127.0.0.1
You can tail the karaf.log to control if an error occurs during these steps. After few seconds, here is the query result
Hope this helps.

Resources