How to create a size-limited file-system

简介:

How to create a size-limited file-system?(loopback device)
1) dd if=/dev/zero of=/h/data/file.img bs=1k count=100000 # ~100M
2) su root
3) losetup /dev/loop1 /h/data/file.img
4) mkfs -t ext3 /dev/loop1 100000
5) mkdir /mnt/small
6) mount -t ext3 /dev/loop1 /mnt/small
7) chown tachyon:tachyon /mnt/small

Please refer to command: losetup, mount



本文转自 zhenjing 博客园博客,原文链接:http://www.cnblogs.com/zhenjing/archive/2011/01/18/loopback.html   ,如需转载请自行联系原作者

相关文章
|
6月前
|
前端开发
Fatal error_ ENOSPC_ System limit for number of file watchers reached, watch '...path...'
Fatal error_ ENOSPC_ System limit for number of file watchers reached, watch '...path...'
53 0
|
安全 关系型数据库 MySQL
xtrabackup 问题“Too many open files”system error number 24
一个MySQL数据库备份的时候出现下面的错误
179 0
SAP WM Storage Type Capacity Check Method 5 (Usage check based on SUT)
SAP WM Storage Type Capacity Check Method 5 (Usage check based on SUT)
SAP WM Storage Type Capacity Check Method 5 (Usage check based on SUT)
|
JavaScript 前端开发 Shell
|
JavaScript 前端开发 Shell
|
Oracle 关系型数据库 Linux
|
存储 安全 数据安全/隐私保护