Go to main content

Managing Devices in Oracle® Solaris 11.3

Exit Print View

Updated: April 2018
 
 

Creating File Systems on USB Storage Devices

The file systems are automatically mounted on hot-pluggable devices. On certain removable devices, you might need to create the file system after the devices are connected. This section provides some examples of how to create the file systems.

Before you create the file system, ensure that the device is unmounted. To create a file system, use the following command syntax:

# mkfs -F FS-type -o FS-type-specific-options raw-device-file
FS-type

Type of file system you want to create.

FS-type-specific-options

Options that are specific to the type of file system you are creating such as size for FAT file systems.

raw-device-file

Disk partition on which to write the file system.


Note -  You must format USB storage devices first before creating file systems on them. All other mass storage devices require only a file system before you can use them.

The following example shows how to create a PCFS file system on a 100-MB USB memory stick on a SPARC system:

# mkfs -F pcfs /dev/rdsk/c5t0d0s2:c

The following example shows how to create a PCFS file system on a 100-MB USB memory stick on an x86 system:

# mkfs -F pcfs /dev/rdsk/c5t0d0p0:c

The following example shows how to create a legacy UFS file system.

# newfs /dev/rdsk/c0t0d0s6