From nobody Wed Jan 25 23:54:03 2023 X-Original-To: freebsd-hackers@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 4P2LKv6c3Tz3bqWg for ; Wed, 25 Jan 2023 23:54:43 +0000 (UTC) (envelope-from marietto2008@gmail.com) Received: from mail-ej1-x632.google.com (mail-ej1-x632.google.com [IPv6:2a00:1450:4864:20::632]) (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 4P2LKt56ZNz4RmH for ; Wed, 25 Jan 2023 23:54:42 +0000 (UTC) (envelope-from marietto2008@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20210112 header.b=HqpXw207; spf=pass (mx1.freebsd.org: domain of marietto2008@gmail.com designates 2a00:1450:4864:20::632 as permitted sender) smtp.mailfrom=marietto2008@gmail.com; dmarc=pass (policy=none) header.from=gmail.com Received: by mail-ej1-x632.google.com with SMTP id v6so942537ejg.6 for ; Wed, 25 Jan 2023 15:54:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=qXdGT5iP1Rk0iD0yfCeRaOui424A3NEF72qMOhjnQRM=; b=HqpXw207ktIl+PEtM3I8xgP59TB/TuXgdMvmlhwg2YT1jspTN01q2A0oiXDDiOSV4Q Eft3ZgptFKpf58uZUtivTA8bVNsnKkaSrx4eH9kMVuW/f4fXwtG+/IUCgv4XEl7sL0i/ Jtuy0D4x2RYzZ472NDjMQrk/Ryor7dNHMLzcIXiwDF4g0S5+mCuAR0cmA/lbg/NkYh3n Wun5c2pw/x9r/WhJyYrkhTasEsN//1HdAv47uuIuhqqhxoDTMX2HcWyEmV97h9RVJ9/6 HUej8XzbEAnav+DZYyi2TZ+nAB83KoZ7JWs9L3BzYbSRKhF3xosyC/HEciJOzM8NCD6K UctA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=qXdGT5iP1Rk0iD0yfCeRaOui424A3NEF72qMOhjnQRM=; b=cvMMj12hZxOoW1ab1LGC92+7jdJIFyHmAaFNedXabPj2STL46Bm+TGw29NLm5PLOZG XU8EzvBm2ODyRpI2ifFF8zWiztuis+VhRE2DIM/4d2SXFqSeCwZAdKG8RhsyEVJZnENg rStYA4gFKhbD82mAF72RZbBBFFiJLARWS3pzJefXLlWH93KTJHXdiCI2VwyJSBtulOpC Nz5Q/1xnAMZPJ0Gv1SPCKaFfcatD2APxMjkICb5Xfw8g8n1iubmowhrGcvoptSNnXE31 Xi1pWri2KKOOuaR0ZGoO8d2sXEq5QiZp+hsNivJNmAij/uc2AyGY9EZ4cQ8oOO7vxXGt 66Qg== X-Gm-Message-State: AO0yUKUEPX5AypMvRPiVh5qF2jU3QPh1O0FbFx1t/9EsuhTeAzZq9flg c8ONo/wlRvSowFPkvXDlvh46GjIhaciBVCzypqXCZff18Y4= X-Google-Smtp-Source: AK7set89U8oJ1OeS31SF7ce+e37Q6Xz5yLmxrOEztyqfIV7ef7TMm+XAODCrZlNGU/ZtfhO4K40ueSTd9guqyyFjJ3E= X-Received: by 2002:a17:906:1653:b0:877:ec3a:ead0 with SMTP id n19-20020a170906165300b00877ec3aead0mr1045598ejd.74.1674690880432; Wed, 25 Jan 2023 15:54:40 -0800 (PST) List-Id: Technical discussions relating to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-hackers List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-hackers@freebsd.org MIME-Version: 1.0 References: In-Reply-To: From: Mario Marietto Date: Thu, 26 Jan 2023 00:54:03 +0100 Message-ID: Subject: Fwd: linux-miniconda-installer script usage and problems. To: freebsd-hackers@freebsd.org Content-Type: multipart/alternative; boundary="000000000000096f8805f31f5b4f" X-Spamd-Result: default: False [-3.27 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; NEURAL_HAM_SHORT(-0.27)[-0.274]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20210112]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36:c]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; ARC_NA(0.00)[]; MLMMJ_DEST(0.00)[freebsd-hackers@freebsd.org]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::632:from]; FROM_EQ_ENVFROM(0.00)[]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; FREEMAIL_ENVFROM(0.00)[gmail.com]; MID_RHS_MATCH_FROMTLD(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; FREEMAIL_FROM(0.00)[gmail.com]; FROM_HAS_DN(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_NONE(0.00)[]; RCVD_TLS_LAST(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim] X-Rspamd-Queue-Id: 4P2LKt56ZNz4RmH X-Spamd-Bar: --- X-ThisMailContainsUnwantedMimeParts: N --000000000000096f8805f31f5b4f Content-Type: text/plain; charset="UTF-8" Hello to everyone, I've been able to run the stable diffusion webui of automatic1111. You can read the post and the tutorial that I have created here : https://forums.freebsd.org/threads/how-to-run-stable-diffusion-webui-on-freebsd.87610/ What's the problem that I have ? The problem is that it runs only with the centos7 userland. As I said,to run it I'm forced to use the centos package installed on /compat/linux. But I have also installed Ubuntu on /compat/ubuntu with some important applications inside that I use from time to time,like brave,chrome,firefox,spotify,Sikulix,etc. As you probably know,we can't use two linux layers simultaneously. So,if I want to run stable diffusion I can't run at the same time the linux version of firefox,useful when I want to watch some DRM protected content. But what happens when I try to run the commands above using ubuntu instead of centos ? this : service ubuntu onestop && sysctl compat.linux.emul_path=/compat/ubuntu && service ubuntu onestart cd /compat source /usr/home/marietto/miniconda3/etc/profile.d/conda.sh conda activate cd /compat/ubuntu/home/marietto/stable-diffusion-webui conda activate automatic LD_PRELOAD=/compat/dummy-uvm.so python3 launch.py Python 3.10.9 (main, Jan 11 2023, 15:21:40) [GCC 11.2.0] Commit hash: 360feed9b55fb03060c236773867b08b4265645d Traceback (most recent call last): File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py", line 294, in prepare_environment() File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py", line 209, in prepare_environ ment run_python("import torch; assert torch.cuda.is_available(), 'Torch is not able to use GPU; add - -skip-torch-cuda-test to COMMANDLINE_ARGS variable to disable this check'") File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py", line 73, in run_python return run(f'"{python}" -c "{code}"', desc, errdesc) File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py", line 49, in run raise RuntimeError(message) RuntimeError: Error running command. Command: "/home/marietto/miniconda3/envs/automatic/bin/python3" -c "import torch; assert torch.cuda. is_available(), 'Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variab le to disable this check'" Error code: 1 stdout: stderr: Traceback (most recent call last): File "", line 1, in AssertionError: Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variabl e to disable this check I don't know why that error happens,but I know that it does not happen if I use Centos instead of Ubuntu and I have issued the same commands included in the tutorial to both "distros". I suspect that centos has some different software mechanisms than ubuntu. But I want to use only one "distro" and I would like it to be Ubuntu,because I have a better familiarity with it than with the centos. I understand that I have two roads that I can follow : 1) installing Debian in a chroot under CentOS 2) modify the script called "*miniconda-installer.sh*" and / or the script called "*Miniconda3-latest-Linux-x86_64.sh*" or both,I don't know. First of all,I have installed ubuntu following this tutorial : https://forums.freebsd.org/threads/linuxulator-how-to-install-brave-linux-app-on-freebsd-13-0.78879/ and then I've started to follow the instructions and I've reached the point where miniconda3 should be installed. This is what happens when I try to do that on a fresh installation of FreeBSD : # miniconda-installer.sh /compat/linux/bin/sh: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory As the error says,it refers to /compat/linux,but I'm using /compat/ubuntu,so,I've thought to make some little modification inside the script called *"miniconda-installer.sh"*,changing the word linux with the word ubuntu. Below you see what happens when I run the modified script : Miniconda3 will now be installed into this location: /home/marietto/miniconda3 - Press ENTER to confirm the location - Press CTRL-C to abort the installation - Or specify a different location below [/home/marietto/miniconda3] >>> PREFIX=/home/marietto/miniconda3 md5sum: -: No such file or directory WARNING: md5sum mismatch of tar archive expected: 81b26c617ffd9011dea96fd57c13e71b got: Unpacking payload ... Installing base environment... Downloading and Extracting Packages Downloading and Extracting Packages Preparing transaction: done Executing transaction: done Miniconda3-latest-Linux-x86_64.sh: 438: [[: not found Installing * environment... Miniconda3-latest-Linux-x86_64.sh: 444: [[: not found CondaFileIOError: '/home/marietto/miniconda3/pkgs/envs/*/env.txt'. [Errno 2] No such file or directory: '/home/marietto/miniconda3/pkgs/envs/*/env.txt My knowledge of the shell scripting is too low to understand how to fix that error. But I presume that someone of you can. It looks like a script requiring bash running in plain /bin/sh. So,I tried to do something like this : marietto@marietto:/compat $ bash [marietto@marietto /compat]$ miniconda-installer Welcome to Miniconda3 py310_22.11.1-1 In order to continue the installation process, please review the license agreement. Please, press ENTER to continue >>> ====================================== End User License Agreement - Miniconda ====================================== Copyright 2015-2022, Anaconda, Inc. All rights reserved under the 3-clause BSD License: This End User License Agreement (the "Agreement") is a legal agreement between you and Anaconda, Inc . ("Anaconda") and governs your use of Miniconda. Subject to the terms of this Agreement, Anaconda hereby grants you a non-exclusive, non-transferable license to: * Install and use the Miniconda, * Modify and create derivative works of sample source code delivered in Miniconda subject to the T erms of Service for the Repository (as defined hereinafter) available at https://www.anaconda.com/te rms-of-service , and * Redistribute code files in source (if provided to you by Anaconda as source) and binary forms, w ith or without modification subject to the requirements set forth below. Anaconda may, at its option, make available patches, workarounds or other updates to Miniconda. Unle ss the updates are provided with their separate governing terms, they are deemed part of Miniconda l icensed to you as provided in this Agreement. This Agreement does not entitle you to any support for Do you accept the license terms? [yes|no] [no] >>> yes Miniconda3 will now be installed into this location: /home/marietto/miniconda3 - Press ENTER to confirm the location - Press CTRL-C to abort the installation - Or specify a different location below [/home/marietto/miniconda3] >>> PREFIX=/home/marietto/miniconda3 md5sum: -: No such file or directory WARNING: md5sum mismatch of tar archive expected: 81b26c617ffd9011dea96fd57c13e71b got: Unpacking payload ... Installing base environment... Downloading and Extracting Packages Downloading and Extracting Packages Preparing transaction: done Executing transaction: done Miniconda3-latest-Linux-x86_64.sh: 438: [[: not found Installing * environment... Miniconda3-latest-Linux-x86_64.sh: 444: [[: not found CondaFileIOError: '/home/marietto/miniconda3/pkgs/envs/*/env.txt'. [Errno 2] No such file or directory: '/home/marietto/miniconda3/pkgs/envs/*/env.txt As further experiment I have installed the ubuntu userland under /compact and I have renamed the name ubuntu with the name linux and I tried again to install the linux-miniconda-installer,but it didn't even work. The error that I get in this case is the same as before. I don't know what to do next. -- Mario. --000000000000096f8805f31f5b4f Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hello to everyone,

I've been able to run the=20 stable diffusion webui of automatic1111. You can read the post and the=20 tutorial that I have created here :


=
What's the problem that I have ? The problem is that i= t runs only=20 with the centos7 userland.=20

As I said,to run it I'm forced to use the centos package installed o= n=20 /compat/linux. But I have also installed Ubuntu on /compat/ubuntu with=20 some important applications inside that I use from time to time,like brave,= chrome,firefox,spotify,Sikulix,etc. As you probably=20 know,we can't use two linux layers simultaneously. So,if I want to run= =20 stable diffusion I can't run at the same time the linux version of=20 firefox,useful when I want to watch some DRM protected content. But what happens when I try to run the commands above using ubuntu instead of=20 centos ? this :

serv=
ice ubuntu onestop && sysctl compat.linux.emul_path=3D/compat/ubunt=
u && service ubuntu onestart
cd /compat
source /usr/home/marietto/miniconda3/etc/profile.d/conda.sh
conda activate
cd /compat/ubuntu/home/marietto/stable-diffusion-webui
conda activate automatic
LD_PRELOAD=3D/compat/dummy-uvm.so  python3 launch.py

Python 3.10.9 (main, Jan 11 2023, 15:21:40) [GCC 11.2.0]
Commit hash: 360feed9b55fb03060c236773867b08b4265645d
Traceback (most recent call last):
  File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py&=
quot;, line 294, in <module>
    prepare_environment()
  File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py&=
quot;, line 209, in prepare_environ
ment
    run_python("import torch; assert torch.cuda.is_available(), 'T=
orch is not able to use GPU; add -
-skip-torch-cuda-test to COMMANDLINE_ARGS variable to disable this check=
9;")
  File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py&=
quot;, line 73, in run_python
    return run(f'"{python}" -c "{code}"', desc,=
 errdesc)
  File "/compat/ubuntu/home/marietto/stable-diffusion-webui/launch.py&=
quot;, line 49, in run
    raise RuntimeError(message)
RuntimeError: Error running command.
Command: "/home/marietto/miniconda3/envs/automatic/bin/python3" -=
c "import torch; assert torch.cuda.
is_available(), 'Torch is not able to use GPU; add --skip-torch-cuda-te=
st to COMMANDLINE_ARGS variab
le to disable this check'"
Error code: 1
stdout: <empty>
stderr: Traceback (most recent call last):
  File "<string>", line 1, in <module>
AssertionError: Torch is not able to use GPU; add --skip-torch-cuda-test to=
 COMMANDLINE_ARGS variabl
e to disable this check

I don't know why that error happens,but I know that it= does not happen=20 if I use Centos instead of Ubuntu and I have issued the same commands=20 included in the tutorial to both "distros". I suspect that centos= has=20 some different software mechanisms than ubuntu. But I want to use only one = "distro" and I would like it to be Ubuntu,because I have a=20 better familiarity with it than with the centos.

I understand that I have two= roads that I can follow :

1) installing Debian in a chroot under CentOS

2) modify the script called "miniconda-installer.sh" and /= or the script called "Miniconda3-latest-Linux-x86_64.sh" = or both,I don't know.

First of all,I have installed ubuntu following this tutorial :


https://forums.free= bsd.org/threads/linuxulator-how-to-install-brave-linux-app-on-freebsd-13-0.= 78879/


and then I've started to follow the instructions and I= 've reached the=20 point where miniconda3 should be installed. This is what happens when I=20 try to do that on a fresh installation of FreeBSD :

# miniconda-installer=
.sh
/compat/linux/bin/sh: error while loading shared libraries: libtinfo.so.5: =
cannot open shared object file: No such file or directory

As the error = says,it refers to /compat/linux,but I'm using /compat/ubuntu,so,I'v= e thought to make some little modification inside the script called "miniconda-instal= ler.sh",changing the word linux with the word ubuntu= .
Below you see what happens when I run the modified script :


Miniconda3 will now be installed into this locatio=
n:
/home/marietto/miniconda3

  - Press ENTER to confirm the location
  - Press CTRL-C to abort the installation
  - Or specify a different location below

[/home/marietto/miniconda3] >>>
PREFIX=3D/home/marietto/miniconda3
md5sum: -: No such file or directory
WARNING: md5sum mismatch of tar archive
expected: 81b26c617ffd9011dea96fd57c13e71b
     got:
Unpacking payload ...
                                                                           =
                  =20
Installing base environment...


Downloading and Extracting Packages


Downloading and Extracting Packages

Preparing transaction: done
Executing transaction: done
Miniconda3-latest-Linux-x86_64.sh: 438: [[: not found

Installing * environment...

Miniconda3-latest-Linux-x86_64.sh: 444: [[: not found

CondaFileIOError: '/home/marietto/miniconda3/pkgs/envs/*/env.txt'. =
[Errno 2] No such file or directory: '/home/marietto/miniconda3/pkgs/en=
vs/*/env.txt

My knowledge of the shell scripting is too low to understa= nd how to fix that error. But I presume that someone of you can. It looks like a script requiri= ng bash running in plain /bin/sh. So,I tried to do something like this :


marietto@marietto:/compat $ bash [marietto@marietto /compat]$ miniconda-installer Welcome to Miniconda3 py310_22.11.1-1 In order to continue the installation process, please review the license agreement. Please, press ENTER to continue >>>=20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D End User License Agreement - Miniconda =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Copyright 2015-2022, Anaconda, Inc. All rights reserved under the 3-clause BSD License: This End User License Agreement (the "Agreement") is a legal agre= ement between you and Anaconda, Inc . ("Anaconda") and governs your use of Miniconda. Subject to the terms of this Agreement, Anaconda hereby grants you a non-ex= clusive, non-transferable license to: * Install and use the Miniconda, * Modify and create derivative works of sample source code delivered in M= iniconda subject to the T erms of Service for the Repository (as defined hereinafter) available at ht= tps://www.anaconda.com/te rms-of-service, and * Redistribute code files in source (if provided to you by Anaconda as so= urce) and binary forms, w ith or without modification subject to the requirements set forth below. Anaconda may, at its option, make available patches, workarounds or other u= pdates to Miniconda. Unle ss the updates are provided with their separate governing terms, they are d= eemed part of Miniconda l icensed to you as provided in this Agreement. This Agreement does not entit= le you to any support for Do you accept the license terms? [yes|no] [no] >>> yes Miniconda3 will now be installed into this location: /home/marietto/miniconda3 - Press ENTER to confirm the location - Press CTRL-C to abort the installation - Or specify a different location below [/home/marietto/miniconda3] >>>=20 PREFIX=3D/home/marietto/miniconda3 md5sum: -: No such file or directory WARNING: md5sum mismatch of tar archive expected: 81b26c617ffd9011dea96fd57c13e71b got:=20 Unpacking payload ... = =20 Installing base environment... Downloading and Extracting Packages Downloading and Extracting Packages Preparing transaction: done Executing transaction: done Miniconda3-latest-Linux-x86_64.sh: 438: [[: not found Installing * environment... Miniconda3-latest-Linux-x86_64.sh: 444: [[: not found CondaFileIOError: '/home/marietto/miniconda3/pkgs/envs/*/env.txt'. = [Errno 2] No such file or directory: '/home/marietto/miniconda3/pkgs/en= vs/*/env.txt

<=
span style=3D"font-family:arial,sans-serif">As further experiment I =
have installed the ubuntu userland under /compact and I have renamed the na=
me ubuntu 
with the name linux and I tried again to install the linux-mi= niconda-installer,but it didn't even work.

The error that I get in this case is the same as b= efore. I don't know what to do next.


=
--
Mario.
--000000000000096f8805f31f5b4f--