What are the system requirements of Magento 2 regarding PHP memory limit (Resource Limits:
I have problems to find these informations in the System Requirements despite the second release candidate has been already pushed out.
The official system requirements (or rather: recommendations) are:
Increase the PHP memory limit to at least 768MB for normal operation or 2GB for testing.
I would only increase it to a higher value if you encounter problems where the memory limit is hit. Then debug and fix these problems, and set the memory limit back to normal when successful.
memory_limit is totally up to you, you have to see how your application behaves. Do not be confused with big numbers. Any script must work as fast as possible and take not much than 3-4 times of its per process memory, which is 60MB x 4 = ~300MB an average. IMHO
768mb is just a precaution, so your server will not melt down or become unresponsive.
In some circumstances it may go beyond, so you have to debug these cases. configure your database and web stack.
Magento 2 limits its memory usage to 768M in the main .htaccess file: https://github.com/magento/magento2/blob/2335247d4ae2dc1e0728ee73022b0a244ccd7f4c/.htaccess#L40
This is the PHP-only limit for a single HTTP request. If your store need to serve 10 HTTP requests simultaneously then you need up to 10 * 768M = 7680M of memory for PHP interpreter only (in reality it is much lower because of cache usage, but there are some memory intensive tasks like compilation, reindexing, some 3rd-systems integrations which sometimes disable its memory limit at all and use a lot of memory).
Also you need some memory for other software environment: MySQL, web server, mail software, operating system, and so on.