Rocket.chat: Error when Downloading or Exporting My Data

Created on 11 Jun 2018  Â·  18Comments  Â·  Source: RocketChat/Rocket.Chat

Description:

We are unable to Download or Export My Data.

Steps to reproduce:

  1. Log in to RocketChat
  2. Click on My Account
  3. Scroll to the bottom of the page
  4. Click either DOWNLOAD MY DATA or EXPORT MY DATA

Expected behavior:

Clicking on either button, I expect an email with instructions how to access a file containing my chat history.

Actual behavior:

An email is never received with instructions how to access my chat history.

Server Setup Information:

  • Version of Rocket.Chat Server: 0.65.1 DB Migration 121
  • Operating System: Ubuntu 16.04.4
  • Deployment Method: Snap
  • Number of Running Instances: 1
  • DB Replicaset Oplog:
  • NodeJS Version: 8.11.2
  • MongoDB Version:

Additional context

Relevant logs:

There are no errors generated in the browser.

Server log:
I20180611-08:39:00.876(-4) SyncedCron âž” info Starting "Generate download files for user data".
I20180611-08:39:00.903(-4) Exception in callback of async function: Error: ENOENT: no such file or directory, open '/tmp/rocket_chat_export_compressed/MfANF2qwBemicsdJB.zip'
I20180611-08:39:00.912(-4) SyncedCron âž” info Not running "Generate download files for user data" again.
I20180611-08:39:00.948(-4) SyncedCron âž” info Not running "Generate download files for user data" again.
I20180611-08:39:00.951(-4) SyncedCron âž” info Finished "Generate download files for user data".


Most helpful comment

Doesn't work even in latest version.

All 18 comments

Hi @etyack,

this should be fixed with PR #10837 (Release 0.65.0). Are you sure you're on the latest version?

Cheers

Yes, I double checked since I found the issue you referenced before I submitted this issue.

According to the snap output:
erickt@wiki:~ sudo snap list
Name Version Rev Tracking Developer Notes
core 16-2.32.8 4650 stable canonical core
rocketchat-server 0.65.1 1273 stable rocketchat -

And admin Info output.
screen shot 2018-06-11 at 10 28 34 am

Thanks for the quick reply @etyack :)

@Hudell You may want to have a look?

We are unable to Download or Export My Data, too. But in our logs, are no error messages.

Here are the only lines:

I20180613-08:27:05.962(0) Meteor âž” method requestDataDownload -> userId: dc45SQus6oW8Ajutc , arguments:  { '0': { fullExport: true } } 
[ ... ]
I20180613-08:30:00.500(0) SyncedCron âž” info Starting "Generate download files for user data". 
I20180613-08:30:00.505(0) SyncedCron âž” info Not running "Generate download files for user data" again. 
I20180613-08:30:01.023(0) SyncedCron âž” info Finished "Generate download files for user data". 

bildschirmfoto 2018-06-13 um 10 46 33

@phillipplum Can you check your "User Data Download" admin settings? Based on your log, it seems like there's no Processing Frequency configured.

@Hudell Here are our settings. We don't change something.

image

I'll look into it.

@Hudell: I also experience this issue. It seems identical to the others here:

  • Email is never received with instructions how to access the chat history
  • No error message presented to the user
  • No error message in logs

Setup:

  • Server version: 0.65.1 deployed with Snap, on Ubuntu Ubuntu 16.04 (newest available for snap)
  • Default User Data Download settings (enabled, frequency=15m, message limit=100)
  • Email verified working. Logging suggests Rocket.Chat server never attempts to send the email.

Please let us know if you need any debugging assistance.

Unfortunately, it still does not work after the update to 0.66.0.

Update:
Now _(3-4 hours later)_ I get a e-mail with an download link.
The link looks like this: https://chat.domain/ufs/FileSystem:UserDataFiles/Yu7JK49278JiX8duy/2018-06-28-firstname%2520lastname.zip

But it is a 0kb zip-file and after extracting it I get a file with the same name and at the end .cpgz.

Doesn't work even in latest version.

I think this still doesnt work...

Same here with latest docker develop image.

Guys, can you please test this with version 2.0.0 ?

Getting this with 2.1.0-develop, commit 72aaeb3201 which is after the commit that addressed the download.

TypeError: Cannot read property 'username' of undefined
    at generateUserAvatarFile (app/user-data-download/server/cronProcessDownloads.js:477:62)
    at Promise.asyncApply (app/user-data-download/server/cronProcessDownloads.js:503:4)
    at /app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40

Getting this with 2.1.0-develop, commit 72aaeb3 which is after the commit that addressed the download.

TypeError: Cannot read property 'username' of undefined
    at generateUserAvatarFile (app/user-data-download/server/cronProcessDownloads.js:477:62)
    at Promise.asyncApply (app/user-data-download/server/cronProcessDownloads.js:503:4)
    at /app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40

Same here on 2.1.0 (not develop)

Getting the same with docker image: rocketchat/rocket.chat:2.1.1:

 TypeError: Cannot read property 'username' of undefined
Oct 24 17:28:00 chat rocketchat_app2_1[2683]:     at generateUserAvatarFile (app/user-data-download/server/cronProcessDownloads.js:477:62)
Oct 24 17:28:00 chat rocketchat_app2_1[2683]:     at Promise.asyncApply (app/user-data-download/server/cronProcessDownloads.js:503:4)
Oct 24 17:28:00 chat rocketchat_app2_1[2683]:     at /app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40

We are testing the function "Download my Data". Yesterday it works and I get a E-Mail to download the data. After that and today I would to export the data again, because there are many new conversations, that would I save.
Then I click on "Download My Data" I get the message: "Your data file was already generated. Click here to download it."
Then I click on the link I get the data from yesterday again but no new data. How can I get new data?

Version of RocketChat: 3.4.0

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pnewell picture pnewell  Â·  243Comments

oliver-bowman picture oliver-bowman  Â·  55Comments

engelgabriel picture engelgabriel  Â·  91Comments

RiusmaX picture RiusmaX  Â·  81Comments

bazarnew picture bazarnew  Â·  87Comments