Cannot allocate memory error in Rails (when creating folder locally) -


i have rails app gives me error once in while:

 errno::enomem 

error coming function:

   def create_folder     new_dir = self.id.to_s     working_dir = '/home/user/files/'    # line causing error:     %x[cd #{working_dir} && mkdir #{new_dir}]     working_dir = working_dir + new_dir + '/'     self.working_dir = working_dir    self.save! 

this error happening controller, upon creation of model calls above mentioned function...

would grateful if points out how deal it..

i cannot see pattern in why happens or when..

just record. error went away moment started using ruby's dir.

so

%x[mkdir nnn] # bad dir.mkdir("bbb") # good. 

Comments

Popular posts from this blog

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -

php - Controller/JToolBar not working in Joomla 2.5 -