Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 170 Vote(s) - 3.72 Average
  • 1
  • 2
  • 3
  • 4
  • 5
No such file or directory @ rb_sysopen - tmp/pids/puma.pid

#1
I'm trying to start puma, but at the last step it fails like this:

16:38:09 web.1 | /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/lib/puma/launcher.rb:130:in `initialize': No such file or directory @ rb_sysopen - tmp/pids/puma.pid (Errno::ENOENT)
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/lib/puma/launcher.rb:130:in `open'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/lib/puma/launcher.rb:130:in `write_pid'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/lib/puma/launcher.rb:103:in `write_state'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/lib/puma/single.rb:92:in `run'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/lib/puma/launcher.rb:174:in `run'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/lib/puma/cli.rb:77:in `run'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/gems/puma-3.9.1/bin/puma:10:in `<top (required)>'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/bin/puma:23:in `load'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/bin/puma:23:in `<main>'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/bin/ruby_executable_hooks:15:in `eval'
16:38:09 web.1 | from /home/ramonpm/.rvm/gems/ruby-2.2.7/bin/ruby_executable_hooks:15:in `<main>'
16:38:09 web.1 | exited with code 1
16:38:09 system | sending SIGTERM to all processes

Couldn't find a solution somewhere else, they are all related to different things.
Reply

#2
This error happened when I first added `puma.rb` file by `rails app:update` to rails 5.2 for a Heroku app.

```rb
# Specifies the `pidfile` that Puma will use.
pidfile ENV.fetch("PIDFILE") { "tmp/pids/server.pid" }
```

Resolved by adding `tmp/pids/.keep` file,
```sh
$ touch tmp/pids/.keep
```

And updating `.gitignore` file as follows.
```sh
# Ignore all logfiles and tempfiles.
/log/*
/tmp/*
!/log/.keep
!/tmp/.keep

# Ignore pidfiles, but keep the directory.
/tmp/pids/*
!/tmp/pids/
!/tmp/pids/.keep
```
Reply

#3
You can add that in your `config/puma.rb`:

```ruby
require "fileutils"
FileUtils.mkdir_p("tmp/pids")
```
Reply

#4
Could solve it manually creating the necessary folders, then the server process could create the pid file.

mkdir -p tmp/pids
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through