Description
I would like to upgrade RocketChat from 4.8.1 to 5.x/stable
The first thing I tried is to upgrade it to 4.x/stable first, but it fails
[root@chat]# snap refresh rocketchat-server --channel=4.x/stable
error: snap "rocketchat-server" is not available on 4.x/stable but is available to install on the
following channels:
4.x/candidate snap refresh --channel=4.x/candidate rocketchat-server
4.x/beta snap refresh --channel=4.x/beta rocketchat-server
4.x/edge snap refresh --channel=4.x/edge rocketchat-server
Please be mindful pre-release channels may include features not completely tested or
implemented. Get more information with 'snap info rocketchat-server'.
Then I tried to upgrade to 5.x/stable, but it starts with this error
Jul 8 18:45:48 chat systemd[1]: Started Service for snap application rocketchat-server.rocketchat-server.
Jul 8 18:45:48 chat rocketchat-server.rocketchat-server[2969135]: node $SNAP/main.js
Jul 8 18:46:08 chat rocketchat-server.rocketchat-server[2969194]: strict mode: use allowUnionTypes to allow union type keyword at "#/properties/value" (strictTypes)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: LocalStore: store created at
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: LocalStore: store created at
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: Error creating index: livechat_priority -> { name: 1 } { unique: true } MongoServerError: Index with name: name_1 already exists with different options
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at MessageStream.messageHandler (/snap/rocketchat-server/1556/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/cmap/connection.js:462:30)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at MessageStream.emit (events.js:400:28)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at MessageStream.emit (domain.js:475:12)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at processIncomingData (/snap/rocketchat-server/1556/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/cmap/message_stream.js:108:16)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at MessageStream._write (/snap/rocketchat-server/1556/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/cmap/message_stream.js:28:9)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at writeOrBuffer (internal/streams/writable.js:358:12)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at MessageStream.Writable.write (internal/streams/writable.js:303:10)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at Socket.ondata (internal/streams/readable.js:731:22)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at Socket.emit (events.js:400:28)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at Socket.emit (domain.js:475:12)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at addChunk (internal/streams/readable.js:293:12)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at readableAddChunk (internal/streams/readable.js:267:9)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at Socket.Readable.push (internal/streams/readable.js:206:10)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at TCP.onStreamRead (internal/stream_base_commons.js:188:23)
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: at TCP.callbackTrampoline (internal/async_hooks.js:130:17) {
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: ok: 0,
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: code: 85,
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: codeName: 'IndexOptionsConflict'
Jul 8 18:46:11 chat rocketchat-server.rocketchat-server[2969194]: }
Jul 8 18:46:22 chat rocketchat-server.rocketchat-server[2969194]: MessageType.render is deprecated. Use MessageType.message instead. livechat_webrtc_video_call
Jul 8 18:46:24 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:46:24.340Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"VoIPService","msg":"Voip is not enabled. Cant start the service"}
Jul 8 18:46:35 chat rocketchat-server.rocketchat-server[2969194]: Browserslist: caniuse-lite is outdated. Please run:
Jul 8 18:46:35 chat rocketchat-server.rocketchat-server[2969194]: npx update-browserslist-db@latest
Jul 8 18:46:35 chat rocketchat-server.rocketchat-server[2969194]: Why you should do it regularly: https://github.com/browserslist/update-db#readme
Jul 8 18:46:36 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:46:36.701Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"VoIPService","msg":"VoIP service already stopped"}
Jul 8 18:46:38 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:46:38.240Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 0/30. Trying again in 10 seconds."}
Jul 8 18:46:48 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:46:48.255Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 1/30. Trying again in 10 seconds."}
Jul 8 18:46:58 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:46:58.273Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 2/30. Trying again in 10 seconds."}
Jul 8 18:47:08 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:47:08.286Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 3/30. Trying again in 10 seconds."}
Jul 8 18:47:18 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:47:18.300Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 4/30. Trying again in 10 seconds."}
Jul 8 18:47:28 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:47:28.313Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 5/30. Trying again in 10 seconds."}
Jul 8 18:47:38 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:47:38.326Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 6/30. Trying again in 10 seconds."}
Jul 8 18:47:48 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:47:48.342Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 7/30. Trying again in 10 seconds."}
Jul 8 18:47:58 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:47:58.388Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 8/30. Trying again in 10 seconds."}
Jul 8 18:48:08 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:48:08.402Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 9/30. Trying again in 10 seconds."}
Jul 8 18:48:18 chat rocketchat-server.rocketchat-server[2969194]: {"level":40,"time":"2023-07-08T10:48:18.422Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Not migrating, control is locked. Attempt 10/30. Trying again in 10 seconds."}
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: {"level":51,"time":"2023-07-08T10:48:28.438Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Migrating from version 272 -> 281"}
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: {"level":51,"time":"2023-07-08T10:48:28.439Z","pid":2969194,"hostname":"chat.skywidetech.local","name":"Migrations","msg":"Running up() on version 273"}
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: +----------------------------------------------------------------------+
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | ERROR! SERVER STOPPED |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: +----------------------------------------------------------------------+
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Your database migration failed: |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | index not found with name [userId_1] |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Please make sure you are running the latest version and try again. |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | If the problem persists, please contact support. |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | This Rocket.Chat version: 5.4.10 |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Database locked at version: 272 |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Database target version: 281 |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Commit: ba268c5004052a11040dbcd6e26834e7da317152 |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Date: Wed May 17 10:40:24 2023 -0300 |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Branch: HEAD |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | Tag: 5.4.10 |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: | |
Jul 8 18:48:28 chat rocketchat-server.rocketchat-server[2969194]: +----------------------------------------------------------------------+
Server Setup Information
- Version of Rocket.Chat Server:
- Operating System: centos8
- Deployment Method: snap
- Number of Running Instances: 1
- DB Replicaset Oplog:
- NodeJS Version: 14
- MongoDB Version: 4.4
- Proxy:
- Firewalls involved: