最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

關(guān)于docker中?WSL?配置與修改問題

 更新時(shí)間:2021年12月28日 11:36:42   作者:PanPan003  
這篇文章主要介紹了docker中?WSL?配置與修改,本文給大家介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下

https://docs.microsoft.com/en-us/windows/wsl/wsl-config

.wslconfig

  • Stored in your%UserProfile%directory.
  • Used to configure settings globally across all installed Linux distributions running as the WSL 2 version.Can be usedonly for distributions run by WSL 2.
  • Distributions running as WSL 1 will not be affected by this configuration as they are not running as a virtual machine.
  • To get to your%UserProfile%directory, in PowerShell, usecd ~to access your home directory (which is typically your user profile,C:\Users\<UserName>) or you can open Windows File Explorer and enter%UserProfile%in the address bar. The directory path should look something like:C:\Users\<UserName>\.wslconfig.WSL will detect the existence of these files, read the contents, and automatically apply the configuration settings every time you launch WSL. If the file is missing or malformed (improper markup formatting), WSL will continue to launch as normal without the configuration settings applied.

Check which version of WSL you are running.

Note

Adjusting per-distribution settings with the wsl.conf file is only available in Windows Build 17093 and later.

Configuration setting for .wslconfig

The .wslconfig file configures settings globally for all Linux distributions running with WSL 2.(For per-distribution configuration seewsl.conf).

See.wslconfigfor info on where to store the .wslconfig file.

Note

Global configuration options with.wslconfigis only available for distributions running as WSL 2 in Windows Build 19041 and later. Keep in mind you may need to runwsl --shutdownto shut down the WSL 2 VM and then restart your WSL instance for these changes to take affect.

This file can contain the following options that affect the VM that powers any WSL 2 distribution:

Section label:[wsl2]

key value default notes
kernel string The Microsoft built kernel provided inbox An absolute Windows path to a custom Linux kernel.
memory size 50% of total memory on Windows or 8GB, whichever is less; on builds before 20175: 80% of your total memory on Windows How much memory to assign to the WSL 2 VM.
processors number The same number of processors on Windows How many processors to assign to the WSL 2 VM.
localhostForwarding boolean true Boolean specifying if ports bound to wildcard or localhost in the WSL 2 VM should be connectable from the host via?localhost:port.
kernelCommandLine string Blank Additional kernel command line arguments.
swap size 25% of memory size on Windows rounded up to the nearest GB How much swap space to add to the WSL 2 VM, 0 for no swap file. Swap storage is disk-based RAM used when memory demand exceeds limit on hardware device.
swapFile string %USERPROFILE%\AppData\Local\Temp\swap.vhdx An absolute Windows path to the swap virtual hard disk.
pageReporting boolean true Default?true?setting enables Windows to reclaim unused memory allocated to WSL 2 virtual machine.
guiApplications boolean* true Boolean to turn on or off support for GUI applications (WSLg) in WSL. Only available for Windows 11.
debugConsole boolean* false Boolean to turn on an output console Window that shows the contents of?dmesg?upon start of a WSL 2 distro instance. Only available for Windows 11.
nestedVirtualization boolean* true Boolean to turn on or off nested virtualization, enabling other nested VMs to run inside WSL 2. Only available for Windows 11.
vmIdleTimeout number* 60000 The number of milliseconds that a VM is idle, before it is shut down. Only available for Windows 11.

Entries with thepathvalue must be Windows paths with escaped backslashes, e.g:C:\\Temp\\myCustomKernel

Entries with thesizevalue must be a size followed by a unit, for example8GBor512MB.

Entries with an * after the value type are only available on Windows 11.

Example .wslconfig file

The.wslconfigsample file below demonstrates some of the configuration options available. In this example, the file path isC:\Users\<UserName>\.wslconfig.

# Settings apply across all Linux distros running on WSL 2
[wsl2]
 
# Limits VM memory to use no more than 4 GB, this can be set as whole numbers using GB or MB
memory=4GB
 
# Sets the VM to use two virtual processors
processors=2
 
# Specify a custom Linux kernel to use with your installed distros. The default kernel used can be found at https://github.com/microsoft/WSL2-Linux-Kernel
kernel=C:\\temp\\myCustomKernel
 
# Sets additional kernel parameters, in this case enabling older Linux base images such as Centos 6
kernelCommandLine = vsyscall=emulate
 
# Sets amount of swap storage space to 8GB, default is 25% of available RAM
swap=8GB
 
# Sets swapfile path location, default is %USERPROFILE%\AppData\Local\Temp\swap.vhdx
swapfile=C:\\temp\\wsl-swap.vhdx
 
# Disable page reporting so WSL retains all allocated memory claimed from Windows and releases none back when free
pageReporting=false
 
# Turn off default connection to bind WSL 2 localhost to Windows localhost
localhostforwarding=true
 
# Disables nested virtualization
nestedVirtualization=false
 
# Turns on output console showing contents of dmesg when opening a WSL 2 distro for debugging
debugConsole=true

到此這篇關(guān)于docker中 WSL 配置 修改的文章就介紹到這了,更多相關(guān)docker中 WSL 配置 修改內(nèi)容請(qǐng)搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關(guān)文章希望大家以后多多支持腳本之家!

相關(guān)文章

  • 被棄用的 Docker 會(huì)被 Podman 取代嗎

    被棄用的 Docker 會(huì)被 Podman 取代嗎

    Docker 是一種以容器化的方式打包、分發(fā)和部署應(yīng)用程序的方式。自 2013 年 3 月 13 日初始版本發(fā)布以來(lái),Docker 已成為容器業(yè)界的事實(shí)標(biāo)準(zhǔn)。而Kubernetes 是一款由 Google 開發(fā)的開源容器編排系統(tǒng)
    2020-12-12
  • Docker?compose搭建ELK服務(wù)基本使用

    Docker?compose搭建ELK服務(wù)基本使用

    這篇文章主要為大家介紹了Docker?compose搭建ELK服務(wù)基本使用,有需要的朋友可以借鑒參考下,希望能夠有所幫助,祝大家多多進(jìn)步,早日升職加薪
    2023-03-03
  • docker 安裝solr8.6.2 配置中文分詞器的方法

    docker 安裝solr8.6.2 配置中文分詞器的方法

    這篇文章主要介紹了docker 安裝solr8.6.2 配置中文分詞器的方法,本文給大家介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下
    2020-09-09
  • docker-compose如何定義容器的ip

    docker-compose如何定義容器的ip

    這篇文章主要介紹了docker-compose如何定義容器的ip問題,具有很好的參考價(jià)值,希望對(duì)大家有所幫助,如有錯(cuò)誤或未考慮完全的地方,望不吝賜教
    2024-01-01
  • docker多個(gè)容器的相互通信實(shí)現(xiàn)步驟

    docker多個(gè)容器的相互通信實(shí)現(xiàn)步驟

    本文介紹了在宿主機(jī)上運(yùn)行多個(gè)Docker容器時(shí)的幾種通信方式,包括默認(rèn)的橋接網(wǎng)絡(luò)、自定義網(wǎng)絡(luò)、--link參數(shù)、Host網(wǎng)絡(luò)、Docker-compose和共享數(shù)據(jù)卷等,每種方式都有其特點(diǎn)和適用場(chǎng)景,感興趣的朋友跟隨小編一起看看吧
    2025-02-02
  • docker啟動(dòng)mysql5.7服務(wù)詳細(xì)說(shuō)明

    docker啟動(dòng)mysql5.7服務(wù)詳細(xì)說(shuō)明

    這篇文章主要給大家介紹了關(guān)于docker啟動(dòng)mysql5.7服務(wù)的相關(guān)資料,文中通過(guò)代碼示例介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考價(jià)值,需要的朋友可以參考下
    2023-09-09
  • docker鏡像拉取過(guò)程和遠(yuǎn)程代理配置過(guò)程

    docker鏡像拉取過(guò)程和遠(yuǎn)程代理配置過(guò)程

    Docker鏡像拉取過(guò)程涉及客戶端、守護(hù)進(jìn)程、注冊(cè)表和網(wǎng)絡(luò)通信,客戶端發(fā)送請(qǐng)求,守護(hù)進(jìn)程處理并從注冊(cè)表下載鏡像層,配置包括Docker守護(hù)進(jìn)程的代理、TLS設(shè)置和防火墻規(guī)則,確保網(wǎng)絡(luò)策略和安全措施到位,以優(yōu)化鏡像拉取和保護(hù)傳輸過(guò)程
    2024-11-11
  • docker運(yùn)行nginx不生效的解決辦法

    docker運(yùn)行nginx不生效的解決辦法

    當(dāng)docker運(yùn)行nginx鏡像時(shí),設(shè)置端口映射,則只有該映射端口起作用,nginx配置的其他端口無(wú)效,接下來(lái)本文將給大家介紹docker運(yùn)行nginx不生效的解決辦法,文中有相關(guān)的代碼示例供大家參考,需要的朋友可以參考下
    2024-01-01
  • Docker容器中運(yùn)行flume及啟動(dòng)不輸出運(yùn)行日志問題

    Docker容器中運(yùn)行flume及啟動(dòng)不輸出運(yùn)行日志問題

    這篇文章主要介紹了 Docker容器中運(yùn)行flume及啟動(dòng)不輸出運(yùn)行日志問題及解決方法,需要的朋友參考下吧
    2018-03-03
  • springboot整合docker部署實(shí)現(xiàn)兩種構(gòu)建Docker鏡像方式

    springboot整合docker部署實(shí)現(xiàn)兩種構(gòu)建Docker鏡像方式

    這篇文章主要介紹了springboot整合docker部署實(shí)現(xiàn)兩種構(gòu)建Docker鏡像方式,小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,也給大家做個(gè)參考。一起跟隨小編過(guò)來(lái)看看吧
    2019-04-04

最新評(píng)論

类乌齐县| 漯河市| 西城区| 南阳市| 库车县| 乌兰县| 乌拉特后旗| 报价| 平遥县| 莫力| 庆城县| 华容县| 樟树市| 罗城| 静宁县| 玉山县| 南和县| 开原市| 凤庆县| 嘉祥县| 务川| 进贤县| 汉阴县| 祥云县| 怀仁县| 德州市| 德格县| 乌什县| 洮南市| 永定县| 嘉兴市| 吉安市| 长宁区| 全南县| 怀远县| 昭觉县| 体育| 台南县| 香港 | 县级市| 广宗县|