2
我似乎无法获得wkhtmltopdf
在用户帐户上工作。Wkhtmltopdf用户权限
作为根用户:
wkhtmltopdf -V
wkhtmltopdf http://google.com google.pdf
上述两种工作。但作为一个普通用户,我得到一个错误:
wkhtmltopdf -V
wkhtmltopdf: error while loading shared libraries: libQtWebKit.so.4: cannot open shared object file: No such file or directory
显然,wkhtmltopdf
工作并正确安装,因为它的工作原理为root用户,但不是所有的用户。
我已经尝试设置权限:
[[email protected] ~]# chmod 755 /root/wkqt/
[[email protected] ~]# chmod 755 /root/wkqt/lib/
[[email protected] ~]# chmod 755 /root/wkhtmltopdf-qt/
[[email protected] ~]# chmod 755 /root/wkhtmltopdf-qt/lib/
[[email protected] ~]# chmod 644 /root/wkqt/lib/*so*
[[email protected] ~]# chmod 644 /root/wkhtmltopdf-qt/lib/*so*
我也尝试添加到visudo
:
motorconne localhost=/bin/wkhtmltopdf
motorconne localhost=/root/wkhtmltopdf-qt/lib/libQtWebKit.so.4
但仍没有运气。有任何想法吗?
你是否以root身份安装它? – 2012-07-31 12:32:02
是的,它是作为根安装的 – garethhallnz 2012-07-31 21:56:24
尝试安装它作为打算使用它的用户 – 2012-08-01 05:54:09