# Incorrect saving a lead with avatar.

**URL:** https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099
**Category:** Product Support
**Created:** [July 28, 2015, 11:56am UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099 "2015-07-28T11:56:41Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![slawek.kow](https://avatars.discourse-cdn.com/v4/letter/s/898d66/32.png) [@slawek.kow](https://forum.mautic.org/u/slawek.kow)
#### Post date: [July 28, 2015, 11:56am UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/1 "2015-07-28T11:56:41Z")

</div>

hello  
  
Mautic installed on your own hosting.  
  
Incorrect saving a lead with avatar.  
  
  
  
When saving a lead with an avatar, log says:

Quote:

[2015-07-27 13:49:58] mautic.CRITICAL: Uncaught PHP Exception LogicException: "Unable to guess the mime type as no guessers are available (Did you enable the php\_fileinfo extension?)" at /home/..../public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/MimeType/MimeTypeGuesser.php line 127 {"exception":"[object] (LogicException(code: 0): Unable to guess the mime type as no guessers are available (Did you enable the php\_fileinfo extension?) at /home/..../public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/MimeType/MimeTypeGuesser.php:127)"} []

  
After the power is turned on php\_fileinfo save still not working

Quote:

[2015-07-27 14:41:12] mautic.CRITICAL: Uncaught PHP Exception SymfonyComponentHttpFoundationFileExceptionFileException: "Unable to create the "/media/images/lead\_avatars" directory" at /home/rsw63763/public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/File.php line 134 {"exception":"[object] (Symfony\Component\HttpFoundation\File\Exception\FileException(code: 0): Unable to create the "/media/images/lead\_avatars" directory at /home/rsw63763/public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/File.php:134)"} []

  
This message saying that the application could not create a directory to store avatars.  
After you create this directory manually, the application will further pay the same mistake, and therefore it is impossible for me to accurately determine the cause of such behavior.

---

<div class="post-metadata">

### Author: ![slawek.kow](https://avatars.discourse-cdn.com/v4/letter/s/898d66/32.png) [@slawek.kow](https://forum.mautic.org/u/slawek.kow)
#### Post date: [July 28, 2015, 11:56am UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/2 "2015-07-28T11:56:41Z")

</div>

hello  
Mautic installed on your own hosting.  
Incorrect saving a lead with avatar.

When saving a lead with an avatar, log says:

> [@](#):
>
> [2015-07-27 13:49:58] mautic.CRITICAL: Uncaught PHP Exception LogicException: “Unable to guess the mime type as no guessers are available (Did you enable the php\_fileinfo extension?)” at /home/…/public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/MimeType/MimeTypeGuesser.php line 127 {“exception”:“[object] (LogicException(code: 0): Unable to guess the mime type as no guessers are available (Did you enable the php\_fileinfo extension?) at /home/…/public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/MimeType/MimeTypeGuesser.php:127)”}

After the power is turned on php\_fileinfo save still not working

> [@](#):
>
> [2015-07-27 14:41:12] mautic.CRITICAL: Uncaught PHP Exception SymfonyComponentHttpFoundationFileExceptionFileException: “Unable to create the “/media/images/lead\_avatars” directory” at /home/rsw63763/public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/File.php line 134 {“exception”:“[object] (Symfony\Component\HttpFoundation\File\Exception\FileException(code: 0): Unable to create the “/media/images/lead\_avatars” directory at /home/rsw63763/public\_html/mautic/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/File/File.php:134)”}

This message saying that the application could not create a directory to store avatars.  
After you create this directory manually, the application will further pay the same mistake, and therefore it is impossible for me to accurately determine the cause of such behavior.

---

<div class="post-metadata">

### Author: ![dbhurley](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/dbhurley/32/2_2.png) [@dbhurley](https://forum.mautic.org/u/dbhurley)
#### Post date: [July 28, 2015, 12:00pm UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/3 "2015-07-28T12:00:03Z")

</div>

Thank you for the clear and concise post! It makes it much easier to read the problem and try to help solve it. Based on the last part of your post I think the problem is in the file ownership. Can you verify that the /media/images/lead\_avatars directory is correctly owned by the web or apache user? Typically on a VPS system this is `www:data`. Most of the time when the ownership is not correct the system cannot properly write to the folder (even if you’ve given the forbidden 777 access). 🙂

If this doesn’t work just update this thread and hopefully we’ll have some other ideas to try.

Hope it helps!  
David

---

<div class="post-metadata">

### Author: ![slawek.kow](https://avatars.discourse-cdn.com/v4/letter/s/898d66/32.png) [@slawek.kow](https://forum.mautic.org/u/slawek.kow)
#### Post date: [July 29, 2015, 7:35am UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/4 "2015-07-29T07:35:48Z")

</div>

David, thank you for responding to my call.  
Changing permissions to 777 did not help.  
I do not have a VPS system. I have a regular web hosting. Maybe there is a problem

---

<div class="post-metadata">

### Author: ![slawek.kow](https://avatars.discourse-cdn.com/v4/letter/s/898d66/32.png) [@slawek.kow](https://forum.mautic.org/u/slawek.kow)
#### Post date: [July 29, 2015, 7:37am UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/5 "2015-07-29T07:37:04Z")

</div>

David, thank you for responding to my ticket.  
Changing permissions to 777 did not help.  
I do not have a VPS system. I have a regular web hosting. Maybe there is a problem  
Slawek

---

<div class="post-metadata">

### Author: ![dbhurley](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/dbhurley/32/2_2.png) [@dbhurley](https://forum.mautic.org/u/dbhurley)
#### Post date: [July 29, 2015, 7:22pm UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/6 "2015-07-29T19:22:34Z")

</div>

Hey 🙂

You should absolutely NOT use 777 😉 That’s always dangerous. Rather than changing permissions we need to make sure that the web user is the owner of the directory. How was Mautic installed? Did you upload the files directly?

Thanks!  
David

---

<div class="post-metadata">

### Author: ![slawek.kow](https://avatars.discourse-cdn.com/v4/letter/s/898d66/32.png) [@slawek.kow](https://forum.mautic.org/u/slawek.kow)
#### Post date: [August 6, 2015, 12:31pm UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/7 "2015-08-06T12:31:30Z")

</div>

Hey  
Mautic was installed by Softacolous

Slawek

---

<div class="post-metadata">

### Author: ![silavapi](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/silavapi/32/7424_2.png) [@silavapi](https://forum.mautic.org/u/silavapi)
#### Post date: [February 2, 2020, 10:58pm UTC](https://forum.mautic.org/t/incorrect-saving-a-lead-with-avatar/2099/8 "2020-02-02T22:58:52Z")

</div>


