CADViewer / NextCloud

CAD viewing, markup and collaboration on NextCloud for AutoCAD, MicroStation and advanced raster graphics.
GNU Affero General Public License v3.0
22 stars 2 forks source link

AIO Nextcloud 29.0.2 Cadviewer doesn't work with error E127 #92

Open lehakatana opened 1 week ago

lehakatana commented 1 week ago

Fresh installation AIO nextcloud, i tried install Cadviewer via store and from git, result same.

image Can't find anything about error E127

My AIO behind haproxy, Debug said that i have wrong .htaccess, but I did everything according to the guide. content after ### in .htaccess:

DO NOT CHANGE ANYTHING ABOVE THIS LINE

ErrorDocument 403 /index.php/error/403 ErrorDocument 404 /index.php/error/404

Options -MultiViews RewriteRule ^core/js/oc.js$ index.php [PT,E=PATH_INFO:$1] RewriteRule ^core/preview.png$ index.php [PT,E=PATH_INFO:$1] RewriteCond %{REQUEST_FILENAME} !\.(css|js|mjs|svg|gif|png|html|ttf|woff2?|ico|jpg|jpeg|map|webm|mp4|mp3|ogg|wav|flac|wasm|tflite)$ RewriteCond %{REQUEST_FILENAME} !/core/ajax/update\.php RewriteCond %{REQUEST_FILENAME} !/core/img/(favicon\.ico|manifest\.json)$ RewriteCond %{REQUEST_FILENAME} !/(cron|public|remote|status)\.php RewriteCond %{REQUEST_FILENAME} !/ocs/v(1|2)\.php RewriteCond %{REQUEST_FILENAME} !/robots\.txt RewriteCond %{REQUEST_FILENAME} !/(ocs-provider|updater)/ RewriteCond %{REQUEST_URI} !^/\.well-known/(acme-challenge|pki-validation)/.* RewriteCond %{REQUEST_FILENAME} !/richdocumentscode(_arm64)?/proxy.php$ RewriteCond %{REQUEST_FILENAME} !/apps/cadviewer/converter/php/*\.* RewriteRule . index.php [PT,E=PATH_INFO:$1] RewriteBase / SetEnv front_controller_active true DirectorySlash off

i pinned log and full htaccess file call-Api_Conversion_log .txt htaccess.txt

I have classic nextcloud, all works fine after installation and set permissions. But in AIO have problems, help pls!

When i pressed flush cache get error: image

i found command line in Api_conversation_log: $command_line: "/var/www/html/apps/cadviewer/converter//converters/ax2024/linux//ax2023_L64_23_12_130" -i="/var/www/html/apps/cadviewer/converter//converters/files/f1483319627.dwg" -o="/var/www/html/apps/cadviewer/converter//converters/files/f1483319627.svgz" -f="svgz" -model -extents -fpath="/var/www/html/apps/cadviewer/converter//converters/ax2024/linux/fonts/" -lpath="/var/www/html/apps/cadviewer/converter//converters/ax2024/linux/" -xpath="/mnt/ncdata/abystrov/files/"

try run it mannualy with bash or php, get errors image I've tried the full command, but the result is the same.

CADViewer commented 1 week ago

Hello, @lehakatana ,
1) check the content of your /apps/cadviewer/converter/converters/ax2024/linux folder. ls -l 2) check if the converter is alive: ./ax2023_L64_23_12_130 -? 3) check if the converter ax2023_L64_23_12_130 has chmod 755.

let me know your results, thanks!

limimiking commented 3 days ago

Hello, @lehakatana ,

  1. check the content of your /apps/cadviewer/converter/converters/ax2024/linux folder. ls -l
  2. check if the converter is alive: ./ax2023_L64_23_12_130 -?
  3. check if the converter ax2023_L64_23_12_130 has chmod 755.

let me know your results, thanks!

Same issue, here is the output of the command:

Screenshot 2024-07-06 at 15 32 48
limimiking commented 3 days ago

Here's part of the API Conversion log:

exec return1 127
output log:
exec return1 check 127
Q1 contentresponse stream
Q2:svg_creation
Q4: $general_response{"completedAction":"svg_creation","errorCode":"E127","converter":"AutoXchange AX2020","version":"V1.00","userLabel":"fromCADViewerJS","contentLocation":"/mnt/ncdata/groupfolders/4/陈旭/4轴机械臂固定支座.DWG","contentResponse":"stream","contentStreamData":"https://cloud.ylabics.top/apps/cadviewer/converter//php//getFile_09.php?remainOnServer=1&fileTag=f1600966834&Type=svgz"}
Q5: 0 1 $json_response"{\"completedAction\":\"svg_creation\",\"errorCode\":\"E127\",\"converter\":\"AutoXchange AX2020\",\"version\":\"V1.00\",\"userLabel\":\"fromCADViewerJS\",\"contentLocation\":\"\/mnt\/ncdata\/__groupfolders\/4\/\u9648\u65ed\/4\u8f74\u673a\u68b0\u81c2\u56fa\u5b9a\u652f\u5ea7.DWG\",\"contentResponse\":\"stream\",\"contentStreamData\":\"https:\/\/cloud.ylabics.top\/apps\/cadviewer\/converter\/\/php\/\/getFile_09.php?remainOnServer=1&fileTag=f1600966834&Type=svgz\"}"
$json_response = "{\"completedAction\":\"svg_creation\",\"errorCode\":\"E127\",\"converter\":\"AutoXchange AX2020\",\"version\":\"V1.00\",\"userLabel\":\"fromCADViewerJS\",\"contentLocation\":\"\/mnt\/ncdata\/
groupfolders\/4\/\u9648\u65ed\/4\u8f74\u673a\u68b0\u81c2\u56fa\u5b9a\u652f\u5ea7.DWG\",\"contentResponse\":\"stream\",\"contentStreamData\":\"https:\/\/cloud.ylabics.top\/apps\/cadviewer\/converter\/\/php\/\/getFile_09.php?remainOnServer=1&fileTag=f1600966834&Type=svgz\"}"
$post_request_flag=1 $json_response only
LAST BEFORE CALLBACK

limimiking commented 3 days ago

FYI, Nextcloud AIO create a Nextcloud container of Alpine Linux, maybe that's the reason why the converter cannot be executed.

CADViewer commented 2 days ago

Yes @limimiking , Alpine Linux is notorius difficult as a number of libraries are stripped out. Can you try run a sample conversion from the folder ./ax2023_L64_23_12_130 -i=test.dwg -o=test01.svg -f=svg -model -trace , and see if that gives a result. If it cannot run -? then it probably will not run. Can you change to a standard Ubunu container?

limimiking commented 2 days ago

@CADViewer not possible to change the container because it's generated by NextCloud AIO master container. Even if I somehow change it, it will be redeployed after an auto upgrade. It means if you want to use NextCloud AIO, you have to use Alphine Linux for now. I'll try to compile this package on Alphine Linux but I'm not sure it will work, or I hope you can compile a package for Alpine Linux as NextCloud AIO is very convenient for operation and maintenance.

limimiking commented 1 day ago

@CADViewer I can only compile the nodejs package. The backend converter still doesn't work. NextCloud official docker images are switching to Alpine Linux now.