https://www.activepieces.com logo
Hello, I'm self-hosting and encountering
# 🐶|general
e
Hello, I'm self-hosting and encountering errors related to failed pieces installations, with the logs mentioning the cache folder and then failed installation and roll back. I've searched for solutions and found someone else with similar issues, but I didn't see any resolution. My installation is fresh, set up through Docker Compose using Container Manager on my Synology. I followed the standard Docker Compose instructions from the website, but the build failed, prompting me to create the cache folder, which I did, and then it built successfully. I can't proceed further because, without the pieces loading there isn't much else to try. However, I can access my instance, create a user account, and log in, create new flows (but not add pieces successfully), edit admin settings, etc. Any help would be appreciated. UI Provided Error Error An internal error occurred while fetching data, please contact support Logs {"level":50,"time":1764776373645,"pid":10,"hostname":"65527c854218","error":{},"msg":"[PackageManager#install] Failed to install dependencies"} {"level":20,"time":1764776373551,"pid":10,"hostname":"65527c854218","path":"/usr/src/app/cache/v7/common","args":["--ignore-scripts","--linker isolated"],"filters":["--filter ./pieces/@activepieces/piece-opnform-0.0.1"],"msg":"[PackageManager#install]"} {"level":30,"time":1764776373454,"pid":10,"hostname":"65527c854218","rootWorkspace":"/usr/src/app/cache/v7/common","pieces":["@activepieces/piece-opnform-0.0.1"],"msg":"[registryPieceManager] acquired lock and starting to install pieces"} {"level":50,"time":1764776373451,"pid":10,"hostname":"65527c854218","rootWorkspace":"/usr/src/app/cache/v7/common","pieces":["@activepieces/piece-opnform-0.0.1"],"error":{},"msg":"[registryPieceManager] Piece installation failed, rolling back"} {"level":50,"time":1764776373451,"pid":10,"hostname":"65527c854218","error":{},"msg":"[PackageManager#install] Failed to install dependencies"}
m
Hi @Erfin What is the OS do you use?
e
I'm running this on a Synology. :-)
I am unsure of what they are unising as the undelying OS.
m
Are you able to ssh into the container?
Are you able to run
bun -v
inside?
e
I will try that when I get home. :-)
Okay after some testing and a little bit of ChatGPT it appears I have an x86 Linux environment. It had me install a bun version for that. However even after installing and restarting all containers I have this same issue. {"level":50,"time":1764821739693,"pid":10,"hostname":"65527c854218","rootWorkspace":"/usr/src/app/cache/v7/common","pieces":["@activepieces/piece-opnform-0.0.1"],"error":{},"msg":"[registryPieceManager]
m
Does running bun. -v inside the container works or return illegal operation?
e
It returned an illegal operation
m
@chaker5341 sounds like same issue
can you check the os?
@Erfin
e
Sure thing let me try
It just says command not found.
m
Give a moment
Give me a moment*
e
Sure thing. :-) I'm wondering if Synology's OS isn't compatible.
m
cat /etc/os-release
What this output?
e
ssh@Office:~$ cat /etc/os-release cat: /etc/os-release: No such file or directory
m
Okay bare with me
We will try to reinstall bun
e
Sure thing, I'm not in a hurry and appreciate your help. :-)
m
Let's uninstall bun
Copy code
rm -rf ~/.bun
Let's verify that it's uninstalled
Copy code
bun -v
e
do you want me to run this from my host os or from the container?
m
Then let's use their installation script again, my assumption is either OS is not supported for bun or it downloaded the wrong variation.
Copy code
curl -fsSL https://bun.sh/install | bash
from https://bun.sh/
the container
e
Sure thing, let me do that I will let you know the result.
Okay, installed. I assume you want me to restart the containers?
m
now can you run
bun -v
Do not restart yet 😄
Does it work?
e
# bun -v 1.3.3
m
That's quite interesting!
e
lol what should it be saying?
m
So somehow if we install the bun during run time and instead of building time
it works xD
Let's try to install one of the piece, if it works
we will publish a fix
e
sure thing let me try and see what happens.
m
Give me a moment!
Or yo ucan try from inside activepieces
that would work
Can you try to run this inside the container anywhere
Copy code
bun install @activepieces/piece-webhook
e
sure thing, it's trying now and says # bun install @activepieces/piece-webhook bun add v1.3.3 (274e01c7) installed @activepieces/piece-webhook@0.1.25 13 packages installed [2.47s]
m
Awesome and does it work from inside activepieces?
If you try to run a flow
e
so when I try to add a piece through the UI it will just sort of spin when I give it data and I see this in the logs. {"level":20,"time":1765057978297,"pid":11,"hostname":"65527c854218","path":"/usr/src/app/cache/v7/common","args":["--ignore-scripts","--linker isolated"],"filters":["--filter ./pieces/@activepieces/piece-opnform-0.0.1"],"msg":"[PackageManager#install]"} {"level":50,"time":1765057978321,"pid":11,"hostname":"65527c854218","error":{},"msg":"[PackageManager#install] Failed to install dependencies"} {"level":50,"time":1765057978321,"pid":11,"hostname":"65527c854218","rootWorkspace":"/usr/src/app/cache/v7/common","pieces":["@activepieces/piece-opnform-0.0.1"],"error":{},"msg":"[registryPieceManager] Piece installation failed, rolling back"}
m
Give me a moment
e
Sure thing
m
Can you run that
Copy code
bun install --ignore-scripts --linker isolated --filter ./pieces/@activepieces/piece-opnform-0.0.1
anywhere in the container
Whaat does it return?
e
# bun install --ignore-scripts --linker isolated --filter ./pieces/@activepieces/piece-opnform-0.0.1 bun install v1.3.3 (274e01c7) Checked 1 install across 49 packages (no changes) [88.00ms]
e
lol
m
Give me 5 minutes, I am bringing someone from the team
e
If you would like for me to send you my compose file, I can, if I can figure out how to DM on here. :-)
Sounds good to me
m
Will you be there in 15 minutes? we are building new docker image
e
I sure will. I will set a timer and owrk on someting else. :-)
m
Thanks will ping you once we are done 😄
e
👍
c
@Erfin can you run this command inside this folder cache/v7/common
e
# cache/v7/common sh: 5: cache/v7/common: Permission denied
c
in the container . try
cd /usr/src/app/cache/v7/common
and then the command above
e
# cd /usr/src/app/cache/v7/common # bun install --ignore-scripts --linker isolated --filter ./pieces/@activepieces/piece-opnform-0.0.1 error: An unknown error occurred (Unexpected)
c
Can you delete that folder and test flows on the ui
run ‘rm -rf /usr/src/app/cache’
e
Interesting: # run 'rm -rf /usr/src/app/cache' sh: 11: run: not found I ran that within the container should i be running this elsewhere?
c
No do not include run
rm -rf /usr/src/app/cache
e
I'm sorry, that was a rookie mistake lol.
rm -rf /usr/src/app/cache rm: cannot remove '/usr/src/app/cache': Device or resource busy
c
Happens hh
m
@Erfin I am almost done as well, building the new image
e
Excellent, just let me know what you all want done and I can test it
m
I might need sometime, not sure how long i need facing issues
will ping you once i am done
e
that's not a problem at all
:-)
m
@Erfin Do you know how to edit the docker image version?
(Sorry for the question, but i am not sure how it works in synology tbh)
e
I don't think i do, but if I am using Container Manager (A Version of Docker Composer) for Synology I might be able to get it it pull a released version. But I'm not scared to try whatever you say. :-)
m
Awesome can you edit the docker compose image
to that
image: ghcr.io/activepieces/activepieces:0.72.4-bun.1
e
So I think I woudl edit this line i the compose file? activepieces: image: ghcr.io/activepieces/activepieces:0.72.4
m
yeah please edit the image to ghcr.io/activepieces/activepieces:0.72.4-bun.1 instead of ghcr.io/activepieces/activepieces:0.72.4
and try again 😄
e
sure thing the containers are shutting down and then I will replace that line
okay it's pulling now :-)
m
Fingers crossed!
e
so it failed to build but I'm trying again and am going to see if I can grab a log
Okay that built now it's starting up.
shrugs
So I'm thnking it might be crashing.
m
What error are you running into?
e
The Web UI isn't loading adn I noticed it was only up for a few seconds, checked the logs and found this, and then noticed Container Manager said it was restarting. ssh@OfficeNAS:/volume1/Docker/activepieces$ docker logs 65527c854218_activepieces -f Installing Bun...100.0% bun was installed successfully to ~/.bun/bin/bun AP_APP_TITLE: Activepieces AP_FAVICON_URL: https://cdn.activepieces.com/brand/favicon.ico
Starting backend server with Node.js (WORKER mode or default) Migration "UnifyCommunityWithEnterprise1764567780604" failed, error: column "tasks" of relation "flow_run" does not exist {"level":50,"time":1765061836979,"pid":28,"hostname":"e36d7b1bd9d3","err":{"type":"QueryFailedError","message":"column \"tasks\" of relation \"flow_run\" does not exist","stack":"QueryFailedError: column \"tasks\" of relation \"flow_run\" does not exist\n at PostgresQueryRunner.query (/usr/src/app/dist/packages/server/api/node_modules/typeorm/driver/src/driver/postgres/PostgresQueryRunner.ts:325:19)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async UnifyCommunityWithEnterprise1764567780604.up (/usr/src/app/packages/server/api/src/app/database/migration/postgres/1764567780604-UnifyCommunityWithEnterprise.ts:285:9)\n at async MigrationExecutor.executePendingMigrations (/usr/src/app/dist/packages/server/api/node_modules/typeorm/migration/src/migration/MigrationExecutor.ts:336:17)\n at async DataSource.runMigrations (/usr/src/app/dist/packages/server/api/node_modules/typeorm/data-source/src/data-source/DataSource.ts:404:13)\n at async DataSource.initialize (/usr/src/app/dist/packages/server/api/node_modules/typeorm/data-source/src/data-source/DataSource.ts:273:17)\n at async initializeDatabase (/usr/src/app/packages/server/api/src/app/database/index.ts:5:5)\n at async Redlock.using (/usr/src/app/dist/packages/server/api/node_modules/redlock/src/index.ts:742:14)\n at async main (/usr/src/app/packages/server/api/src/main.ts:61:9)","query":"\n ALTER TABLE \"flow_run\" DROP COLUMN \"tasks\"\n ","driverError":{"type":"DatabaseError","message":"column \"tasks\" of relation \"flow_run\" does not exist","stack":"error: column \"tasks\" of relation \"flow_run\" does not exist\n at /usr/src/app/dist/packages/server/api/node_modules/pg/lib/client.js:
526:17\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async PostgresQueryRunner.query (/usr/src/app/dist/packages/server/api/node_modules/typeorm/driver/src/driver/postgres/PostgresQueryRunner.ts:254:25)\n at async UnifyCommunityWithEnterprise1764567780604.up (/usr/src/app/packages/server/api/src/app/database/migration/postgres/1764567780604-UnifyCommunityWithEnterprise.ts:285:9)\n at async MigrationExecutor.executePendingMigrations (/usr/src/app/dist/packages/server/api/node_modules/typeorm/migration/src/migration/MigrationExecutor.ts:336:17)\n at async DataSource.runMigrations (/usr/src/app/dist/packages/server/api/node_modules/typeorm/data-source/src/data-source/DataSource.ts:404:13)\n at async DataSource.initialize (/usr/src/app/dist/packages/server/api/node_modules/typeorm/data-source/src/data-source/DataSource.ts:273:17)\n at async initializeDatabase (/usr/src/app/packages/server/api/src/app/database/index.ts:5:5)\n at async Redlock.using (/usr/src/app/dist/packages/server/api/node_modules/redlock/src/index.ts:742:14)\n at async main (/usr/src/app/packages/server/api/src/main.ts:61:9)","length":117,"name":"error","severity":"ERROR","code":"42703","file":"tablecmds.c","line":"8271","routine":"ATExecDropColumn"},"length":117,"severity":"ERROR","code":"42703","file":"tablecmds.c","line":"8271","routine":"ATExecDropColumn"},"msg":"[Main#main]"}
Sorry I don't know waht is useful versus what isn't for this.
m
that seems different
Is it possible for you to clear database volume
e
if you tell me how to I would be more than happy to do so
actually I think I can use Container Manager as it has a Clean feature.
m
Can you try that?
e
Sure can :-)
Okay I'm letting it build again, we will see if that did it.
still crashing. How would you like to me to clear the database volume so I can ensure it was completed corerctly.
e
hummmm I don't use portainer. But let me see if I can find a way to nuke the database.
m
what do you see 😄
e
Just the container manager. However I believe I can use docker volume rm activepieces_postgress_data to remove it
m
that would work!
e
do you want me to clear activepieces_redis_data as well?
m
even better
e
done and done. Now rebuild?
m
Yes!
e
Okay trying again. ssh@OfficeNAS:/volume1/Docker/activepieces$ docker logs 89641830cee2 -f Installing Bun... ######################################################################## 100.0% bun was installed successfully to ~/.bun/bin/bun Run 'bun --help' to get started AP_APP_TITLE: Activepieces AP_FAVICON_URL: https://cdn.activepieces.com/brand/favicon.ico Starting backend server with Node.js (WORKER mode or default)
m
Awesome now let's test on the ui 😮
e
still loading lol
I will try again in a few second
I'm assuming this could take a minute to load everything? It gets a loading circle for a moment and then it goes away.
So I don't see any crashes. But the UI isn't loading. {"level":30,"time":1765063364856,"pid":27,"hostname":"89641830cee2","msg":"UnifyCommunityWithEnterprise1764567780604 up"} {"level":30,"time":1765063367051,"pid":27,"hostname":"89641830cee2","name":"rolesSeed","msg":"Seeding roles"} {"level":30,"time":1765063368316,"pid":27,"hostname":"89641830cee2","name":"seedDevData","msg":"skip: not in development environment"} {"level":30,"time":1765063368938,"pid":27,"hostname":"89641830cee2","name":"SystemJob#upsertJob","jobName":"file-cleanup-trigger","msg":"Upserting job"} {"level":30,"time":1765063368940,"pid":27,"hostname":"89641830cee2","name":"SystemJob#upsertJob","jobName":"file-cleanup-trigger","msg":"Adding job to queue"} {"level":30,"time":1765063369372,"pid":27,"hostname":"89641830cee2","msg":"Starting piece synchronization"}
Maybe a little more patience on my side?
hummm I do'nt seem to be loading. Here is the latest log. {"level":30,"time":1765063800087,"pid":27,"hostname":"89641830cee2","counts":0,"types":["FLOW_RUN_LOG","FLOW_STEP_FILE","TRIGGER_EVENT_FILE","TRIGGER_PAYLOAD"],"msg":"[FileService#deleteStaleBulk] iteration completed"} {"level":30,"time":1765063800087,"pid":27,"hostname":"89641830cee2","totalAffected":0,"types":["FLOW_RUN_LOG","FLOW_STEP_FILE","TRIGGER_EVENT_FILE","TRIGGER_PAYLOAD"],"msg":"[FileService#deleteStaleBulk] completed"}
It loaded! Let me create my account and I will let you know if it loads pieces!
m
😮 let's see
that took while!
e
Yeah, it’s running on a Synology from like 2018 or something, maybe 2016. It has 16 GB of RAM, but let's be honest, she's not a new machine.
m
It seems powerful machine
Let me know if AP works now 😄
e
bummer it still didn't work. However, I don't see the same fallback message which used to be in the other logs before. Do you have an integration you want me to try aside from my Opnform in case it's the casue of the error.
m
webhook trigger with code piece
e
Actually {"level":50,"time":1765064705471,"pid":27,"hostname":"89641830cee2","rootWorkspace":"/usr/src/app/cache/v7/common","pieces":["@activepieces/piece-opnform-0.0.1"],"error":{},"msg":"[registryPieceManager] Piece installation failed, rolling back"}
Okay, let me try that
No dice. {"level":30,"time":1765064822728,"pid":27,"hostname":"89641830cee2","rootWorkspace":"/usr/src/app/cache/v7/common","piecesToInstall":["@activepieces/piece-webhook-0.1.25"],"msg":"[registryPieceManager] Installing pieces in workspace"} {"level":30,"time":1765064822728,"pid":27,"hostname":"89641830cee2","rootWorkspace":"/usr/src/app/cache/v7/common","pieces":["@activepieces/piece-webhook-0.1.25"],"msg":"[registryPieceManager] acquired lock and starting to install pieces"} {"level":20,"time":1765064822826,"pid":27,"hostname":"89641830cee2","path":"/usr/src/app/cache/v7/common","args":["--ignore-scripts","--linker isolated"],"filters":["--filter ./pieces/@activepieces/piece-webhook-0.1.25"],"msg":"[PackageManager#install]"} {"level":50,"time":1765064822857,"pid":27,"hostname":"89641830cee2","error":{},"msg":"[PackageManager#install] Failed to install dependencies"} {"level":50,"time":1765064822857,"pid":27,"hostname":"89641830cee2","rootWorkspace":"/usr/src/app/cache/v7/common","pieces":["@activepieces/piece-webhook-0.1.25"],"error":{},"msg":"[registryPieceManager] Piece installation failed, rolling back"} {"level":30,"time":1765064823616,"pid":27,"hostname":"89641830cee2","reqId":"req_wuchQYxwrCjikCrkk9EEG","flowId":"7QyJu5XEhhdQOY9IEfvla","projectId":"6Ja9ihaRPurvAfwjetql8","simulate":true,"msg":"[triggerSourceService#disable] Disabling trigger source"}
I'm pretty sure this wouldn't have to do with any reverse proxies or anything correct?
m
Correct, it's something with bun
One second one final thing
e
Okay :-) just wanted to make sure I didn't do anything.
m
not sure for now tbh 😅
e
that's not a problem at all.
I will do my best to check in on here over the next few days :-)
Thank you for all of your help today, though!
m
Thank you for debuggimg with us 😄
e
Anytime lol have a great day!
m
If you can run this again that would be awesome
Copy code
cd /usr/src/app/cache/v7/common 
bun install --ignore-scripts --linker isolated --filter ./pieces/@activepieces/piece-opnform-0.0.1 --verbose
e
Hello! I'm sorry it's been a minute. I ran the commands and recived the error # cd /usr/src/app/cache/v7/common bun install --ignore-scripts --linker isolated --filter ./pieces/@activepieces/piece-opnform-0.0.1 --verbose# error: An unknown error occurred (Unexpected) # cd /usr/src/app/cache/v7/common # bun install --ignore-scripts --linker isolated --filter ./pieces/@activepieces/piece-opnform-0.0.1 --verbose error: An unknown error occurred (Unexpected)
m
Thisis now fixed