How to create a swap file on BeagleBone ?

Hello, when I want to create a swap file on BeagleBone green which have 512MB DDR3, what is the preferable size for the swpafile please ?

totally up to your swapping RAM <-> Disk needs, can be 1MB or 10GB…