Linux Jiuyin Mantra: Shadowless Sword Fragment 4 (create virtual memory --swap)

Create virtual memory --swap

1. Create a partition, change the format to 82, the format required for swap, and then format

fdisk /dev/sdb

 

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-13054, default 1): 
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-13054, default 13054): +2G

Command (m for help): t

 

Command (m for help): p

Disk /dev/sdb: 107.4 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1         262     2104483+  82  Linux swap / Solaris

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324893135&siteId=291194637