Create Swap Space on Amazon EC2 Image
Posted: February 4, 2012 Filed under: Amazon AWS, EC2 | Tags: Amazon AWS, EC2, rds, swapfile 5 CommentsI am creating an Oracle XE database server in Amazon, I know that Amazon has Oracle RDS but I need an inexpense solution for this particular application.
Upon downloading the oracle-xe rpm and trying to install it discovered that you need a swap file space. How therefore do you create a swap file space ?????
sudo su
dd if=/dev/zero of=/swapfile bs=1024 count=1048576
( this should give you 1024MB but in the Amazon world it registers 1023MB AAAARRRGGGHHHH !!!!!) I therefore used the following
Please note to delete a swap file use
swapoff /swapfile
rm /swapfile
dd if=/dev/zero of=/swapfile bs=1536 count=1572864
/sbin/mkswap /swapfile
/sbin/swapon /swapfile
/sbin/swapon -s
I found this on a site burried away and thought I would add this to post to bolster the chances of you finding something 🙂
[…] need a swap space on the server to allow Oracle to be installed this can be found at survivalguides create swap space written by […]
[…] need a swap space on the server to allow Oracle to be installed this can be found at survivalguides create swap space written by […]
Hey thanks, this is helpful!
Hi Frank
Your welcome, I get a fair amount of hits, and not many comments. I wonder sometimes if the notes are useful
Cheers
Alistair
[…] not worry just follow these instructions on creating swap space and then get right back to this […]