在现有磁盘基础上直接扩容的。一开始部署的时候,设置的是40GB。现在已经使用30多GB了。需要扩容下。

打开虚拟机设置

把磁盘扩展到一定大小

root@branch-dev:~# df -h
Filesystem                    Size  Used Avail Use% Mounted on
tmpfs                         3.2G  2.2M  3.2G   1% /run
/dev/mapper/ubuntu--vg-lv--0   38G   30G  6.0G  84% /
tmpfs                          16G     0   16G   0% /dev/shm
tmpfs                         5.0M     0  5.0M   0% /run/lock
/dev/sda2                     2.0G  251M  1.6G  14% /boot

 

查看逻辑卷相关信息

root@branch-dev:~# lvs
  LV   VG        Attr       LSize   Pool Origin Data%  Meta%  Move Log Cpy%Sync Convert
  lv-0 ubuntu-vg -wi-ao---- <38.00g                                                    
root@branch-dev:~# pvs
  PV         VG        Fmt  Attr PSize   PFree
  /dev/sda3  ubuntu-vg lvm2 a--  <38.00g    0 
root@branch-dev:~# vgs
  VG        #PV #LV #SN Attr   VSize   VFree
  ubuntu-vg   1   1   0 wz--n- <38.00g    0 

开始扩容

# 使用parted命令
root@branch-dev:~# parted /dev/sda
GNU Parted 3.4
Using /dev/sda
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) help                                                             
align-check TYPE N                       check partition N for TYPE(min|opt) alignment
help [COMMAND]                           print general help, or help on COMMAND
mklabel,mktable LABEL-TYPE               create a new disklabel (partition table)
mkpart PART-TYPE [FS-TYPE] START END     make a partition
name NUMBER NAME                         name partition NUMBER as NAME
print [devices|free|list,all|NUMBER]     display the partition table, available devices, free space, all found partitions, or a particular partition
quit                                     exit program
rescue START END                         rescue a lost partition near START and END
resizepart NUMBER END                    resize partition NUMBER
rm NUMBER                                delete partition NUMBER
select DEVICE                            choose the device to edit
disk_set FLAG STATE                      change the FLAG on selected device
disk_toggle [FLAG]                       toggle the state of FLAG on selected device
set NUMBER FLAG STATE                    change the FLAG on partition NUMBER
toggle [NUMBER [FLAG]]                   toggle the state of FLAG on partition NUMBER
unit UNIT                                set the default unit to UNIT
version                                  display the version number and copyright information of GNU Parted
(parted) print     #打印信息                                                       
Model: VMware, VMware Virtual S (scsi)
Disk /dev/sda: 107GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system  Name  Flags
1      1049kB  2097kB  1049kB                     bios_grub
2      2097kB  2150MB  2147MB  ext4
3      2150MB  42.9GB  40.8GB

(parted) resizepart 3 100%    #选择第三个
(parted) quit       #退出
Information: You may need to update /etc/fstab.

第一步

root@branch-dev:~# pvresize /dev/sda3
  Physical volume "/dev/sda3" changed
  1 physical volume(s) resized or updated / 0 physical volume(s) not resized

第二步

 
  root@branch-dev:~# lvextend -l +100%FREE /dev/mapper/ubuntu--vg-lv--0
  Size of logical volume ubuntu-vg/lv-0 changed from <38.00 GiB (9727 extents) to <98.00 GiB (25087 extents).
  Logical volume ubuntu-vg/lv-0 successfully resized.

 

第三步

 
  root@branch-dev:~# resize2fs /dev/mapper/ubuntu--vg-lv--0
resize2fs 1.46.5 (30-Dec-2021)
Filesystem at /dev/mapper/ubuntu--vg-lv--0 is mounted on /; on-line resizing required
old_desc_blocks = 5, new_desc_blocks = 13
The filesystem on /dev/mapper/ubuntu--vg-lv--0 is now 25689088 (4k) blocks long.

 

第四步 验证

root@branch-dev:~# df -h
Filesystem                    Size  Used Avail Use% Mounted on
tmpfs                         3.2G  2.2M  3.2G   1% /run
/dev/mapper/ubuntu--vg-lv--0   97G   30G   63G  32% /
tmpfs                          16G     0   16G   0% /dev/shm
tmpfs                         5.0M     0  5.0M   0% /run/lock
/dev/sda2                     2.0G  251M  1.6G  14% /boot
overlay                        97G   30G   63G  32% /var/lib/docker/overlay2/26d3467e6fee1f2f4f585cb3c1acd52e000a4481e42398f643734f88039a2a48/merged
overlay                        97G   30G   63G  32% /var/lib/docker/overlay2/4472858bcb06a4ec49f004b6c9398f63a3c7e8030bbed20e154c1aad6a8a5679/merged
overlay                        97G   30G   63G  32% /var/lib/docker/overlay2/ede99e283b91606ecb041574e1426df839b644441caadae4c3460e15420ec6cf/merged
overlay                        97G   30G   63G  32% /var/lib/docker/overlay2/607f6fdf38fa1686535a546c46454505d31e2f98e25e125409299092a188a923/merged
overlay                        97G   30G   63G  32% /var/lib/docker/overlay2/00e4dc4e79f802916419598a22fb7f50c083ebe60d5bc5acad39ee68a8aa9c8f/merged
overlay                        97G   30G   63G  32% /var/lib/docker/overlay2/4176993e84f29cfd926fc1b7a5c6fa479bbdd7d20ec2a74a4529c67cdb5adf0a/merged
tmpfs                         3.2G  4.0K  3.2G   1% /run/user/0
overlay                        97G   30G   63G  32% /var/lib/docker/overlay2/dfe4a6f793eb756c116f268dd5b16d5df3a5fa3b630d42fc2d4091f7c62b2f4d/merged

 

可见容量已经提升到100GB了。 完成本次扩容。 👌

posted @ 2024-11-01 16:26 糖果的二师兄 阅读(131) 评论(0) 推荐(0) 编辑
摘要: ./Configure make make install编译安装后再执行一下这个:ldconfig /usr/local/lib64/ 阅读全文
posted @ 2024-11-01 10:39 糖果的二师兄 阅读(253) 评论(0) 推荐(0) 编辑
摘要: 注册码1RAR registration dataAdminUnlimited Company LicenseUID=1d7426b0b166c91c21ab641221225021abd0925f7c70456ecd71f724a7f5a00b0a0f7d19ee45c5e20951dae2857 阅读全文
posted @ 2024-06-14 14:23 糖果的二师兄 阅读(1419) 评论(0) 推荐(0) 编辑
摘要: 直接整 就这种打印机,很经典 First, you need to download the legacy Samsung Printer Driver 2.6 for OS X - from apple website: Samsung Printer Drivers v2.6 for OS X 阅读全文
posted @ 2024-06-10 15:03 糖果的二师兄 阅读(283) 评论(0) 推荐(0) 编辑
摘要: 2D游戏一般按玩家视角可以分为:侧视、俯视、斜45度。横轴游戏一般都属于侧视;俯视一般常见于一些小游戏,号称上帝视角;斜45度就是所谓的2.5D,又称为伪3D,用2D的技术产生3D的效果,主要是看美术绘制的贴图。视角不同,游戏场景的设计是有所差异,今天主要总结下前一周使用Tiled制作地图的一些思路 阅读全文
posted @ 2024-01-18 10:47 糖果的二师兄 阅读(354) 评论(0) 推荐(0) 编辑
摘要: 一,使用USBToolBox定制https://github.com/USBToolBox请下载tool和kext,推荐在win下打开定制工具,定制过程非常简单,使用USB2.0和USB3.0各一个U盘,把所有的接口都插一遍,然后导出map.kext,将该kext和之前下载的另一个kext,总共两个 阅读全文
posted @ 2023-10-08 14:32 糖果的二师兄 阅读(932) 评论(0) 推荐(0) 编辑
摘要: https://www.cnblogs.com/findumars/p/3498714.html GAS中每个操作都是有一个字符的后缀,表明操作数的大小。 C声明 GAS后缀 大小(字节) char b 1 short w 2 (unsigned) int / long / char* l 4 fl 阅读全文
posted @ 2023-09-20 10:53 糖果的二师兄 阅读(1777) 评论(0) 推荐(0) 编辑
摘要: mysql -u root - p接下来输入刚刚创建的密码 成功进入之后需要输入以下命令use mysql; //切换数据库update user set host = '%' where user = 'root'; 输入完成之后 select Host, User from user; 查看以下 阅读全文
posted @ 2023-07-15 17:36 糖果的二师兄 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 1,启动虚拟机。2,在虚拟机的菜单中“虚拟机”中选择“安装 Parallels Tools”。此时 prl-tools-lin.iso 连接到 CD/DVD 驱动里。3,查看是否在 ubuntu 中挂载 ISO 文件。sudo mount | grep iso9660如果此命令返回空,没有挂载,要挂 阅读全文
posted @ 2023-07-14 11:29 糖果的二师兄 阅读(744) 评论(0) 推荐(0) 编辑
摘要: 官网下载Mac版C4D R25的安装包之后安装:https://wdown.solidangle.com/c4dtoa/C4DtoA-4.4.0-darwin-R25.pkg 再下载: 链接: https://pan.baidu.com/s/1XSfbps41kDRESHSMpbQiWA?pwd=z 阅读全文
posted @ 2022-09-29 14:29 糖果的二师兄 阅读(191) 评论(0) 推荐(0) 编辑
摘要: 注意:如果需要部署在私有云,那么会通过私有云的带宽传输。 该镜像较小:11.1 MB,推荐使用 镜像地址:https://hub.docker.com/r/messense/aliyundrive-webdav 1、获取阿里云盘 Token 登录官网 https://www.aliyundrive. 阅读全文
posted @ 2022-09-14 14:47 糖果的二师兄 阅读(3066) 评论(0) 推荐(0) 编辑
摘要: 修改一下wrap mode 阅读全文
posted @ 2022-05-18 23:00 糖果的二师兄 阅读(242) 评论(0) 推荐(0) 编辑
摘要: 一直没找到TBC2.4.3的mac客户端。今天终于找到了。 原生的2.4.3 World of Warcraft.app 只能运行在x86的mac系统下,也就是最高支持Mojave版本。 这只是一个.app的运行文件。放在下载的windows tbc的客户端里即可运行 链接: https://pan 阅读全文
posted @ 2021-10-22 21:33 糖果的二师兄 阅读(677) 评论(2) 推荐(0) 编辑
摘要: 从新冠疫苗接种系统导出的excel表中,所有有效单元格都加了干扰字符,很多时候需要正常的数据做对比等用途,这时候这此干扰字符特别讨厌。 类似这样的,看上去是正常的,其实单元格内容加了一些干扰字符 要去除这些,非常的费事儿,特别大量数据的时候,基本不可能人工去除。 但用vba脚本,那就简单多了。 Su 阅读全文
posted @ 2021-08-31 10:15 糖果的二师兄 阅读(1317) 评论(0) 推荐(1) 编辑
摘要: 原来是 Servlet、JSP 与 Spring 的版本之间的匹配出了问题。众所周知,2018 年,Java EE 改名为 Jakarta EE。这导致一些 JAR 包的包名也在之后的版本中进行了更改。这对本项目的影响是,Spring 本身是不含 Servlet、JSP 的 JAR 包的,但其依赖这 阅读全文
posted @ 2021-08-21 20:05 糖果的二师兄 阅读(5898) 评论(0) 推荐(0) 编辑
点击右上角即可分享
微信分享提示