Re: [Fuego] Issue with unoconv package inside fuego container
Dhinakar Kalyanasundaram <[email protected]>
| Newsgroups | dev.linux.lists.fuego |
|---|---|
| Message-ID | <20190906113541epcms5p5796da8b0b3c8b10ecbd72e35b7903c87@epcms5p5> |
Hi Tim, Thank you very much for the effort. In the previous fuego version I just installed unoconv, it installed the relevant dependent libraries (like LibreOffice) and it used to work out of the box without any issue and it was headless. But of course it was taking some 300MB of space. I understand it's overkill to install unoconv and libreoffice into the Fuego container. As you suggested, I will try to keep it outside the container and do my conversion there itself. Thank you very much once again. Regards, Dhinakar --------- Original Message --------- Sender : [email protected] <[email protected]> Date : 2019-09-06 10:28 (GMT+5:30) Title : RE: RE: RE: Issue with unoconv package inside fuego container > -----Original Message----- > From: Dhinakar Kalyanasundaram > > Hi Tim, > > Did you find time to checkout unoconv package issue inside fuego container? > > It was working fine in debian-8 (jessie) version. > > But now in the current fuego version (v1.5) which runs debian-8 (stretch), I > get the 'The application cannot be started' issue. I'm not an expert at debugging Debian package issues, but here are some thoughts that come to mind. Not only did we update from Jessie to stretch in the v1.5 release, but we also switched from a 'full' docker image of Debian to the 'slim' docker image, as the base for the Fuego image. I didn't have time to try what I describe next, but you might change the FROM line in the Fuego dockerfile from: FROM debian:stretch-slim to FROM debian:stretch and do a rebuild of the Fuego image, to see if that affects the issue. My overall impression of your solution here is that it's overkill to install unoconv and libreoffice into the Fuego container. When I tried this, it added many packages and over 300MB of new material to the image. This is a bit unsettling, as I think it's best not to install and/or upgrade a lot of material in the Fuego container. It's possible this will destabilize other packages in the system, or break dependencies inside the Fuego distribution. I think a better architecture for what you're doing would be to execute the unoconv stuff on your host (outside the container). If you are converting from excel spreadsheets or html created by Fuego, you should be able to access these on the host in the fuego-rw/logs directory (or wherever they get put under fuego-rw). The Fuego container is intended to be run headless (that is, without any graphics system), so I'm not sure how libreoffice is supposed to execute in that environment. When I tried to run unoconv as a listener, I got the following: --- root@timdesk:/# unoconv -- listener unoconv: RuntimeException during import phase: Office probably died. Unsupported URL <listener>: "from LoadEnv::initializeLoading" --- I'm guessing that this is because I can't invoke libreoffice inside the container. I get an error: "Failed to open display" Out of curiosity, do you have a libreoffice instance running on your host? I don't know much about the UNO protocol, but it appears that unoconv uses a network connection to a running libreoffice instance in order to perform the actual file conversion. I made a test document, called testfile.odt, and put it into the 'transfer' directory under /fuego-rw. Then I did this and it worked inside the container: ---- root@timdesk:/fuego-rw/transfer# ls testfile.odt root@timdesk:/fuego-rw/transfer# unoconv -f pdf testfile.odt root@timdesk:/fuego-rw/transfer# ls testfile.odt testfile.pdf --- I checked the PDF, and the output looked correct. Note that I had libreoffice running on my host. I'm not sure whether unoconv connected to a running libreoffice instance on my host (i.e. at ip address 'localhost'), or connected to a running libreoffice instance inside the Fuego container, or started its own instance of libreoffice inside the container. In any event, I was unable to start a listener, but I was able to successfully execute unoconv inside my Fuego container here. -- Tim > > Regards, > > Dhinakar > > > > > > --------- Original Message --------- > > Sender : Dhinakar Kalyanasundaram <[email protected]> Staff > Engineer/FDS SW /SSIR/Samsung Electronics > > Date : 2019-08-26 13:28 (GMT+5:30) > > Title : RE: RE: Issue with unoconv package inside fuego container > > > > Thanks Tim for the prompt response. > > I am using unoconv to convert the excel report to html, to display test > summary in our management dashboard. > > > > Regards, > > Dhinakar > > > > > > --------- Original Message --------- > > Sender : [email protected] <[email protected]> > > Date : 2019-08-23 23:26 (GMT+5:30) > > Title : RE: Issue with unoconv package inside fuego container > > > > I'll try to take a look at this when I'm back in the office next week. > (I'm currently at Embedded Linux Conference.) > > What are you using unoconv for inside the container? > It looks like you're using it with the spreadsheet files created > by Fuego? > > Just curious. > -- Tim > > > > -----Original Message----- > > From: Dhinakar Kalyanasundaram [mailto:[email protected]] > > Sent: Friday, August 23, 2019 7:07 AM > > To: [email protected] > > Cc: Bird, Timothy <[email protected]>; Dhinakar Kalyanasundaram > > <[email protected]> > > Subject: Issue with unoconv package inside fuego container > > > > Dear Fuego users, > > > > > > > > I was using unoconv utility inside fuego container. > > > > It was working fine in debian-8 (jessie) version. > > > > But now in the current fuego version (v1.5) which runs debian-8 (stretch), I > > get the 'The application cannot be started' issue. > > > > I have installed all the prerequisites such as libreoffice etc. > > > > I have pasted the commands and the outputs below for better > > understanding of the issue. > > > > If any of you cand try and confirm if you are getting the same issue in your > > container it will be helpful to debug the issue. > > > > Thanks. > > > > > > > > root@linux-2030047407:/ <mailto:root@linux-2030047407:/> # apt-get > install > > unoconv > > Reading package lists... Done > > Building dependency tree > > Reading state information... Done > > unoconv is already the newest version (0.7-1.1). > > 0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded. > > > > > > > > root@linux-2030047407:/ <mailto:root@linux-2030047407:/> # apt-get > install > > libreoffice > > Reading package lists... Done > > Building dependency tree > > Reading state information... Done > > libreoffice is already the newest version (1:5.2.7-1+deb9u10). > > 0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded. > > > > > > root@linux-2030047407:/ <mailto:root@linux-2030047407:/> # unoconv -- > > listener > > The application cannot be started. > > The component manager is not available. > > ("Cannot open directory file:///usr/lib/libreoffice/program/services") > > > > > > root@linux-2030047407:/ <mailto:root@linux-2030047407:/> # unoconv -f > > html MergedReport.xlsx > > The application cannot be started. > > The component manager is not available. > > ("Cannot open directory file:///usr/lib/libreoffice/program/services") > > Error: Unable to connect or start own listener. Aborting. > > > > > > Regards, > > > > Dhinakar > > > > > > > > > > > <http://ext.samsung.net/mail/ext/v1/external/status/update?userid=dhina > > > kar.k&do=bWFpbElEPTIwMTkwODIzMTQwNjQ1ZXBjbXM1cDQwNGYwYWIz > > > MjNiZTVmOTc2ODk2NTc5ZDk5YjYxZWIxYiZyZWNpcGllbnRBZGRyZXNzPVRpb > > S5CaXJkQHNvbnkuY29t> > > > > <http://ext.samsung.net/mail/ext/v1/external/status/update?userid=dhina > kar.k&do=bWFpbElEPTIwMTkwOTA1MTM0NzUwZXBjbXM1cDgxMjhhYzIxM > DdlYzBmMDEwYjc0NzhlODIxODI4NmVmNSZyZWNpcGllbnRBZGRyZXNzPVRp > bS5CaXJkQHNvbnkuY29t>
201602111742151_N3WZA6X7.png
(image/png, 32.7 KB) - not displayed