I'm trying to add a swap file on Solaris 10. I have already created a 2GB file
swap.file. Then, I add a swap file with the command:
swap -a /swap.file
which shows an error:
/swap.file: size is invalid
What am I doing wrong?
migrated from stackoverflow.com Jul 11 '12 at 12:30
This question came from our site for professional and enthusiast programmers.
You are likely running a 32 bit kernel. You can just create 2 x 1 GB swap files and add them separately.
Also, for this setting to survive a reboot, you'll also need to add lines to the /etc/vfstab file, eg: