You can use neither NTFS nor FAT32 for the swap disk. The swap partition has an own file system called "swap", which can be used only for this particular purpose. But you may try to juse a swap-file instead. What I could imagine of would be to use a swap-file and auto-delete the swap file of the other OS on startup. But this would require some tricks with the startup scripts, where I've absolutely no idea.
–
FUZxxlFeb 15 '11 at 19:08

2

The linked "Linux Swap Space Mini-HOWTO" deals with 3.1 and 95/98. I'm not watching MS very carefully, but maybe that's not really up to date. AFAIK, mkswap only marks the file/partition as swap, this is just a security measure so you don't swap in your documents. No idea what Windows does, but I could imagine it relying on the filename and maybe its attributes. I'd go and try it out, if I were you.
–
maaartinusFeb 15 '11 at 19:50

Just for future reference, Linux can indeed use a file for Swap.
–
hexafractionOct 10 '12 at 10:26

2 Answers
2

Windows' swap space is typically a pagefile.sys file stored on the drive. It is given an arbitrary size, and can use no more than that size.

Ubuntu and Linux require a dedicated 'swap' partition or designated swap space. However, the swap space between Linux and Windows are not formatted correctly for each system to understand the other's swap space. This causes the limitation in the ability to share swap space. However, you don't need to share swap space. It acts on the premise of RAM: each bit of memory is filled with data and allocated as its needed. When the data there is not needed, it is marked as being able to be written over. This then means that some other program can come by and overwrite the last allocated area with new data. This cycle then continues.

The actual pagefile.sys file does not need to be shared. Both Windows and Ubuntu ignore the initial contents of their respective swap spaces at startup, so the actual contents do not have to be preserved. They just have to be 'ready.'
–
LeftiumFeb 15 '11 at 19:19

2

@Leftium: No, Linux looks for a valid swap header. That is why you have to format a swap partition with mkswap before you can use it. I'm pretty sure Windows is similar.
–
psusiFeb 15 '11 at 20:11