First on the virtual machine to add a hard disk, that is, "Edit Virtual machine settings" in the inside add a hard disk, are generally SCSI devices.
Specify the hard drive capacity and reboot into the system.
Root User action:
Fdisk-l will see a new setting, if you have a hard drive (sda1, sda2 ...), the new addition should be (/DEV/SDB).
See that the system has identified the hard drive, next we give this hard disk partition, format.
Fdisk/dev/sdb (Of course if you add the IDE settings, will be HDX) x represents the number, the specific information can be found on the Internet.
Fdisk detailed parameter description, can use--help to see, also can search on the Internet, a partition management tool.
I want to add a partition is enough, so select N, create a partition, and then select the partition type, e i selected is the main, and then he will let you enter the size of the partition, I chose the default, is the entire disk space.
Then W save exit!
Finished, partition complete, with fdisk-l view, you will find a/dev/sdb1 if it is ide/dev/hdb1, and so on (if you do not know, you can find Linux disk partition related information).
We can't use this hard drive now, why? No formatting, hehe!
MDFS.EXT3/DEV/SDB1 format the specified partition, and so on, most of the current system is ext3 format, and if you need anything else, MKFS This command helps you to fix it!
The last one is to hook up the hard drive!
My operation is to copy everything under/home to a new disk partition, and of course, note the file permissions and owner attributes.
CP-PR can help you with this, and then delete what's under the original/home/.
Modify/etc/fstab put/dev/sdb1 to/home this section, reboot!
Well, my needs are done!