Skip to content

Instantly share code, notes, and snippets.

@hdyen
Last active August 29, 2015 14:08
Show Gist options
  • Save hdyen/5a5a049cd9511c7dd8a7 to your computer and use it in GitHub Desktop.
Save hdyen/5a5a049cd9511c7dd8a7 to your computer and use it in GitHub Desktop.

在 OS X 上製做 Ubuntu USB 安裝碟

  1. 下載 Ubuntu Desktop
  1. .iso 檔轉換成 .dmg
hdiutil convert -format UDRW -o ~/path/to/ubuntu.dmg ~/path/to/ubuntu.iso
  1. 判斷 USB stick 的裝置代碼
  2. 確認 USB stick 未插入電腦,並執行
diskutil list
  1. 插入 USB stick,再次執行 diskutil list,比對差異,找出裝置使用代碼,如 /dev/disk3

  2. 執行

diskutil unmountDisk /dev/diskN

diskN 以你在步驟 3 找出的快閃裝置代碼取代,如 disk3

  1. 執行
sudo dd if=/path/to/ubuntu.dmg of=/dev/rdiskN bs=1m

/dev/rdisk 取代 /dev/disk,在速度上可能會快一點。

  1. 執行
diskutil eject /dev/diskN

REFERENCES

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment