2
votes

Situation:

When attempting to start a brand new phoenix project on Ubuntu Server
with the command mix phoenix.server we see the following output:

==> mime
Compiling 1 file (.ex)
Killed

The server fails to start but gives us no indication of why... The commands that preceded this were:

Installation of Erlang/Elixir/Phoenix on Ubuntu Server

wget https://packages.erlang-solutions.com/erlang-solutions_1.0_all.deb
sudo dpkg -i erlang-solutions_1.0_all.deb
sudo apt-get update
sudo apt-get install build-essential erlang elixir erlang-base-hipe erlang-dev
mix local.hex
mix archive.install https://github.com/phoenixframework/archives/raw/master/phoenix_new.ez

Did I miss a step here? (was I supposed to install anything else?)

Phoenix Project Creation

mix phoenix.new --no-ecto --no-brunch phoenix_app
* creating phoenix_app/config/config.exs
* ...

Fetch and install dependencies? [Yn] Y
* running mix deps.get
* ...

cd phoenix_app
mix phoenix.server

Server Details

  • Phoenix v1.2.1
  • IEx (Elixir) 1.4.2
  • Mix 1.4.2
  • Erlang/OTP 19
  • OS: Ubuntu 16.04.2 LTS
  • Host: Digital Ocean

Just trying to figure out if this is an environment setup issue or if I have done something wrong. Hoping someone else has come across this Killed thing before and can help! Unable to find it in the Phoenix docs ...

iRealise this is a "noob" question, the context is I'm trying to do a deployment from scratch using Distillery following these instructions, but can't get past the basics so wondering if this killed issue is a thing...?

1
Can you try increasing the RAM temporarily and then compiling? Definitely looks like an OOM issue like my answer above. - Dogbert
thanks @Dogbert what would we do without you?! :-) - nelsonic
@Dogbert was 100% correct (as usual) on a 512Mb VM only 12MB was free (thanks Docker for hogging resources it wasn't using!) shut down docker temporarily to do the compilation step and re-started. all worked thanks! - nelsonic

1 Answers

0
votes

There is nothing noob question here. Just in case someone read this page and want to know how to properly setup phoenix framework development, here are the installation guide:

Installation in Ubuntu 20.04 + Phoenix 1.5.1:

https://www.yodiw.com/install-elixir-phoenix-framework-in-ubuntu-20-04-focal-fossa/

Installation in Windows 10 + Phoenix 1.5.1:

https://www.yodiw.com/phoenix-elixir-installation-in-windows-10/