# Uploading pdf to assest getting error: The file could not be uploaded because the destination "private://farm/asset/2022-04" is invalid

**URL:** <https://farmos.discourse.group/t/uploading-pdf-to-assest-getting-error-the-file-could-not-be-uploaded-because-the-destination-private-farm-asset-2022-04-is-invalid/1219>\
**Category:** Hosting farmOS\
**Tags:** support-request\
**Created:** [April 15, 2022, 2:06pm UTC](https://farmos.discourse.group/t/uploading-pdf-to-assest-getting-error-the-file-could-not-be-uploaded-because-the-destination-private-farm-asset-2022-04-is-invalid/1219 "2022-04-15T14:06:46Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![trippi](https://yyz2.discourse-cdn.com/free1/user_avatar/farmos.discourse.group/trippi/32/610_2.png) [@trippi](https://farmos.discourse.group/u/trippi)\
**Post date:** [April 15, 2022, 2:27pm UTC](https://farmos.discourse.group/t/uploading-pdf-to-assest-getting-error-the-file-could-not-be-uploaded-because-the-destination-private-farm-asset-2022-04-is-invalid/1219/4 "2022-04-15T14:27:30Z")

</div>

Hey, thanks. I have, while waiting for a reply, continued looking through the forum and found a solution that worked. I did edit the settings.php adding the line " `$settings[‘file_private_path’] = ‘/opt/drupal/web/sites/default/private/files’;` " but removing the preceding slash from in front of opt/. Also a hard server reboot did nothing I had to clear the cache in admin - config - development - performance. I have only uploaded one pdf thus far but it seems to be working. Thanks again for the fast reply

I followed this post for the most part:

> [@KML import in 2.x](https://farmos.discourse.group/t/kml-import-in-2-x/1108):
>
> I tried importing a KML file on a self hosted server and got the following error message Error message The file could not be uploaded because the destination " private://kml " is invalid. Any ideas how one gets around this?

---

_[View the full topic](https://farmos.discourse.group/t/uploading-pdf-to-assest-getting-error-the-file-could-not-be-uploaded-because-the-destination-private-farm-asset-2022-04-is-invalid/1219)._
