#author("2023-05-27T11:50:17+09:00","","") #author("2023-05-27T11:51:24+09:00","","") #nofollow #norelated 総数:&counter(total); 今日:&counter(today); 昨日:&counter(yesterday);&br; [[Memorandums]]&br; [[on windows]]&br; * もくじ [#ie7b9eef] #contents * WSL2 (Windows Subsystem for Linux) [#w5de4603] ** installing WSL2 Windows11 [#ue0371db] 参考url https://chigusa-web.com/blog/windows%E3%81%ABdocker%E3%82%92%E3%82%A4%E3%83%B3%E3%82%B9%E3%83%88%E3%83%BC%E3%83%AB%E3%81%97%E3%81%A6python%E7%92%B0%E5%A2%83%E3%82%92%E6%A7%8B%E7%AF%89/ [[WSL を使用して Windows に Linux をインストールする>https://learn.microsoft.com/ja-jp/windows/wsl/install]] [[WSL2のインストールを分かりやすく解説【Windows10/11】>https://chigusa-web.com/blog/wsl2-win11/]] **PowerShellを管理者として実行します [#y1f66323] -①タスクバーの「検索」アイコンをクリック -②検索フォームに「powershell」と入力しましょう。 -③「Windows PowerShell」を右クリックし -④「管理者として実行」しましょう。 Windows PowerShell Copyright (C) Microsoft Corporation. All rights reserved. 新機能と改善のために最新の PowerShell をインストールしてください!https://aka.ms/PSWindows PS C:\WINDOWS\system32> **コマンドでインストール開始する[#s13b1da2] 以下のコマンドを実行します。これだけでインストールは完了します。 wsl --install インストール中: 仮想マシン プラットフォーム 仮想マシン プラットフォーム はインストールされました。 インストール中: Linux 用 Windows サブシステム Linux 用 Windows サブシステム はインストールされました。 インストール中: Ubuntu Ubuntu はインストールされました。 要求された操作は正常に終了しました。変更を有効にするには、システムを再起動する必要があります。 PS C:\WINDOWS\system32> **インストールが完了したら、PCを再起動します [#g0640794] **再起動後、自動でUbuntuが起動されました。ユーザ名とパスワードを設定します [#w8b13b0b] Ubuntu は既にインストールされています。 Ubuntu を起動しています... Installing, this may take a few minutes... Please create a default UNIX user account. The username does not need to match your Windows username. For more information visit: https://aka.ms/wslusers Enter new UNIX username: ryu New password: Retype new password: passwd: password updated successfully Installation successful! To run a command as administrator (user "root"), use "sudo <command>". See "man sudo_root" for details. Welcome to Ubuntu 22.04.2 LTS (GNU/Linux 5.15.90.1-microsoft-standard-WSL2 x86_64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage This message is shown once a day. To disable it please create the /home/ryu/.hushlogin file. ryu@LAPTOP-KRM3VC55:~$ -WSL2では、デフォルトだとメインメモリの半分しかメモリが割り当てられません。 ryu@LAPTOP-KRM3VC55:~$ free -h total used free shared buff/cache available Mem: 7.6Gi 487Mi 6.7Gi 3.0Mi 418Mi 6.9Gi Swap: 2.0Gi 0B 2.0Gi ryu@LAPTOP-KRM3VC55:~$ **以下のページより、Docker Desktop for Windowsをダウンロードします。&br; [#z87f07b1] https://www.docker.com/products/docker-desktop/ -Docker Desktop Installer.exeを取得した [[on windows]]へ&br;