当前位置: 首页 > news >正文

【wsl2】从C盘迁移到G盘

  • 参考大神

C盘的ubuntu22.04 非常大,高达30g+

  • 迁移后就只有几百M了:

在这里插入图片描述

右键有一个move没有敢尝试

在这里插入图片描述


迁移过程

在这里插入图片描述

Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindowsPS C:\Users\zhangbin> wsl --shutdown
PS C:\Users\zhangbin> wsl --export ^C
PS C:\Users\zhangbin> wsl -l -vNAME            STATE           VERSION
* Ubuntu-22.04    Stopped         2CentOS7         Stopped         2
PS C:\Users\zhangbin> wsl -export Ubuntu-22.04 G:\ubuntu2204.tar
Invalid command line argument: -export
Please use 'wsl.exe --help' to get a list of supported arguments.
PS C:\Users\zhangbin> wsl --export Ubuntu-22.04 G:\ubuntu2204.tar
Export in progress, this may take a few minutes.
The operation completed successfully.
PS C:\Users\zhangbin> wsl --unregister Ubuntu-22.04
Unregistering.
The operation completed successfully.
PS C:\Users\zhangbin> wsl -l -vNAME       STATE           VERSION
* CentOS7    Stopped         2
PS C:\Users\zhangbin> wsl --input Ubuntu-22.04 G:\WSL-SYS\Ubuntu-22.04 G:\WSL-SYS\Ubuntu-22.04.tar --version 2
Invalid command line argument: --input
Please use 'wsl.exe --help' to get a list of supported arguments.
PS C:\Users\zhangbin> wsl --imput Ubuntu-22.04 G:\WSL-SYS\Ubuntu-22.04 G:\WSL-SYS\Ubuntu-22.04.tar --version 2
Invalid command line argument: --imput
Please use 'wsl.exe --help' to get a list of supported arguments.
PS C:\Users\zhangbin> wsl --import Ubuntu-22.04 G:\WSL-SYS\Ubuntu-22.04 G:\WSL-SYS\Ubuntu-22.04.tar --version 2
The system cannot find the file specified.
Error code: Wsl/ERROR_FILE_NOT_FOUND
PS C:\Users\zhangbin> wsl --import Ubuntu-22.04 G:\WSL-SYS\Ubuntu-22.04 G:\WSL-SYS\ubuntu2204.tar --version 2
Import in progress, this may take a few minutes.
The operation completed successfully.
PS C:\Users\zhangbin>
  • 然后点开就能用了:
http://www.lryc.cn/news/430700.html

相关文章:

  • 低代码技术新趋势——逆向工程
  • HTTP 二、进阶
  • 【Hot100】LeetCode—35. 搜索插入位置
  • 001集——CAD—C#二次开发入门——开发环境基本设置
  • Java类和对象——快速自动生成带参数的结构
  • Python操作数据库的ORM框架SQLAlchemy快速入门教程
  • 提交MR这个词儿您知道是什么意思吗?
  • Linux sentinel写法
  • 顶级域名服务器 - TLD服务器
  • 【LeetCode】01.两数之和
  • 便宜好用的云手机盘点
  • pdf怎么压缩小一些?推荐的几种PDF压缩方法
  • Linux终端简单配置(Vim、oh-my-zsh和Terminator)
  • js模块化 --- commonjs规范 原理详解
  • kubeadm部署 Kubernetes(k8s) 高可用集群【V1.28 】
  • 【MySQL】MySQL Workbench下载安装、环境变量配置、基本MySQL语句、新建Connection
  • CrowdStrike 的失败如何凸显了左移测试的重要性
  • HarmonyOS开发实战( Beta5版)高负载组件的渲染实践规范
  • NLP从零开始------16.文本中阶处理之序列到序列模型(1)
  • 【匈牙利汽车产业考察,开启新机遇】
  • 并行程序设计基础——动态进程管理
  • C# 字符串(String)使用教程
  • django之ForeignKey、OneToOneField 和 ManyToManyField
  • java.lang.IndexOutOfBoundsException: setSpan ( 0...x ) ends beyond length X
  • 技术进展:CH-90树脂在去除硫酸钠柠檬酸钠溶液中铁锰离子上的应用
  • 录屏时摄像头无法识别?如何录屏时打开摄像头,解决方案及录屏软件推荐
  • 达梦数据库-DM8 企业版安装指南
  • 心脑血管科董田林医生:心律失常患者饮食,调养秘诀,助你找回健康心跳
  • 期权杂记(一)
  • 【MATLAB源码-第163期】基于matlab的BPSK+瑞利(rayleigh)信道下有无波束成形误码率对比仿真。