首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >cfdisk中一个分区前面的回勾(`)的含义

cfdisk中一个分区前面的回勾(`)的含义
EN

Unix & Linux用户
提问于 2020-05-08 20:59:31
回答 1查看 70关注 0票数 1

我有一个具有潜在错误分区的磁盘(特定目录中的du -sh *给了我Structure needs cleaning)。我启动了cfdisk /dev/sda来查看分区,我看到的是:

代码语言:javascript
复制
Disk: /dev/sda
Size: 232.9 GiB, 250059350016 bytes, 488397168 sectors
Label: dos, identifier: 0x00000000

    Device Boot Start                        End Sectors                   Size                 Id Type
>>  Free space 2048                       8191 6144 3M
    /dev/sda1 * 8192                      90111 81920                    40M                  e W95 FAT16 (LBA)
    /dev/sda2 90112                     729087 638976                   312M                 83 Linux
    /dev/sda3 729088                    1368063 638976                   312M                 83 Linux
    /dev/sda4 1368064                  488397167 487029104                 232.2G                  f W95 Ext'd (LBA)
    |-Free space 1370112                    1376256 6145 3M
    |-/dev/sda5 1376256                    1417215 40960                    20M                 83 Linux
    |-Free space 1419264                    1425408 6145 3M
    `-/dev/sda6 1425408                  488397167 486971760                 232.2G                 83 Linux

in front of/dev/sda6` 6‘代表什么?

EN

回答 1

Unix & Linux用户

回答已采纳

发布于 2020-05-09 01:00:08

它是基于字符的树表示的一部分,试图说明/dev/sda4与它下面的行之间的关系。它类似于使用tree命令可以获得的目录树的表示,尽管只使用基本的ASCII字符集。

在任何情况下,您可能都会看到类似的情况,即需要使用普通的ASCII和固定宽度的字体来描述树状结构。

代码语言:javascript
复制
This is the main unit
|- this is a sub-unit inside the main unit
|- this is another sub-unit inside the main unit
`- this is the last sub-unit inside the main unit

这种基于文本的树表示存在许多变体。您可能会看到用反斜杠代替反勾号:

代码语言:javascript
复制
This is the main unit
|--- this is a sub-unit
|    \--- this is a sub-sub-unit for the first sub-unit  
|-+- this is a sub-unit that might have sub-sub-units inside it (hidden for now)
\--- this is the last sub-unit inside the main unit

它看起来就像一条从主单元向下的线,分支代表子单元,在最后一个子单元有一个90度的角度,表示这个主单元内的一组子单位在这里结束。除此之外,这些特定的字符并不代表任何特定的东西:它们只是作为树形图中形状合适的部分来选择。

票数 4
EN
页面原文内容由Unix & Linux提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://unix.stackexchange.com/questions/585447

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档