MaruOpsInfrastructure and AI notes

About (Korean)Contact (Korean)

[Local LLM 10] Install WSL2 and Understand Files and Networking

Workbench with keyboard and mouse

Reference photo · Workbench with keyboard and mouse · Photo: Jeff Sheldon ugmonk / Source / CC0 · Resized for listings; illustrative photo, not the tested environment

Building a Local LLM · 10/30 · Development Environment

Full series and learning sequence · Practice code ZIP

WSL2 makes Linux tools available on a Windows PC, but the two environments still have distinct files, processes and network behavior. Before switching between terminals, identify where the working files are stored and which environment runs the server.

Use Windows administrator privileges for the WSL installation steps. In daily practice, use only the necessary permissions and save any running work before restarting.

Install WSL2 and Ubuntu

wsl --install -d Ubuntu
# 재시작이 필요하다는 안내가 나오면 재부팅 후 Ubuntu 초기 설정
wsl --status
wsl --list --verbose

The first time you open Ubuntu, you create a Linux username and password. In the WSL list, we check that VERSION is 2. If installation is blocked, check BIOS virtualization settings and supported Windows states according to Microsoft documentation. We do not bypass security features by turning them off all at once.

File location on Windows/Linux

pwd
uname -a
which python3
which node
ls /mnt/c/Users

Run the following command in Ubuntu terminal: The C drive in Windows usually appears as /mnt/c, and the Linux home is in a separate file system. If your project deals with a lot of Linux packages, it is more efficient to place it in a Linux path such as ~/projects. .venv is also created separately for Windows and Linux.

The serial’s primary Ollama continues to run on Windows. If you install it on WSL, an additional server and model repository are created. For now, rather than increasing the number of servers, I’m focusing on checking where I can connect to the Windows server.

NAT mirrored and localhost

In default NAT mode, 127.0.0.1 in WSL should not be treated the same as the same address in Windows. In mirrored mode supported by Microsoft, mutual access is possible through localhost, but you must check the Windows version and configuration conditions. Ollama will not be released to 0.0.0.0 right away because it cannot be connected.

curl --max-time 5 http://127.0.0.1:11434/api/version
ip route

You can continue the previous exercise in Windows PowerShell. When WSL needs to call Ollama on Windows, review whether mirrored is supported and how to apply it. wsl –shutdown stops all running WSL tasks, so use it after saving.

GPU driver in WSL

When using NVIDIA CUDA in WSL, prepare based on the WSL-supported driver on your Windows host. Be careful not to confuse this as a procedure for reinstalling a regular Linux server’s display driver into WSL. Docker Desktop’s GPU delivery also checks the WSL2 backend and GPU support conditions separately.

Shutting down WSL will also affect services within it. You need to check whether the Windows app is turned on and the Linux server is running. First, write down which server you are running in which terminal. The operational phase simply adds to that record how it started and where the data is located.

reference material

Documentation and model tags checked: October 18, 2026. Primary lab environment: Windows 11 x64.