Skip to content

Instantly share code, notes, and snippets.

@lorentzca
Created December 7, 2014 16:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lorentzca/8e84127331ec943e21e5 to your computer and use it in GitHub Desktop.
Save lorentzca/8e84127331ec943e21e5 to your computer and use it in GitHub Desktop.
update system, initialize disk and swap
#!/bin/bash
yum update -y
resize2fs -p /dev/xvde
mkdir /mnt/store_vol
mount /dev/xvdf /mnt/store_vol/
dd if=/dev/zero of=/mnt/store_vol/swapfile bs=1M count=1024
mkswap /mnt/store_vol/swapfile
swapon /mnt/store_vol/swapfile
@lorentzca
Copy link
Author

Linux インスタンスでの起動時のコマンドの実行でシステムのアップデート、ディスクの拡張、swap領域の作成をする

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