question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Documents don't get stored back to Nextcloud

See original GitHub issue

Hey, I upgraded yesterday to the latest Onlyoffice documentserver version 5.0.3. But I guess I also experienced this bug in earlier versions so this is not a regression. Changes in the document are present but they don’t get stored on Nextcloud. The newly created document there remains empty. Unforatunately, the interface doesn’t inform the user that something went wrong. It displays the file as saved. In the network activity log of my browser I notice this unfinished request:

Get: https://office.example.com/users/sign_in
Host: office.example.com
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:56.0) Gecko/20100101 Firefox/56.0
Accept: */*
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate, br
Referer: https://office.example.com/web-apps/apps/documenteditor/main/index.html?_dc=0&lang=en&customer=ONLYOFFICE&frameEditorId=iframeEditor
Cookie: _ga=GA1.2.28880319.1502505349; _gitlab_session=c00707e8509c07dba8a1c67a9a5851d8
DNT: 1
Connection: keep-alive

The request returns 404. I’m a bit confused because /users/sign_in seems to refer to my Gitlab instance I also host on the domain. Is there any way to debug this issue further?

Best regards, Jonas

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:15 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
onnycommented, Dec 27, 2017

@alexanderonlyoffice: Yes I build it myself. It’s from my ArchLinux package here https://aur.archlinux.org/packages/onlyoffice-documentserver/ which is using this buildscript https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=onlyoffice-documentserver . Therefore I took the Document Server version from this repo https://github.com/ONLYOFFICE/DocumentServer/releases What’s the best practice to debug this error? Are there any error logs or debug log levels I can check? I also noticed an other error while trying to upload a file to the document server integration example (https://github.com/ONLYOFFICE/document-server-integration):

[2017-12-27 22:45:50.182] [ERROR] nodeJS - sendServerRequest error: docId = -2092860721;url = https://office.***/track?filename=new.docx&useraddress=151.217.***;data = {"key":"-2092860721","status":3,"users":["uid-1"],"actions":[{"type":0,"userid":"uid-1"}],"lastsave":"2017-12-27T20:52:51.916Z","notmodified":false}
Error: Error response: statusCode:500 ;body:
<!DOCTYPE html>
<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title>Error</title>
</head>
<body>
    <hgroup>
        <h1>Error.</h1>
        <h2>An error occurred while processing your request.</h2>
    </hgroup>
    <div>Cannot read property &#39;length&#39; of undefined</div>
</body>
</html>
    at Request._callback (/usr/share/webapps/onlyoffice/documentserver/server/Common/sources/utils.js:269:18)
    at Request.self.callback (/usr/share/webapps/onlyoffice/documentserver/server/Common/node_modules/request/request.js:186:22)
    at Request.emit (events.js:159:13)
    at Request.<anonymous> (/usr/share/webapps/onlyoffice/documentserver/server/Common/node_modules/request/request.js:1163:10)
    at Request.emit (events.js:159:13)
    at IncomingMessage.<anonymous> (/usr/share/webapps/onlyoffice/documentserver/server/Common/node_modules/request/request.js:1085:12)
    at Object.onceWrapper (events.js:254:19)
    at IncomingMessage.emit (events.js:164:20)
    at endReadableNT (_stream_readable.js:1054:12)
    at _combinedTickCallback (internal/process/next_tick.js:138:11)

ps. We can meet up if you’re on the Chaos Communication Congress in Leipzig (Germany) 😃

edit: I set log level to DEBUG and have additional output concerning the Nextcloud app:

Dec 27 23:07:08 http-new node[13466]: [2017-12-27 23:07:08.140] [INFO] nodeJS - data.type = isSaveLock id = 578094_1514203614
Dec 27 23:07:08 http-new node[13466]: [2017-12-27 23:07:08.197] [INFO] nodeJS - data.type = saveChanges id = 578094_1514203614
Dec 27 23:07:08 http-new node[13466]: [2017-12-27 23:07:08.198] [INFO] nodeJS - Start saveChanges docid: 578094_1514203614
Dec 27 23:07:08 http-new node[13466]: [2017-12-27 23:07:08.199] [INFO] nodeJS - saveChanges docid: 578094_1514203614 ; deleteIndex: -1 ; startIndex: 526 ; length: 40
Dec 27 23:07:10 http-new node[13466]: [2017-12-27 23:07:10.839] [INFO] nodeJS - Connection closed or timed out: userId = onny6 isCloseConnection = true docId = 578094_1514203614
Dec 27 23:07:15 http-new node[13466]: [2017-12-27 23:07:15.884] [DEBUG] nodeJS - Start saveFromChanges: docId = 578094_1514203614
Dec 27 23:07:15 http-new node[13462]: [2017-12-27 23:07:15.956] [DEBUG] nodeJS - Start Task(id=578094_1514203614_7480)
Dec 27 23:07:15 http-new node[13462]: [2017-12-27 23:07:15.960] [DEBUG] nodeJS - downloadFileFromStorage list 578094_1514203614/Editor.bin (id=578094_1514203614)
Dec 27 23:07:15 http-new node[13462]: [2017-12-27 23:07:15.961] [DEBUG] nodeJS - downloadFileFromStorage complete(id=578094_1514203614_7480)
Dec 27 23:07:15 http-new node[13462]: [2017-12-27 23:07:15.962] [DEBUG] nodeJS - downloadFileFromStorage list  (id=578094_1514203614_7480)
Dec 27 23:07:15 http-new node[13466]: [2017-12-27 23:07:15.995] [DEBUG] nodeJS - AddTask saveFromChanges: docId = 578094_1514203614
Dec 27 23:07:20 http-new node[13462]: [2017-12-27 23:07:20.296] [ERROR] nodeJS - stdout (id=578094_1514203614_7480):
Dec 27 23:07:20 http-new node[13462]: [2017-12-27 23:07:20.297] [ERROR] nodeJS - stderr (id=578094_1514203614_7480):
Dec 27 23:07:20 http-new node[13462]: [2017-12-27 23:07:20.297] [ERROR] nodeJS - ExitCode (code=0;signal=SIGSEGV;error:-80;id=578094_1514203614_7480)
Dec 27 23:07:20 http-new node[13462]: [2017-12-27 23:07:20.381] [DEBUG] nodeJS - processUploadToStorage error complete(id=578094_1514203614_7480)
Dec 27 23:07:20 http-new node[13462]: [2017-12-27 23:07:20.382] [DEBUG] nodeJS - output (data={"cmd":{"c":"sfc","id":"578094_1514203614","userid":"onny","data":null,"title":"output.","outputformat":2055,"outputpath":"output.","status_info":-80,"savekey":"578094_1514203614_7480","useractionid":"onny","nobase64":true}};id=578094_1514203614_7480)
Dec 27 23:07:20 http-new node[13462]: [2017-12-27 23:07:20.382] [DEBUG] nodeJS - postProcess (id=578094_1514203614_7480)
Dec 27 23:07:20 http-new node[13462]: [2017-12-27 23:07:20.383] [DEBUG] nodeJS - deleteFolderRecursive (id=578094_1514203614_7480)
Dec 27 23:07:20 http-new node[13466]: [2017-12-27 23:07:20.387] [DEBUG] nodeJS - Start receiveTask: docId = 578094_1514203614 {"cmd":{"c":"sfc","id":"578094_1514203614","userid":"onny","data":null,"title":"output.","outputformat":2055,"outputpath":"output.","status_info":-80,"savekey":"578094_1514203614_7480","useractionid":"onny","nobase64":true}}
Dec 27 23:07:21 http-new node[13466]: [2017-12-27 23:07:21.196] [DEBUG] nodeJS - Start commandSfcCallback: docId = 578094_1514203614
Dec 27 23:07:21 http-new node[13466]: [2017-12-27 23:07:21.198] [DEBUG] nodeJS - Callback commandSfcCallback: docId = 578094_1514203614 callback = https://nextcloud.***/index.php/apps/onlyoffice/track?doc=WFNlYkJicCtuMDRGcXBDeFJuSGhGcUlsZDVQRC9UUGNLZ25YWC9WY0M4ND0/eyJmaWxlSWQiOjU3ODA5NCwidXNlcklkIjoib25ueSIsImFjdGlvbiI6InRyYWNrIn0%3D
Dec 27 23:07:21 http-new node[13466]: [2017-12-27 23:07:21.198] [DEBUG] nodeJS - hasEditors commandSfcCallback: docId = 578094_1514203614 hasEditors = 0
Dec 27 23:07:21 http-new node[13466]: [2017-12-27 23:07:21.574] [DEBUG] nodeJS - postData request: docId = 578094_1514203614;url = https://nextcloud.***/index.php/apps/onlyoffice/track?doc=WFNlYkJicCtuMDRGcXBDeFJuSGhGcUlsZDVQRC9UUGNLZ25YWC9WY0M4ND0/eyJmaWxlSWQiOjU3ODA5NCwidXNlcklkIjoib25ueSIsImFjdGlvbiI6InRyYWNrIn0%3D;data = {"key":"578094_1514203614","status":3,"users":["onny"],"actions":[{"type":0,"userid":"onny"}],"lastsave":"2017-12-27T23:07:08.199Z","notmodified":false}
Dec 27 23:07:21 http-new node[13466]: [2017-12-27 23:07:21.654] [ERROR] nodeJS - sendServerRequest error: docId = 578094_1514203614;url = https://nextcloud***/index.php/apps/onlyoffice/track?doc=WFNlYkJicCtuMDRGcXBDeFJuSGhGcUlsZDVQRC9UUGNLZ25YWC9WY0M4ND0/eyJmaWxlSWQiOjU3ODA5NCwidXNlcklkIjoib25ueSIsImFjdGlvbiI6InRyYWNrIn0%3D;data = {"key":"578094_1514203614","status":3,"users":["onny"],"actions":[{"type":0,"userid":"onny"}],"lastsave":"2017-12-27T23:07:08.199Z","notmodified":false}
Dec 27 23:07:21 http-new node[13466]: Error: Error response: statusCode:400 ;body:
Dec 27 23:07:21 http-new node[13466]: {"message":"Url not found"}
Dec 27 23:07:21 http-new node[13466]:     at Request._callback (/usr/share/webapps/onlyoffice/documentserver/server/Common/sources/utils.js:269:18)
Dec 27 23:07:21 http-new node[13466]:     at Request.self.callback (/usr/share/webapps/onlyoffice/documentserver/server/Common/node_modules/request/request.js:186:22)
Dec 27 23:07:21 http-new node[13466]:     at Request.emit (events.js:159:13)
Dec 27 23:07:21 http-new node[13466]:     at Request.<anonymous> (/usr/share/webapps/onlyoffice/documentserver/server/Common/node_modules/request/request.js:1163:10)
Dec 27 23:07:21 http-new node[13466]:     at Request.emit (events.js:159:13)
Dec 27 23:07:21 http-new node[13466]:     at IncomingMessage.<anonymous> (/usr/share/webapps/onlyoffice/documentserver/server/Common/node_modules/request/request.js:1085:12)
Dec 27 23:07:21 http-new node[13466]:     at Object.onceWrapper (events.js:254:19)
Dec 27 23:07:21 http-new node[13466]:     at IncomingMessage.emit (events.js:164:20)
Dec 27 23:07:21 http-new node[13466]:     at endReadableNT (_stream_readable.js:1062:12)
Dec 27 23:07:21 http-new node[13466]:     at process._tickCallback (internal/process/next_tick.js:152:19)
Dec 27 23:07:24 http-new node[13466]: [2017-12-27 23:07:24.380] [DEBUG] nodeJS - End commandSfcCallback: docId = 578094_1514203614
Dec 27 23:07:24 http-new node[13466]: [2017-12-27 23:07:24.381] [DEBUG] nodeJS - End receiveTask: docId = 578094_1514203614
0reactions
onnycommented, Apr 4, 2018

Problem is fixed in the latest Onlyoffice release. Further I build v8 with clang now 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

Onlyoffice documents not saved in NextCloud
I recently install onlyoffice with onlyoffice and document server ... This app is basically broken and should not be used, it does not...
Read more >
Documents not being saved when editing. Nextcloud 18
It looks like that the edited file doesn't get replicated back to nextcloud. In my case I see the changes if I open...
Read more >
Onlyoffice do not write back to nextcloud
If you know the Documents which were not saved back to Nextcloud you can simply open the documents again and use “File” ->...
Read more >
SMB - Lots of missing files - ℹ️ Support - Nextcloud community
I have used SMB via External Storage for well over a year without issue. I recently did a lot of sorting and so...
Read more >
Restore with database dump but missing files - ℹ️ Support
You won't get any files back by restoring the database, because it only holds the meta data of the files. I'm sorry, but...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found