Category Archives: Ubuntu

Installing Oracle Database 19.3 in a Docker container on Ubuntu Server 18.04

First I installed Ubuntu Server 18.04 as a Hyper-V machine on Windows 10.

While creating the virtual machine I selected Generation 1, because Generation 2 resulted in some strange effects.

Then I created a separate user with sudo permission:

sudo useradd -d /home/singh -m --shell "/bin/bash" singh
sudo passwd singh
sudo usermod -aG sudo singh
(more…)

Binding Docker container ports to the host on Ubuntu 18.04 inside Hyper-V on Windows 10

The binding did not work for me until I switched from Internal Virtual Switch to External Virtual Switch and while switching I were getting the following error:

[Window Title]
Virtual Switch Manager for MY-MACHINE

[Main Instruction]
Error applying Virtual Switch Properties changes

[Content]
Failed while adding virtual Ethernet switch connections.

[Expanded Information]
External Ethernet adapter 'Realtek PCIe GBE Family Controller' is already bound to the Microsoft Virtual Switch protocol.

until I switched Hyper-V Extensible Virtual Switch off on my network adapter properties page (after I created External Virtual Switch it switched on back):

(more…)

Timed out waiting for device dev-disk-by/… while booting Ubuntu 18.04 up.

My Ubuntu 18.04 installed in Windows 10 HyperV virtual machine stopped booting up with the following errors:

(more…)

Setting up time synchronization on Ubuntu

I followed the official Ubuntu time synchronization guide and installed chrony:

sudo apt update
sudo apt install chrony
cat /etc/chrony/chrony.conf
chronyc sources
chronyc sourcestats
sudo systemctl restart chrony.service
apt remove --autoremove chrony

(more…)

Setting up Ethereum node on Windows 10 and Ubuntu.

After a few attempts I was able to start Ethereum Mist 0.11.1 in ‘fast’ mode on Windows 10:

it downloaded ‘geth’, connected to {“path”:”\\\\.\\pipe\\geth.ipc”} and started to sync, but when sync finished I was unable to send transactions (they were ‘denied’ for some reason).

(more…)

Mining Ethereum on Ubuntu 18.04 with GeForce GTX 1060 3GB

I am not a Linux expert, so it took me some time to configure my mining rig on Ubuntu 18.04 with NVIDIA GeForce GTX 1060 3GB, and I wrote down all the steps I did:

First I installed NVIDIA driver, but OpenCL did not install automatically with it and I installed it manually with the following command:

sudo apt install -y ocl-icd-libopencl1

Then I installed CURL:

sudo apt install -y libcurl3

not ‘curl’ and not ‘libcurl4’ packages, otherwise the miner will fail to start reporting the following error message:

./ethdcrminer64: /usr/lib/x86_64-linux-gnu/libcurl.so.4: version `CURL_OPENSSL_3' not found (required by ./ethdcrminer64)

(more…)

PHP script that saves client IP address to a file.

Below I wrote down a simple PHP script that saves client IP address to a file. If the IP address of your home machine periodically changes, you can store it on a web server once a minute by scheduling a task like this:

sudo crontab -u <user> -e
* * * * * wget -q -O /dev/null -o /dev/null "https://yourwebsite.com/ip.php?rig=rig1&password=XXXXX"

where ip.php is the following PHP script:
(more…)

Setting up Squid proxy on Ubuntu 16.04 to browse blocked websites

Squid 3.5.12 can be installed and tested on Ubuntu 16.04 with the following commands:

sudo apt install squid
service squid start
sudo ufw allow 3128/tcp
wget -e use_proxy=yes -e http_proxy=http://localhost:3128 http://google.com

by default Squid listens on port 3128.

At first, Google Chrome started with Squid proxy from some external IP address:

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --proxy-server=http://developernote.com:3128

(more…)

Installing NVIDIA Driver on Ubuntu 16.04 and 18.04

I am not sure if there were NVIDIA drivers when I installed Ubuntu 16.01 on a machine with Intel processor and GTX 1060 graphic card, but at least I saw this in the terminal (it is not clear what actually FAILED):

(more…)

Configuring Postfix with Yandex.ru relay in Ubuntu 16.04

Today I read that Postfix can be better than sendmail and found a great Russian article on how to configure Postfix to work with Yandex.ru relay (Yandex.ru is some kind of Russian Google). The only notice I would give is that in a Docker container I need also install rsyslog, otherwise /var/log/mail.log file is not created:

apt install rsyslog

After doing all the steps described in this Russian manual I was able to send email to Yandex.ru and GMail accounts, but GMail landed all the emails to its spam folder. My first idea was that it is because I did not configure ‘from address’ correctly, so I had the following in /var/log/mail.log, and also there was a message ‘Cannot assign requested address‘:

Oct 27 11:36:19 0675c97b78aa postfix/pickup[1210]: 8C7ECE5B72: uid=0 from=<root>
Oct 27 11:36:19 0675c97b78aa postfix/cleanup[10786]: 8C7ECE5B72: message-id=<20171027113619.8C7ECE5B72@0675c97b78aa.localdomain>
Oct 27 11:36:19 0675c97b78aa postfix/qmgr[1211]: 8C7ECE5B72: from=<root@0675c97b78aa.localdomain>, size=405, nrcpt=2 (queue active)
Oct 27 11:36:19 0675c97b78aa postfix/smtp[10788]: connect to gmail-smtp-in.l.google.com[2a00:1450:400c:c09::1b]:25: Cannot assign requested address
...

(more…)