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

学生组织网站建设安徽金鹏建设集团网站

学生组织网站建设,安徽金鹏建设集团网站,企业做网站的注意什么,北京微网站建设#有时df -h查看分区信息无法满足需求# 借助Android系统自带的sgdisk可以查看详细的分区信息#xff0c;类似fdisk命令#xff0c;sgdisk同样可以创建分区#xff0c;功能也很强大。 一、sgdisk帮助信息 127|console:/ # sgdisk USAGE: sgdisk [OPTION...] device类似fdisk命令sgdisk同样可以创建分区功能也很强大。 一、sgdisk帮助信息 127|console:/ # sgdisk USAGE: sgdisk [OPTION...] device--attributes operate on partition attributes--set-alignment set sector alignment--backup backup GPT to file--change-name change partitions name--recompute-chs recompute CHS values in protective/hybrid MBR--delete delete a partition--display-alignment show number of sectors per allocation block--move-second-header move second header to end of disk--end-of-largest show end of largest free block--first-in-largest show start of the largest free block--first-aligned-in-largest show start of the largest free block, aligned--mbrtogpt convert MBR to GPT--randomize-guids randomize disk and partition GUIDs--hybrid create hybrid MBR--info show detailed information on partition--move-main-table adjust the location of the main partition table--load-backup load GPT backup from file--list-types list known partition types--gpttombr convert GPT to MBR--new create new partition--largest-new create largest possible new partition--clear clear partition table--print-mbr print MBR partition table--print print partition table--pretend make changes in memory, but dont write them--transpose transpose two partitions--replicate replicate partition table--sort sort partition table entries--resize-table resize partition table--typecode change partition type code--transform-bsd transform BSD disklabel partition to GPT--partition-guid set partition GUID--disk-guid set disk GUID--verify check partition table integrity--version display version information--zap zap (destroy) GPT (but not MBR) data structures--zap-all zap (destroy) GPT and MBR data structures 二、查看磁盘分区详情 sgdisk --print /dev/block/sdaconsole:/ # sgdisk --print /dev/block/sda Disk /dev/block/sda: 16777216 sectors, 64.0 GiB Sector size (logical/physical): 4096/4096 bytes Disk identifier (GUID): 54054CFA-8B64-425D-A63F-B6B6F795C66E Partition table holds up to 128 entries Main partition table begins at sector 2 and ends at sector 5 First usable sector is 6, last usable sector is 16777210 Partitions will be aligned on 256-sector boundaries Total free space is 1780981 sectors (6.8 GiB)Number Start (sector) End (sector) Size Code Name1 256 511 1024.0 KiB 8300 misc2 512 16895 64.0 MiB 8300 boot_a3 16896 33279 64.0 MiB 8300 boot_b4 33280 33535 1024.0 KiB 8300 dtb_a5 33536 33791 1024.0 KiB 8300 dtb_b6 33792 37887 16.0 MiB 8300 metadata7 37888 6067199 23.0 GiB 8300 super8 6067200 6591487 2.0 GiB 8300 kdump9 6591488 6607871 64.0 MiB 8300 persist10 6607872 14996479 32.0 GiB 8300 userdata 使用这个指令可以很方便查看RAW分区的大小以及起始和终止簇。新的版本df -h无法查看super分区大小也需要使用sgdisk来查看。 通过上面信息可以看到sda大小为64GB还剩余6.8GB空间未划分。 系统df -h信息如下 console:/ # df -h Filesystem Size Used Avail Use% Mounted on tmpfs 3.9G 856K 3.9G 1% /dev tmpfs 3.9G 0 3.9G 0% /mnt /dev/block/sda6 11M 104K 11M 1% /metadata /dev/block/dm-0 5.9G 3.6G 2.2G 63% / /dev/block/dm-5 8.2G 444M 7.7G 6% /mnt/scratch overlay 8.2G 444M 7.7G 6% /vendor overlay 8.2G 444M 7.7G 6% /product overlay 8.2G 444M 7.7G 6% /system_ext overlay 8.2G 444M 7.7G 6% /odm tmpfs 3.9G 0 3.9G 0% /apex tmpfs 3.9G 264K 3.9G 1% /linkerconfig /dev/block/sda9 58M 24K 58M 1% /persist /dev/block/sda10 32G 1.6G 30G 6% /data tmpfs 3.9G 0 3.9G 0% /data_mirror /dev/block/sda8 1.9G 24K 1.9G 1% /data/vendor/kdump /dev/fuse 32G 1.6G 30G 6% /mnt/user/0/emulated /dev/fuse 32G 1.6G 30G 6% /mnt/user/10/emulated 三、分区操作实操 1查看可以开始使用的第一个簇 console:/ # sgdisk --first-in-largest /dev/block/sda 14996480 通过上面的分区详情也可以看到userdata最后一个簇是14996479接下来可以使用的簇就是14996480与上面指令得到的一致。 做地址对齐后的第一个可用簇 console:/ # sgdisk --first-aligned-in-largest /dev/block/sda 14996480 (2)查看可以使用的最后一个簇 console:/ # sgdisk --end-of-largest /dev/block/sda 16777210 如果希望将剩余所有空间都划分出去可以使用此指令查看最后一个簇。 3新建一个test分区 console:/ # sgdisk --new 11:0:0 /dev/block/sda Warning: The kernel is still using the old partition table. The new table will be used at the next reboot or after you run partprobe(8) or kpartx(8) The operation has completed successfully. console:/ # sgdisk --print /dev/block/sda Disk /dev/block/sda: 16777216 sectors, 64.0 GiB Sector size (logical/physical): 4096/4096 bytes Disk identifier (GUID): 54054CFA-8B64-425D-A63F-B6B6F795C66E Partition table holds up to 128 entries Main partition table begins at sector 2 and ends at sector 5 First usable sector is 6, last usable sector is 16777210 Partitions will be aligned on 256-sector boundaries Total free space is 250 sectors (1000.0 KiB)Number Start (sector) End (sector) Size Code Name1 256 511 1024.0 KiB 8300 misc2 512 16895 64.0 MiB 8300 boot_a3 16896 33279 64.0 MiB 8300 boot_b4 33280 33535 1024.0 KiB 8300 dtb_a5 33536 33791 1024.0 KiB 8300 dtb_b6 33792 37887 16.0 MiB 8300 metadata7 37888 6067199 23.0 GiB 8300 super8 6067200 6591487 2.0 GiB 8300 kdump9 6591488 6607871 64.0 MiB 8300 persist10 6607872 14996479 32.0 GiB 8300 userdata11 14996480 16777210 6.8 GiB 8300 sgdisk --new 11:0:0 /dev/block/sda 11代表分区序号即sda11,中间的0代表起始簇为第一个可用地址最后的0代表结束簇为最后一个可用地址。两个都为0即把剩余空间全部划分给新分区。 修改分区名字 console:/ # sgdisk --change-name 11:test /dev/block/sda Setting name! partNum is 10 Warning: The kernel is still using the old partition table. The new table will be used at the next reboot or after you run partprobe(8) or kpartx(8) The operation has completed successfully. console:/ # sgdisk --print /dev/block/sda Disk /dev/block/sda: 16777216 sectors, 64.0 GiB Sector size (logical/physical): 4096/4096 bytes Disk identifier (GUID): 54054CFA-8B64-425D-A63F-B6B6F795C66E Partition table holds up to 128 entries Main partition table begins at sector 2 and ends at sector 5 First usable sector is 6, last usable sector is 16777210 Partitions will be aligned on 256-sector boundaries Total free space is 250 sectors (1000.0 KiB)Number Start (sector) End (sector) Size Code Name1 256 511 1024.0 KiB 8300 misc2 512 16895 64.0 MiB 8300 boot_a3 16896 33279 64.0 MiB 8300 boot_b4 33280 33535 1024.0 KiB 8300 dtb_a5 33536 33791 1024.0 KiB 8300 dtb_b6 33792 37887 16.0 MiB 8300 metadata7 37888 6067199 23.0 GiB 8300 super8 6067200 6591487 2.0 GiB 8300 kdump9 6591488 6607871 64.0 MiB 8300 persist10 6607872 14996479 32.0 GiB 8300 userdata11 14996480 16777210 6.8 GiB 8300 test 注意重启生效 4新建一个指定大小的分区 新建一个2G大小分区 console:/ # sgdisk --new 11:14996480:2G /dev/block/sda Warning: The kernel is still using the old partition table. The new table will be used at the next reboot or after you run partprobe(8) or kpartx(8) The operation has completed successfully. console:/ # sgdisk --print /dev/block/sda Disk /dev/block/sda: 16777216 sectors, 64.0 GiB Sector size (logical/physical): 4096/4096 bytes Disk identifier (GUID): 54054CFA-8B64-425D-A63F-B6B6F795C66E Partition table holds up to 128 entries Main partition table begins at sector 2 and ends at sector 5 First usable sector is 6, last usable sector is 16777210 Partitions will be aligned on 256-sector boundaries Total free space is 1256693 sectors (4.8 GiB)Number Start (sector) End (sector) Size Code Name1 256 511 1024.0 KiB 8300 misc2 512 16895 64.0 MiB 8300 boot_a3 16896 33279 64.0 MiB 8300 boot_b4 33280 33535 1024.0 KiB 8300 dtb_a5 33536 33791 1024.0 KiB 8300 dtb_b6 33792 37887 16.0 MiB 8300 metadata7 37888 6067199 23.0 GiB 8300 super8 6067200 6591487 2.0 GiB 8300 kdump9 6591488 6607871 64.0 MiB 8300 persist10 6607872 14996479 32.0 GiB 8300 userdata11 14996480 15520767 2.0 GiB 8300 5 查看分区详情 console:/ # sgdisk --info 11 /dev/block/sda Partition GUID code: 0FC63DAF-8483-4772-8E79-3D69D8477DE4 (Linux filesystem) Partition unique GUID: AEA8DD0F-C48F-4177-BD08-C29F28910AD8 First sector: 14996480 (at 57.2 GiB) Last sector: 15520767 (at 59.2 GiB) Partition size: 524288 sectors (2.0 GiB) Attribute flags: 0000000000000000 Partition name: 6删除一个分区 console:/ # sgdisk --delete 11 /dev/block/sda Warning: The kernel is still using the old partition table. The new table will be used at the next reboot or after you run partprobe(8) or kpartx(8) The operation has completed successfully. 11代表/dev/block/sda11这个分区需要重启才能生效 四、结语 以上就是常用的分区操作还有一些其他的操作可以根据help信息自行尝试。 说明Android自带的sgdisk help信息不友好看了后不清楚参数应该如何添加。Android的sgdisk是从linux移植而来使用方法和Ubuntu上的sgdisk基本一样可以参考Ubuntu的help信息。 也可以参考https://www.cnblogs.com/mountain2011/p/9622001.html  Ubuntu sgdisk使用帮助 # sgdisk --help Usage: sgdisk [OPTION...] device-A, --attributeslist|[partnum:show|or|nand|xor||set|clear|toggle|get[:bitnum|hexbitmask]] operate on partition attributes-a, --set-alignmentvalue set sector alignment-b, --backupfile backup GPT to file-c, --change-namepartnum:name change partitions name-C, --recompute-chs recompute CHS values in protective/hybrid MBR-d, --deletepartnum delete a partition-D, --display-alignment show number of sectors per allocation block-e, --move-second-header move second header to end of disk-E, --end-of-largest show end of largest free block-f, --first-in-largest show start of the largest free block-F, --first-aligned-in-largest show start of the largest free block, aligned-g, --mbrtogpt convert MBR to GPT-G, --randomize-guids randomize disk and partition GUIDs-h, --hybridpartnum[:partnum...][:EE] create hybrid MBR-i, --infopartnum show detailed information on partition-j, --move-main-tablesector adjust the location of the main partition table-l, --load-backupfile load GPT backup from file-L, --list-types list known partition types-m, --gpttombrpartnum[:partnum...] convert GPT to MBR-n, --newpartnum:start:end create new partition-N, --largest-newpartnum create largest possible new partition-o, --clear clear partition table-O, --print-mbr print MBR partition table-p, --print print partition table-P, --pretend make changes in memory, but dont write them-r, --transposepartnum:partnum transpose two partitions-R, --replicatedevice_filename replicate partition table-s, --sort sort partition table entries-S, --resize-tablenumparts resize partition table-t, --typecodepartnum:{hexcode|GUID} change partition type code-T, --transform-bsdpartnum transform BSD disklabel partition to GPT-u, --partition-guidpartnum:guid set partition GUID-U, --disk-guidguid set disk GUID-v, --verify check partition table integrity-V, --version display version information-z, --zap zap (destroy) GPT (but not MBR) data structures-Z, --zap-all zap (destroy) GPT and MBR data structuresHelp options:-?, --help Show this help message--usage Display brief usage message
http://www.zqtcl.cn/news/543167/

相关文章:

  • 网站设计大概流程惠城区龙丰街道
  • 游戏平台十大排名南宁seo优化公司
  • 佛山外贸网站建设方案企业管理控制系统
  • 分类信息网站如何做排名品牌建设卓有成效
  • 企业网站报价方案模板下载营销软件crm
  • 湛江网站开发哪家专业东莞营销型手机网站建设
  • 做个外贸的网站不懂英语咋做做网站 嵌入支付
  • 官方模板关键字生成的代码添加在网站的什么地方?网站 建设 培训 视频
  • 做网站时图片要切片有什么作用网站导航栏模板怎么做
  • 网站做数据分析网站开发为什么不用cgi了
  • 有了网址可以建网站吗软件外包项目网站
  • 威海设计网站的单肩包自定义页面设计模板
  • 制作一个网站首页中国建设个人网上银行官网
  • 厦门开发网站公司购买手表网站
  • 网站模板排名vs做网站加背景
  • 思途旅游网站建设系统郴州新网招聘
  • 婚庆公司网站模板下载海域装饰
  • 微信小程序是干什么用的永康网站优化
  • 网站seo是什么谷歌海外广告投放
  • 江苏省 建设 注册中心网站首页淮南建筑网
  • 网站备案核wordpress页面菜单
  • 凤阳县城乡建设局网站设计本app下载
  • 网站建设实用教程网站后台制作表格
  • 微信官方网站注册新开的网页游戏平台
  • 福州专业建站网站代码的重点内容是什么
  • jsp网站架构网站设计的主要内容
  • html电子商务网站模板wordpress 随机阅读数
  • 湖南省军区强军网网站群建设项目免费网页托管
  • 网站背景图政协网站 两学一做专题研讨
  • 买域名建网站郑州做网站优化运营商