LoginSignup
0
0

More than 1 year has passed since last update.

LinuxのUSBインストールの方法(Mac用)

Posted at

これは自分用の備忘録です。

まずはターミナルを開く。

USBデバイスを接続

$ diskutil list
/dev/disk3 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     FDisk_partition_scheme                        *15.5 GB    disk3
   1:                       0xEF ⁨⁩                        9.0 MB     disk3s2

/dev/disk3の場所は人によって変わるので要確認

$ diskutil eraseDisk MS-DOS UNTITLED /dev/disk3
Unmounting disk
Creating the partition map
Waiting for partitions to activate
Formatting disk3s2 as MS-DOS (FAT) with name UNTITLED
512 bytes per physical sector
/dev/rdisk3s2: 29867504 sectors in 1866719 FAT32 clusters (8192 bytes/cluster)
bps=512 spc=16 res=32 nft=2 mid=0xf8 spt=32 hds=255 hid=411648 drv=0x80 bsec=29896704 bspf=14584 rdcl=2 infs=1 bkbs=6
Mounting disk
Finished erase on disk3

マウントしている状態だとダメなのでアンマウントする

$ diskutil unmountDisk /dev/disk3
Unmount of all volumes on disk3 was successful

ISOファイルをダウンロードしたディレクトリに移動する。
移動しないと次のコマンドでエラーになる
今回の場合はデスクトップ

$ cd Desktop/

最後にUSBに移す

$ sudo dd if=CentOS-7-x86_64-Minimal-2009.iso of=/dev/disk3 bs=1m
973+0 records in
973+0 records out
1020264448 bytes transferred in 88.235467 secs (11562974 bytes/sec)

CentOS-7-x86_64-Minimal-2009.isoこの部分は自分のインストールしたファイルによって変更する

使ったlinux : http://ftp.riken.jp/Linux/centos/7.9.2009/isos/x86_64/

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0