From nobody Wed Aug 17 14:24:46 2022 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4M79KJ33J1z4ZZhk for ; Wed, 17 Aug 2022 14:25:24 +0000 (UTC) (envelope-from miguelmclara@gmail.com) Received: from mail-oa1-x2a.google.com (mail-oa1-x2a.google.com [IPv6:2001:4860:4864:20::2a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4M79KH5grPz3QPL; Wed, 17 Aug 2022 14:25:23 +0000 (UTC) (envelope-from miguelmclara@gmail.com) Received: by mail-oa1-x2a.google.com with SMTP id 586e51a60fabf-11c4d7d4683so2137572fac.8; Wed, 17 Aug 2022 07:25:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=Ste+UwE3/Khmeiq2DYm8TQKa3ezL6gQCOuIyHKduykg=; b=A9SOYZ6jKvCqqecnZ8RD7+pDhQVigGo556sB3ggkOie1VcaySS4K2h40l+781Ehi0o /mUKwdK8ydYzDPS5ynZjD/f1GBgHX4/QQheLwuOwlCskaC8FG+Cg4tFl9/ul181u1hfM fQxlgwu3YW2MdzmksXLe+CCVnX4sCCeRd8a01cEFrPB5WjAjf0RsPB7ZEv1WEMXMLIBV +USThhqyOEVKLX42vMPWJDVykzl1ZcGJfwzH1hcqOC9bRK0hfiqQhRVsf7eAoXU4JybU tggHzK+0TpyI8UdExNIp07CFUVlumQYA+65GDvaRTTV7xtBJIPVcLqUCnm7ZG9ZxHug3 PvGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=Ste+UwE3/Khmeiq2DYm8TQKa3ezL6gQCOuIyHKduykg=; b=IgmkaNE1SRaK/ymoBjv+OaZPPdhf4FgZ96HQO6bQ36oPnMf2qK+DKNA0mSIAnTqtux OxClIu7SLG6JnupIEgcWYYSaklUJu8JQJVdGFzb9h3LiIYvH9mtkhuRuLFxx8ihnOQP1 EO0j35Zg8yGgtaWIfpjAq7CYwmmF4kl/aogDZsdg/E8M02SxlckULuywz5O2E6PbBvqk KYAECQcRK+PW8TNF5uzYSmIhgU/xirno3uD5b7QJKdxa11MclHnEg0866eZ+pxKZJqh8 aJb3wIZJZnNhL4N8thvmgMbG70aikX/JCzgsY6wGupyQLgrNkSP73faJ5qWm7ucx+ifj oX+Q== X-Gm-Message-State: ACgBeo3R7yaXwUf9NFQT1B58DInv8EOnapk5nzVWGNHjRYN8JiGX/vN+ +s2DinQxTzA/mkpuPvWP9rlMFXrRh4LgHWMCDIhDwx/PXcY= X-Google-Smtp-Source: AA6agR6Q4BmyXJ6Kw1g2bDPGuwb5hycHIuMzSEIRJRX9nAcSfF1QLyliR6kmZ5JL+CsbS47tIt3CF87Exj0aENsp8k8= X-Received: by 2002:a05:6870:d38c:b0:10e:daa7:da69 with SMTP id k12-20020a056870d38c00b0010edaa7da69mr1741706oag.61.1660746322495; Wed, 17 Aug 2022 07:25:22 -0700 (PDT) List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@freebsd.org MIME-Version: 1.0 References: In-Reply-To: From: Miguel C Date: Wed, 17 Aug 2022 15:24:46 +0100 Message-ID: Subject: Re: Windows Subsystem for FreeBSD? To: Nuno Teixeira Cc: FreeBSD CURRENT Content-Type: multipart/alternative; boundary="0000000000009d4e9205e670a2f2" X-Rspamd-Queue-Id: 4M79KH5grPz3QPL X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20210112 header.b=A9SOYZ6j; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of miguelmclara@gmail.com designates 2001:4860:4864:20::2a as permitted sender) smtp.mailfrom=miguelmclara@gmail.com X-Spamd-Result: default: False [-2.76 / 15.00]; SUBJECT_ENDS_QUESTION(1.00)[]; NEURAL_HAM_LONG(-0.99)[-0.994]; NEURAL_HAM_SHORT(-0.99)[-0.986]; NEURAL_HAM_MEDIUM(-0.78)[-0.779]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; R_SPF_ALLOW(-0.20)[+ip6:2001:4860:4000::/36:c]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20210112]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; FROM_EQ_ENVFROM(0.00)[]; ASN(0.00)[asn:15169, ipnet:2001:4860:4864::/48, country:US]; MID_RHS_MATCH_FROMTLD(0.00)[]; MLMMJ_DEST(0.00)[freebsd-current@freebsd.org]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ARC_NA(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; FROM_HAS_DN(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2001:4860:4864:20::2a:from]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_TLS_LAST(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; TO_DN_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-ThisMailContainsUnwantedMimeParts: N --0000000000009d4e9205e670a2f2 Content-Type: text/plain; charset="UTF-8" I've used it quite a bit on Windows since the early days. In WSL v1 it was pretty much what linuxolator is in FreeBSD, it was just emulation and translation of syscalls from linux to windows and it was mostly limited in the same way linux emulation is on FreeBSD in fact GUI wise I'de say it was much more limited since i.e one could not run GUI Linux apps on Windows or call Windows GUI apps on WSL, you couldn't even run services that require a network layer, like nginx mysql etc. However, it has evolved since and with WSL2 all of the above is possible, this is because they are using an approach similar to how docker runs on macOS, it's a lightweith Linux VM running the linux kernel, no need for syscall translation. I'm not sure if you mean bring this to FreeBSD as in Linux Subsystem as implemented here to FreeBSD or have WSL also run FreeBSD not just Linux. But the latter makes no sense, this would need to be done by Microsoft and I'm not quite sure if there's any advantage to them. However, if you mean to achieve the same level of linux compatibility, that would be quite interesting, I think linux emulation was always a great thing on FreeBSD but it was always limited in the same ways as WSL1. One of the advantage of having something like this might be finally getting docker on a FreeBSD host. This is after all how it works on macOS, and on recent versions its actually using apple's lightweight hypervisor aka "hypervisor.framework". And of course it would allow FreeBSD desktop users to run some software that only works on Linux but without the limitations of not being able to handle all miscalls. --0000000000009d4e9205e670a2f2 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I've used it quite a bit on Windows since the ear= ly days.

In WSL v1 it was pretty much what linuxol= ator is in FreeBSD, it was just emulation and translation of syscalls from = linux to windows and it was mostly limited in the same way linux emulation = is on FreeBSD in fact GUI wise I'de say it was much more limited since = i.e one could not run GUI Linux apps on Windows or call Windows GUI apps on= WSL, you couldn't even run services that require a network layer, like= nginx mysql etc.

However, it has evolved sinc= e and with WSL2 all of the above is possible, this is because they are usin= g an approach similar to how docker runs on macOS, it's a lightweith Li= nux VM running the linux kernel, no need for syscall translation.

I'm not sure if you mean bring this to FreeBSD as in Li= nux Subsystem as implemented here to FreeBSD or have WSL also run FreeBSD n= ot just Linux.

But the latter makes no sense, this= would need to be done by Microsoft and I'm not quite sure if there'= ;s any advantage to them.

However, if you mean to = achieve the same level of linux compatibility, that would be quite interest= ing, I think linux emulation was always a great thing on FreeBSD but it was= always limited in the same ways as WSL1.


One = of the advantage of having something like this might be finally getting doc= ker on a FreeBSD host. This is after all how it works on macOS, and on rece= nt versions its actually using apple's lightweight hypervisor aka &quo= t;hypervisor.framework". And of course it would allow FreeBSD desktop = users to run some software that only works on Linux but without the limitat= ions of not being able to handle all miscalls.



--0000000000009d4e9205e670a2f2--