mastodon / mastodon

Your self-hosted, globally interconnected microblogging community
https://joinmastodon.org
GNU Affero General Public License v3.0
47.02k stars 6.96k forks source link

There was insufficient space remaining on the device. #25932

Closed dan1d closed 1 year ago

dan1d commented 1 year ago

Steps to reproduce the problem

  1. Generate a codespace as indicated on the readme file 2: see logs that it says that it failed to generate a worskpace.

Expected behaviour

Not error raised

Actual behaviour

There was an error while trying to write

Detailed description

2023-07-12 03:42:52.575Z: Fetching brpoplpush-redis_script 0.1.3
2023-07-12 03:42:52.603Z: 
Retrying download gem from https://rubygems.org/ due to error (2/4): Bundler::NoSpaceOnDeviceError There was an error while trying to write to `/workspaces/mastodon/vendor/bundle/ruby/3.2.0/cache/brpoplpush-redis_script-0.1.3.gem`. There was insufficient space remaining on the device.
2023-07-12 03:42:52.605Z: 
2023-07-12 03:42:52.607Z: Retrying download gem from https://rubygems.org/ due to error (2/4): Bundler::NoSpaceOnDeviceError There was an error while trying to write to `/workspaces/mastodon/vendor/bundle/ruby/3.2.0/cache/binding_of_caller-1.0.0.gem`. There was insufficient space remaining on the device.2023-07-12 03:42:52.608Z: 
2023-07-12 03:42:52.612Z: 
Retrying download gem from https://rubygems.org/ due to error (3/4): Bundler::NoSpaceOnDeviceError There was an error while trying to write to `/workspaces/mastodon/vendor/bundle/ruby/3.2.0/cache/brpoplpush-redis_script-0.1.3.gem`. There was insufficient space remaining on the device.

Retrying download gem from https://rubygems.org/ due to error (3/4): Bundler::NoSpaceOnDeviceError There was an error while trying to write to `/workspaces/mastodon/vendor/bundle/ruby/3.2.0/cache/binding_of_caller-1.0.0.gem`. There was insufficient space remaining on the device.
2023-07-12 03:42:52.619Z: 
Retrying download gem from https://rubygems.org/ due to error (4/4): Bundler::NoSpaceOnDeviceError There was an error while trying to write to `/workspaces/mastodon/vendor/bundle/ruby/3.2.0/cache/brpoplpush-redis_script-0.1.3.gem`. There was insufficient space remaining on the device.
2023-07-12 03:42:52.621Z: 
Retrying download gem from https://rubygems.org/ due to error (4/4): Bundler::NoSpaceOnDeviceError There was an error while trying to write to `/workspaces/mastodon/vendor/bundle/ruby/3.2.0/cache/binding_of_caller-1.0.0.gem`. There was insufficient space remaining on the device.
2023-07-12 03:42:52.628Z: 
2023-07-12 03:42:52.629Z: Fetching mario-redis-lock 1.2.12023-07-12 03:42:52.635Z: 
2023-07-12 03:42:52.642Z: 
2023-07-12 03:42:52.650Z: Fetching redis-namespace 1.11.0
2023-07-12 03:42:52.671Z: 
Retrying download gem from https://rubygems.org/ due to error (2/4): Bundler::NoSpaceOnDeviceError There was an error while trying to write to `/workspaces/mastodon/vendor/bundle/ruby/3.2.0/cache/mario-redis-lock-1.2.1.gem`. There was insufficient space remaining on the device.
2023-07-12 03:42:52.676Z: 

Is there anything missing that I need to do while creating the workspace on github? I have 32gb of storage.

Specifications

main branch

dj-sf commented 1 year ago

I am also having this issue. Getting quite frustrated because neither Vagrant nor Codespaces are working for me.

c960657 commented 1 year ago

It seems 32 GB is not enough. But AFAICT this is the maximum available under the free plan.

dj-sf commented 1 year ago

Does mastodon really take up 32gb? If so that seems like an issue in and of itself...

Gargron commented 1 year ago

No. The source code takes up about 50 MB at most, the full git history takes up 561 MB, and node_modules takes up 870 MB.

You're also installing Ruby, Postgres, Redis and possibly Elasticsearch but even all combined won't be anywhere near 32 GB.

c960657 commented 1 year ago

I'm not sure how it adds up to 32 GB, but on my local machine, the LibreTranslate volume alone uses 5 GB. AFAIK the language model is downloaded when the container first boots.

I have created PR #26382 for disabling the non-essentional services (Elasticsearch and LibreTranslate) on Codespaces.

dj-sf commented 1 year ago

Awesome. I approved the PR but it looks like you will need approval from someone with write access before it can be merged.

dj-sf commented 1 year ago

I know this was closed as completed but it is happening again as of a few days ago.

dj-sf commented 1 year ago

I know this was closed as completed but it is happening again as of a few days ago.

I figured out why this was happening. For some reason whenever I created a new codespace by clicking the + button in the codespaces dropdown, it was by default selecting the "mastodon on local machine" option under "Dev container configuration".

I didnt realize this until I tried creating one using the "New with options" dialog and saw the "Mastodon on local machine" selection was checked by default.

The solution for me was to go into the ["New with options" dialog] when creating a new Codespace, and then making sure to select the Mastodon on GitHub Codespaces configuration

Hope this helps someone!