準備 CentOS 6 efidisk

  1. CentOS 6 ISO 檔有 efidisk.img 檔,DYW 系統中也有。
    [root@dywmac ~]# cd /var/ftp/pub/centos6/images/
    [root@dywmac images]# ll efidisk.img
    -rw-r--r--. 1 root root 33896448 Aug 25  2012 efidisk.img
    
  2. 使用 parted 查看 efidisk.img 分割是由 17408 Byte 開始。
    [root@dywmac images]# parted efidisk.img 
    GNU Parted 2.1
    Using /var/ftp/pub/centos6/images/efidisk.img
    Welcome to GNU Parted! Type 'help' to view a list of commands.
    (parted) u                                                                
    Unit?  [compact]? B                                                       
    (parted) print                                                            
    Model:  (file)
    Disk /var/ftp/pub/centos6/images/efidisk.img: 33896448B
    Sector size (logical/physical): 512B/512B
    Partition Table: gpt
    
    Number  Start   End        Size       File system  Name                  Flags
     1      17408B  33879551B  33862144B  fat16        EFI System Partition  boot
    
    (parted) quit
    
  3. 掛載 efidisk.img 中的第一個分割區在 /mnt/efi 目錄。
    [root@dywmac images]# mount -oloop,offset=17408 efidisk.img /mnt/efi/
    
  4. 查看 /mnt/efi 目錄有 UEFI 開機相關檔案。
    [root@dywmac images]# ll /mnt/efi/
    total 2
    drwxr-xr-x. 3 root root 2048 May 13  2010 EFI
    [root@dywmac images]# ll /mnt/efi/EFI/BOOT/
    total 32900
    -rwxr-xr-x. 1 root root      156 May 13  2010 BOOTX64.conf
    -rwxr-xr-x. 1 root root   226825 May 13  2010 BOOTX64.efi
    -rwxr-xr-x. 1 root root 29881604 May 13  2010 initrd.img
    -rwxr-xr-x. 1 root root    63584 May 13  2010 splash.xpm.gz
    -rwxr-xr-x. 1 root root  3510976 May 13  2010 vmlinuz