快上网专注成都网站设计 成都网站制作 成都网站建设
成都网站建设公司服务热线:028-86922220

网站建设知识

十年网站开发经验 + 多家企业客户 + 靠谱的建站团队

量身定制 + 运营维护+专业推广+无忧售后,网站问题一站解决

Whatisthedifferencebetweenpageandblockinoperatingsystem?

What is the difference between pages and blocks? A block is the smallest unit of data that an operating system can either write to a file or read from a file.

成都创新互联公司专业提供成都主机托管四川主机托管成都服务器托管四川服务器托管,支持按月付款!我们的承诺:贵族品质、平民价格,机房位于中国电信/网通/移动机房,托管服务器服务有保障!

What exactly is a page? Pages are used by some operating systems instead of blocks. A page is basically a virtual block. And, pages have a fixed size – 4K and 2K are the most commonly used sizes. So, the two key points to remember about pages is that they are virtual blocks and they have fixed sizes.

Why pages may be used instead of blocks Pages are used because they make processing easier when there are many storage devices, because each device may support a different block size. With pages the operating system can deal with just a fixed size page, rather than try to figure out how to deal with blocks that are all different sizes. So, pages act as sort of a middleman between operating systems and hardware drivers, which translate the pages to the appropriate blocks. But, both pages and blocks are used as a unit of data storage.

http://www.programmerinterview.com/index.php/database-sql/page-versus-block/

总结起来,也就是说,像磁盘这样的设备之所以被称为是块设备,是因为其传输数据的基本单元是Block,即使你的目标数据只是文件中的一个字符,操作系统和驱动仍然会读取整个块,将你想要的目标数据给你,块中剩余的数据则保存在一个特定的buffer/cache中。
而块的大小在不同的操作系统上不一定是一样的。
数据在磁盘和内存之间的传输是以块的形式而不是用户需要的特定字节,存储在内存中的数据则是以页的形式来进行管理,当然,汇编指令只知道字节地址~


当前标题:Whatisthedifferencebetweenpageandblockinoperatingsystem?
分享URL:http://6mz.cn/article/jdpcho.html

其他资讯