Error after cleaning tmp folder

AI-generated summary

A user, bekircem, encountered an error after cleaning the tmp folder while setting up a Discourse development environment on macOS. The error occurred when running bundle exec rails server, and zogstrip suggested checking if PostgreSQL was running. bekircem confirmed it worked before the cleanup. zogstrip suspected the user might have deleted the wrong folder (e.g., /tmp/ instead of tmp/). bekircem clarified they deleted hidden files in the tmp folder, possibly causing the issue. After restarting PostgreSQL, the problem persisted, but bekircem resolved it by removing the postmaster.pid file, which likely fixed a stale process issue.

Hi,

I installed Discourse development environment with official guide on my MacOS. I changed plugin file and it warned me for “remove the TMP folder”. I cleaned tmp folder in Discourse and after that when i use that command Discourse doesn’t work: bundle exec rails server

Any idea?

This error means rails can’t talk to your postgresql server. Is your postgresql server running?

How i can check it? It worked before removing the tmp folder.

Depends on how you installed it.

I’m guessing you removed /tmp/ instead of tmp/? That’s kinda baaad…

I installed with that guide:

I cleaned up files and folders in TMP folder. So i cleaned tmp/? :slight_smile: But my operating system shows hidden files and folders. I must have deleted the hidden files and folders. Is it problem?

Here’s how to stop/start services with Homebrew

Do i start postgresql?

I restarted postgresql, but it still did not work.

This works for me.

rm /usr/local/var/postgres/postmaster.pid