# Fail to auto convert odt to pdf

**URL:** <https://www.dolibarr.org/forum/t/fail-to-auto-convert-odt-to-pdf/23478>\
**Category:** Other native modules\
**Created:** [March 17, 2023, 9:15am UTC](https://www.dolibarr.org/forum/t/fail-to-auto-convert-odt-to-pdf/23478 "2023-03-17T09:15:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![trekmorris](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/t/dfb087/32.png) [@trekmorris](https://www.dolibarr.org/forum/u/trekmorris)\
**Post date:** [March 17, 2023, 9:15am UTC](https://www.dolibarr.org/forum/t/fail-to-auto-convert-odt-to-pdf/23478/1 "2023-03-17T09:15:54Z")

</div>

When i set " MAIN\_ODT\_AS\_PDF " in " Other setup " , and set value to " libreoffice " in debian host .  
It will show the error as below .

 ![image](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/7/7cae89bfacb936859ac1ca09945f29c3da4bba80.png)

But if i copy the command to host to execute , it will work fine to convert the odt file .

The dolibarr version is 16.0.4 . Do i missing something ?

---

<div class="post-metadata">

**Author:** ![citdev](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/c/919ad9/32.png) [@citdev](https://www.dolibarr.org/forum/u/citdev)\
**Post date:** [May 6, 2024, 12:59pm UTC](https://www.dolibarr.org/forum/t/fail-to-auto-convert-odt-to-pdf/23478/2 "2024-05-06T12:59:03Z")

</div>

Hello,

I encountered the same issue but managed to resolve it by changing the owner of the ‘odtaspdf’ folder from root to www-data. To do this on your machine, locate the folder and then execute the following command in the prompt:  
`chown -R www-data /var/lib/dolibarr/documents/temp/odtaspdf`  
 ![image](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/9/9f54765e2919e693546cf09355f832035d35aa2f.png)

That’s it

---

<div class="post-metadata">

**Author:** ![trekmorris](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/t/dfb087/32.png) [@trekmorris](https://www.dolibarr.org/forum/u/trekmorris)\
**Post date:** [May 6, 2024, 10:50pm UTC](https://www.dolibarr.org/forum/t/fail-to-auto-convert-odt-to-pdf/23478/3 "2024-05-06T22:50:16Z")

</div>

Hi

Thanks for your reply , i have tried that and work fine .
