-1

I'm new in VPS and very low knowledge on linux.

I was using a Shared hosting from 3 years where I had almost 100 Joomla websites, with 16GB disk space used and 18GB monthly transfer.

On the shared hosting there was Inodes backup failure warning as I have lots of small files, but it was never crashed the server or my sites.

Now I moved into a VPS with 2GB RAM, 50GB Hard drive. After moving to the VPS and moving sites one by one my Inodes limit is exceeded (137%).

Now when I try to Extract a 600MB zip file it says php memory limit exceeded something...... and my server crashed/down.

After contacting hosting provider support they says it's happening because of my inodes used.

Any one please help me, how can I configure the server, so- 1. If there are more files than inodes limit then just deny inodes backup but not server crash. 2. If I upload a large file than server support or use more memory than server has, so just reject the current operation but not server crash.

SAIFUL
  • 3
  • 3

1 Answers1

0

ad inodes - you need to bigger filesystem. Inodes are something like telephone list, each file and directory is listed here so OS can find it easy (it contain metadata of file and adress on drive where data are saved). If you have many tiny files, this list can be full and you cannot create any new file - including temp files, pid files and so on. So you have to limit number of your files of get bigger filesystem.

ad memory limit - you can configure it in php.ini, how many memory php can use. When this limit is reached, PHP just ends with fatal error (it's not crashing server, just error in one request). You have to set this limit upper. But be careful - it's definitelly BAD idea to give PHP whole memory of server. 2GB for extracting of 600MB zip is just too small. Maybe you can use exec() and run unzip as normal bash command.

Ondra Sniper Flidr
  • 2,653
  • 12
  • 18