简体   繁体   English

USB闪存驱动器的扇区大小可以更改吗?

[英]Can sector size of USB flash drive be changed?

我知道可以更改USB闪存驱动器的群集大小,我们也可以更改扇区大小吗?

Sector size isn't a configurable parameter in ATA/SATA/SCSI/etc devices and, from my experience, USB flash drives implement one of these protocols. 在ATA / SATA / SCSI / etc设备中,扇区大小不是可配置的参数,根据我的经验,USB闪存驱动器会实现以下协议之一。 The sector size is reported by the device itself but, even if you could set it to something other than 512, you would likely run into a latent bug somewhere in a driver or file system package that assumed a sector size of 512. 扇区大小由设备本身,而是报道,即使你可以将其设置为超过512个其他的东西,你可能会在假定的512扇区大小的驱动器或文件系统包碰上一个潜在的错误的地方。

There are real reasons for using a sector size like 512, for example, addressing of larger sectors can be done more quickly and efficiently (not just in time but in size/space as well). 使用扇区大小(例如512)的真正原因是,例如,可以更快,更高效地处理较大的扇区(不仅在时间上,而且在大小/空间上)。 Throughput to these devices is also better with something like 512. Consider that, if you could set sector size to something like 16-bytes, you might have less wasted space with 16-byte sectors compared to having a number of half-full 512-byte sectors, but your throughput to the device would probably be worse. 使用512之类的设备,这些设备的吞吐量也更好。请考虑一下,如果您可以将扇区大小设置为16字节之类的东西,那么与16个半字节的扇区相比,使用半满的512-byte可能会减少浪费的空间。字节扇区,但是您到设备的吞吐量可能会更差。 In fact, writing a single 16-byte sector would only be slightly faster than writing a single 512-byte sector. 实际上,写入单个16字节扇区仅比写入单个512字节扇区快一点。 On the other hand, writing 32 16-byte sectors (to write a total of 512 bytes) would likely take longer than writing a single 512 byte sector simply due to the overhead associated with transferring multiple sectors. 另一方面,写32个16字节的扇区(总共写512字节)可能比写一个512字节的扇区要花费更长的时间,这仅仅是因为与传输多个扇区相关的开销。

I would suggest you buy a larger USB flash drive if you are worried about wasting space with 512-byte sectors. 如果您担心浪费512字节扇区的空间,建议您购买更大的USB闪存驱动器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM