Linux Cookbook

 < Day Day Up > 

9.17.1 Problem

You have a brand-new disk partition all ready to go to work. But you can't use it yet. A partition by itself is just a chunk of disk. How do you put a filesystem on it?

9.17.2 Solution

Use the commands specific to the filesystem you want to use.

Ext2

# mke2fs /dev/hda3

Ext3

# mke2fs -j /dev/hda3

ReiserFS

# mkreiserfs /dev/hda3

JFS

# mkfs.jfs /dev/hda3

XFS

# mkfs.xfs /dev/hda3

9.17.3 Discussion

mke2fs is for creating Ext2/3 filesystems. It is part of the e2fsprogs package, available from http://e2fprogs.sourceforge.net.

mkreiserfs comes with ReiserFS, as part of reiserfsprogs. Get it from http://www.namesys.com.

mkfs.jfs is part of jfsutils, from http://www-124.ibm.com/jfs/.

mkfs.xfs is part of xfsprogs, which can be downloaded from http://oss.sgi.com/project/xfs.

9.17.4 See Also

  • This chapter's "Introduction," for more information on the four filesystems in this recipe

  • JFS (http://www-124.ibm.com/jfs/)

  • XFS (http://oss.sgi.com/projects/xfs/)

  • ReiserFS (http://www.namesys.com/)

  • Ext2/3 (http://e2fsprogs.sourceforge.net/ext2.html)

     < Day Day Up > 

    Категории