"Could not bind on port 80" on application start (amazon ec2)

1,162 views
Skip to first unread message

ArlaHaren

unread,
Feb 28, 2011, 12:15:59 PM2/28/11
to play-framework
Hello!

When I configure my play! application to listen on port 80 (in the
application.conf), I get the error message

16:51:46,227 ERROR ~ Could not bind on port 80

when starting it.

I am using a micro linux instance from Amazon EC2. I don't know if the
problem originates from Play or EC2, but I figured I'll ask in both
technologies' respective community forums.

I have made sure that port 80 is allowed incoming connections.
The application runs fine on (for instance) the default port 9000.
I have of course tried googling but I seem to be the only one that
have seen this error!?

Thanks for any help!

Guillaume Bort

unread,
Feb 28, 2011, 12:40:20 PM2/28/11
to play-fr...@googlegroups.com
Usually you need to be root to run a process that bind on port 80.

> --
> You received this message because you are subscribed to the Google Groups "play-framework" group.
> To post to this group, send email to play-fr...@googlegroups.com.
> To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/play-framework?hl=en.
>
>

--
Guillaume Bort, http://guillaume.bort.fr

For anything work-related, use g...@zenexity.fr; for everything else,
write guillau...@gmail.com

Arnaud Rolly

unread,
Mar 1, 2011, 2:33:20 AM3/1/11
to play-fr...@googlegroups.com, ArlaHaren
Under Linux, you need root privileges to bind to a port < 1024.

Run Play as root, or use a frontal proxy as Nginx normally already packaged for your Linux distribution.

2011/2/28 ArlaHaren <psyk...@gmail.com>

ArlaHaren

unread,
Mar 1, 2011, 3:07:09 AM3/1/11
to play-framework
You're the second one to recommend ngnix. I will most definately use
that.

On Mar 1, 8:33 am, Arnaud Rolly <traxt...@gmail.com> wrote:
> Under Linux, you need root privileges to bind to a port < 1024.
>
> Run Play as root, or use a frontal proxy as Nginx normally already packaged
> for your Linux distribution.
>
> 2011/2/28 ArlaHaren <psyko...@gmail.com>

ArlaHaren

unread,
Mar 1, 2011, 3:06:35 AM3/1/11
to play-framework
Thanks, my noobness as regards to *nix was to blame. Ran it as root
and no more problems.
> Guillaume Bort,http://guillaume.bort.fr
>
> For anything work-related, use g...@zenexity.fr; for everything else,
> write guillaume.b...@gmail.com
Reply all
Reply to author
Forward
0 new messages