Quantcast
Channel: Effect of HOME on libreoffice to convert to pdf as non-root user - Super User
Viewing all articles
Browse latest Browse all 2

Effect of HOME on libreoffice to convert to pdf as non-root user

$
0
0

I installed libreoffice-headless and can convert documents when logged on as root. I then tried doing so as another user, and it didn't show an error, but didn't convert the file. I then found that if I get rid of the HOME=/tmp/ayb, it works with the other user. Doesn't HOME=/tmp/ayb just allow files to default to this directory if not specified? (Sorry, I tried to search "Linux HOME", but as you probably expect, received a bunch of non-relevant results). If not, what is the purpose of specifying HOME? Why does setting HOME prevent it from converting on non-root users? Note that /tmp and /tmp/ayb or both 0777. Thank you

[root@desktop ~]# yum install libreoffice-headless[root@desktop ~]# yum install libreoffice-writer[root@desktop ~]# ls -ltotal 48-rwxrwxrwx. 1 NotionCommotion NotionCommotion 48128 Jul 30 02:38 document_34.doc[root@desktop ~]# HOME=/tmp/ayb; /usr/bin/libreoffice --headless -convert-to pdf --outdir /tmp/ayb /tmp/ayb/document_34.docconvert /tmp/ayb/document_34.doc -> /tmp/ayb/document_34.pdf using writer_pdf_Export[root@desktop ~]# rm d*.pdfrm: remove regular file `document_34.pdf'? y[root@desktop ~]# /usr/bin/libreoffice --headless -convert-to pdf --outdir /tmp/ayb /tmp/ayb/document_34.docconvert /tmp/ayb/document_34.doc -> /tmp/ayb/document_34.pdf using writer_pdf_Export[root@desktop ~]# rm d*.pdfrm: remove regular file `document_34.pdf'? y[root@desktop ~]# su NotionCommotionsh-4.1$ HOME=/tmp/ayb; /usr/bin/libreoffice --headless -convert-to pdf --outdir /tmp/ayb /tmp/ayb/document_34.docsh-4.1$ rm d*.pdfrm: cannot remove `d*.pdf': No such file or directorysh-4.1$ /usr/bin/libreoffice --headless -convert-to pdf --outdir /tmp/ayb /tmp/ayb/document_34.docsh-4.1$ rm d*.pdfrm: cannot remove `d*.pdf': No such file or directorysh-4.1$ exitexit[root@desktop ~]# su NotionCommotionsh-4.1$ /usr/bin/libreoffice --headless -convert-to pdf --outdir /tmp/ayb /tmp/ayb/document_34.docconvert /tmp/ayb/document_34.doc -> /tmp/ayb/document_34.pdf using writer_pdf_Exportsh-4.1$ rm d*.pdfsh-4.1$ HOME=/tmp/ayb; /usr/bin/libreoffice --headless -convert-to pdf --outdir /tmp/ayb /tmp/ayb/document_34.docsh-4.1$ rm d*.pdfrm: cannot remove `d*.pdf': No such file or directorysh-4.1$ /usr/bin/libreoffice --headless -convert-to pdf --outdir /tmp/ayb /tmp/ayb/document_34.docsh-4.1$ rm d*.pdfrm: cannot remove `d*.pdf': No such file or directorysh-4.1$

Viewing all articles
Browse latest Browse all 2

Latest Images

Trending Articles





Latest Images