2、打开终端(ctrl+alt+T),首先创建root用户的密码,然后切换的root登入进行后续操作:
创建密码:sudo passwd
输入密码:root123
确认密码:root123
切换到root:su
root@ubuntu:/home/ubuntu# fdisk -l Disk /dev/sda: 500.1 GB, 500107862016 bytes 255 heads, 63 sectors/track, 60801 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: 0xc92c203c Device Boot Start End Blocks Id System /dev/sda1 * 1 7833 62918541 7 HPFS/NTFS /dev/sda2 7834 60801 425465429+ f W95 Ext'd (LBA) /dev/sda5 7834 18277 83891398+ 7 HPFS/NTFS /dev/sda6 18278 31332 104864256 7 HPFS/NTFS /dev/sda7 31333 44387 104864256 7 HPFS/NTFS /dev/sda8 44388 53615 74117937+ 7 PFS/NTFS /dev/sda9 57443 60801 26981136 7 HPFS/NTFS /dev/sda10 56938 57442 4051968 82 Linux swap /Solaris/dev/sda11 53615 56433 22634496 83 Linux /dev/sda12 56433 56937 4052992 82 Linux swap /Solaris Partition table entries are not in disk order找出ID为83的一行(上面红色区域),记下ubuntu系统所在分区(我的为/dev/sda12).