CLion 2019.2.1 toolchain: WSL not found - clion

I installed Ubuntu through the Windows store and then followed the Jetbrains CLion/WSL setup guide here: https://www.jetbrains.com/help/clion/how-to-use-wsl-development-environment-in-clion.html
However after following that guide I was still an error in CLion saying "WSL not found"
I tried restarting CLion but that didn't fix it.
I verified WSL works fine on my PC:
CLion version information:
CLion 2019.2.1
Build #CL-192.6262.62, built on August 21, 2019
Runtime version: 11.0.3+12-b304.39 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Windows 10 10.0
GC: ParNew, ConcurrentMarkSweep
Memory: 1987M
Cores: 8
Registry: run.processes.with.pty=TRUE
Non-Bundled Plugins:
Windows version: Microsoft Windows [Version 10.0.16299.1331]
I found this related question but unfortunately repair/reset didn't work for me CLION: WSL not found, ssh connected?

All you need is to delete deprecated option from /etc/ssh/sshd_config, change ListenAddress to 0.0.0.0, learn your WSL IP (hostname -I) and change localhost to it in CLion toolchain config.
For this you need to:
Open WSL terminal
su
Enter windows user password
nano /etc/ssh/sshd_config
Scroll to the bottom
Delete line 126 (those deprecated)
Change ListenAddress 127.0.0.1 to ListenAddress 0.0.0.0
ctrl+o, cntrl+x
service ssh restart
hostname -I
Copy IP
In CLion > Settings > Buil & Debug > toolchains > WSL change localhost to copied IP
Note that this IP usually changes after reload. Use this tool to fight it https://github.com/shayne/go-wsl2-host

Related

Qemu Sparc64 emulation - keyboard doesn't work (Windows, Ubuntu host tested)

people
I need to run sparc64 emulator in order to install Solaris 10 for sparc64. I tried to run it on following hosts:
Windows 10 Professional
Windows 10 Enterprise
Windows Server 2019 Datacenter
Ubuntu 21.04
Ubuntu 18.04 LTS (ran on Windows hosted Hyper-v)
Every time I get this:
Keyboard is not responsive and I can not continue.
You can also view that i8042 module used for the keyboard is not available.
Can someone help with how to enable keyboard (it is not usb keyboard, it is integrated - on notebook - used for all except for Win Server)?
The starting command for qemu is (minimalistic):
qemu-system-spark64 -cdrom sol-10-u11-ga-sparc-dvd.iso -drive file=Image.img -m 2G -boot d

How do I open a wsl workspace in VS Code for a different distro?

I have both Ubuntu and Debian installed for WSL. When I open a WSL workspace using VS Code remote development, it always opens Ubuntu. How can I open a workspace under the Debian install using WSL in VS Code?
The VS Code Remote - WSL extension always uses the default WSL distro. You can change the default distro using the wsl command (wslconfig on earlier windows versions):
# List the available distributions
wsl --list
# Set the default version to debian
wsl --setdefault debian
After changing the default for WSL, make sure to restart VS Code
Click the "remote button" in the bottom left
Choose New Window using Distro...
Pick your distro!

Excpetion when installing gofabric8 in Windows Subsystem for Linux

In my system I have enabled the Windows Subsystem for Linux(WSL) and installed Ubuntu on Windows 10.
https://github.com/fabric8io/fabric8-platform/blob/master/INSTALL.md
On top of the WSL, I was trying to install the fabric8 from the scratch with the Minishift using instructions for Ubuntu in the above link and while running the below command, getting error stating that "No User home environment variable found for os windows"
gofabric8 start --minishift --package=system --namespace fabric8
Note: Before running the above commands, I have setup libvirt and qemu-kvm in my WSL
I had the same problem installing fabric8 on Windows. A look into the sourcecode reveals, you need to define a HOME environment variable. In windows CMD try
set HOME=C:\Users\yourHome
That worked for me

Cannot load modules/mod_ssl.so into server

I'm trying to set SSL to my localhost server with WAMP. (https://localhost)
I followed this Youtube course:
https://www.youtube.com/watch?v=TH6evGKgy20
But finally, I got this error by running "httpd -t" command in Apache folder:
D:\Programs\wamp3\bin\apache\apache2.4.17\bin> httpd -t
httpd: Syntax error on line 173 of D:/Programs/wamp3/bin/apache/apache2.4.17/conf/h
ttpd.conf: Cannot load modules/mod_ssl.so into server: The operating system cannot
run %1.
What's the problem?
The problem was OpenSSL version.
I was installed Win 32 version before, but I should install Win64 OpenSSL v1.0.2j Light (from here). Also, "Copy DLLs to Windows System directory" option must be checked in the installation wizard.
After installing it, everything worked correctly!
I'd a problem with running mod_ssl on simply oldest Apache/2.4.41 version on Windows Server 2016, witch perfect works on Windows 10 Pro. Fix solution for WS2016 consist in updating to the new Apache/2.4.43 or copying mod_ssl.so from Apache/2.4.43 to Apache/2.4.41 modules.
Note: that Update httpd 2.4.41 with OpenSSL 1.1.1.e! Make sure the run time variable OPENSSL_CONF is set. Be sure you installed latest Visual C++ Redistributable for Visual Studio 2015-2019

How to initialize and run Docker on windows?

I have Docker installed on Windows 7 platform. However when I try to run boot2docker start, the console gives me:
Failed to get machine 'boot2docker-vm': machine does not exist.
Ok, so I try to initialize the machine: boot2docker init. What now happens is even though I have the ISO image on the same path as docker, it tries to download a new image (and then fails to do so).
I uninstalled both OracleVM and GIT before installing them with boot2docker bundle as advised on Docker forums, but now I don't know how to proceed.
I had the same problem on a Windows 7 64 bit system when I installed the entire boot2docker package. It seems that running the solely 64-bit based boot2docker image from a 32-bit OS image (e.g. created by Virtualbox) does not work.
The solution for me was
to activate Intel Virtualisation Technolologies in my BIOS
(Lenovo X61 for me). Note that the settings can be found either
under CPU or Security.
choose a 64 bit OS version in VirtualBox and boot in with the
image obtained by boot2docker.
In case you're trying to do this now
For Windows 10 64-bit: Pro, Enterprise, or Education (Build 15063 or later), follow the instructions to install Docker Desktop here https://docs.docker.com/docker-for-windows/install/.
If you have Windows systems that do not meet the requirements of Docker Desktop for Windows(in my case Microsoft Windows 10 Home Single Language), you can install Docker Toolbox by following the instructions here https://docs.docker.com/toolbox/toolbox_install_windows/.
boot2docker does not support sharing directories on Windows IIRC. The way I run Docker on windows is:
install VirtualBox
install Vagrant
create a directory (let's say c:\vm\docker)
download this Vagrantfile and save it under c:\vm\docker\Vagrantfile
open a DOS command prompt
go to the directory cd c:\vm\docker
start the VM vagrant up and wait for it to install, start up and get provisionned
connect to the VM vagrant ssh
play with docker docker images, etc
Also you might want a real console instead of using the DOS command prompt:
install Git Bash for Windows
install Console
setup Console to use Git Bash (see this guide)
use Console to run the vagrant up and vagrant ssh commands

Resources