[web2py] Re: web2py on Mac OS Mavericks, trying to use port 80

2014-03-14 Thread Annet
Hi Manuel,

The issue is not limited to Mac OS Mavericks, I ran into the same issue on
Mac OS Lion Server and Mountain Lion Server. For that reason I leave
Web2py's Server Port setting to the default 8000 instead of setting it to 
80.

Kind regards,

Annet

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: web2py on Mac OS Mavericks, trying to use port 80

2014-03-14 Thread LightDot
Hello Manuel, welcome to the list.

The issue you're seeing is not a bug, it's a feature of the OS or, rather, 
of it's security settings. The same behavior can be observed on Linux, 
FreeBSD, Solaris, ... any UN*X OS basically: non root users can't bind to 
ports below 1024.

This limit can be changed (per user or per process), but I don't recommend 
this unless you understand all implications of doing so. There are other 
ways around this, such as starting the process as root and then dropping 
privileges, using a proxy that has such functionality, using iptables to 
redirect ports, etc.

Regards

On Friday, March 14, 2014 7:34:58 AM UTC+1, audi...@gmail.com wrote:
>
> Hello,
> Thanks to the team for the great tool !
> I have minor issues on Mac OS Mavericks, just wanted to check before 
> creating an issue on google code.
>
> System
> Mac OS 10.9.2
> $ which python
> /usr/bin/python
> $ python --version
> Python 2.7.5
>
> Steps
> download web2py_src.zip
> unzip the archive into $basedir
> from an Mac administrator account, launch Terminal
> $ cd $basedir
> $ python web2py.py
> ...
> Version 2.9.4-stable+timestamp.2014.03.05.04.44.09
> ...
> The web2py graphical interface launches
> Leave "server ip" on "local"
> Set "Server Port" to "80"
> Enter a password in "Choose password" field
> Click on "start server"
>
> Expected result
> web2py framework, start listening on port 80
>
> Actual result
> The terminal output :
> ERROR:Rocket.Errors.Port80:Socket 127.0.0.1:80 in use by other process 
> and it won't share.
> WARNING:Rocket.Errors.Port80:Listener started when not ready.
>
> What have I tried
> Check active ports with Apple's network utility (port scan) : no active 
> port between 10 and 100
>
> Use 
> $ sudo python web2py.py
> instead of 
> $ python web2py.py
> Then you can actually launch web2py on port 80
> Terminal output :
> ...
> please visit:
> http://127.0.0.1/
> starting browser...
>
> It seems this is related to Mac OS policy to keep use of some ports for 
> it's own usage.
> My question is wether this is a bug or an enhancement request to have an 
> error message in the graphical web2py launch app to inform user ?
> (When using the Mac OS package instead of the source version, you don't 
> have any feedback on this issue, the server is just not starting).
>
> As this is my first post on this list, let me know if I made any mistake.
> thanks,
> Manuel
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: web2py on Mac OS Mavericks, trying to use port 80

2014-03-14 Thread Dave S
 
On Friday, March 14, 2014 9:51:55 AM UTC-7, LightDot wrote:
>
> Hello Manuel, welcome to the list.
>
> The issue you're seeing is not a bug, it's a feature of the OS or, rather, 
> of it's security settings. The same behavior can be observed on Linux, 
> FreeBSD, Solaris, ... any UN*X OS basically: non root users can't bind to 
> ports below 1024.
>
> This limit can be changed (per user or per process), but I don't recommend 
> this unless you understand all implications of doing so. There are other 
> ways around this, such as starting the process as root and then dropping 
> privileges, using a proxy that has such functionality, using iptables to 
> redirect ports, etc.
>
> Regards
>


Part of the  OP's question is, "Should Web2Py give a diagnostic message 
when the listening port is unavailable?"

Manuel has seen error messages from Rocket -- but only when using the 
command line to start web2py?  Does the graphical launcher hide these?

/dps


> On Friday, March 14, 2014 7:34:58 AM UTC+1, audi...@gmail.com wrote:
>>
>> Hello,
>> Thanks to the team for the great tool !
>> I have minor issues on Mac OS Mavericks, just wanted to check before 
>> creating an issue on google code.
>>
>> System
>> Mac OS 10.9.2
>> $ which python
>> /usr/bin/python
>> $ python --version
>> Python 2.7.5
>>
>> Steps
>> download web2py_src.zip
>> unzip the archive into $basedir
>> from an Mac administrator account, launch Terminal
>> $ cd $basedir
>> $ python web2py.py
>> ...
>> Version 2.9.4-stable+timestamp.2014.03.05.04.44.09
>> ...
>> The web2py graphical interface launches
>> Leave "server ip" on "local"
>> Set "Server Port" to "80"
>> Enter a password in "Choose password" field
>> Click on "start server"
>>
>> Expected result
>> web2py framework, start listening on port 80
>>
>> Actual result
>> The terminal output :
>> ERROR:Rocket.Errors.Port80:Socket 127.0.0.1:80 in use by other process 
>> and it won't share.
>> WARNING:Rocket.Errors.Port80:Listener started when not ready.
>>
>> What have I tried
>> Check active ports with Apple's network utility (port scan) : no active 
>> port between 10 and 100
>>
>> Use 
>> $ sudo python web2py.py
>> instead of 
>> $ python web2py.py
>> Then you can actually launch web2py on port 80
>> Terminal output :
>> ...
>> please visit:
>> http://127.0.0.1/
>> starting browser...
>>
>> It seems this is related to Mac OS policy to keep use of some ports for 
>> it's own usage.
>> My question is wether this is a bug or an enhancement request to have an 
>> error message in the graphical web2py launch app to inform user ?
>> (When using the Mac OS package instead of the source version, you don't 
>> have any feedback on this issue, the server is just not starting).
>>
>> As this is my first post on this list, let me know if I made any mistake.
>> thanks,
>> Manuel
>>
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: web2py on Mac OS Mavericks, trying to use port 80

2014-03-15 Thread audionuma

Hello,

Le vendredi 14 mars 2014 20:33:26 UTC+1, Dave S a écrit :
>
>  
> On Friday, March 14, 2014 9:51:55 AM UTC-7, LightDot wrote:
>>
>> Hello Manuel, welcome to the list.
>>
>> The issue you're seeing is not a bug, it's a feature of the OS or, 
>> rather, of it's security settings. The same behavior can be observed on 
>> Linux, FreeBSD, Solaris, ... any UN*X OS basically: non root users can't 
>> bind to ports below 1024.
>>
>> This limit can be changed (per user or per process), but I don't 
>> recommend this unless you understand all implications of doing so. There 
>> are other ways around this, such as starting the process as root and then 
>> dropping privileges, using a proxy that has such functionality, using 
>> iptables to redirect ports, etc.
>>
>> Regards
>>
>
>
> Part of the  OP's question is, "Should Web2Py give a diagnostic message 
> when the listening port is unavailable?"
>
> Manuel has seen error messages from Rocket -- but only when using the 
> command line to start web2py?  Does the graphical launcher hide these?
>
> /dps
>
Thanks all for your feedback. 
I asked this because I think many first time users will use the packaged 
version (which is a great option for beginners).
This is what I did and I'm not sure these users will then think to try the 
source code version to see if there's more feedback (which has been my 
path).
One might object that maybe first time users will not try to change the 
listening port in the first place.
The packaged version does not launch a terminal window, and there's no 
error message poping up when the selected port is not available (on Mac OS 
at least).

Regards,
Manuel
 

>
>
>> On Friday, March 14, 2014 7:34:58 AM UTC+1, audi...@gmail.com wrote:
>>>
>>> Hello,
>>> Thanks to the team for the great tool !
>>> I have minor issues on Mac OS Mavericks, just wanted to check before 
>>> creating an issue on google code.
>>>
>>> System
>>> Mac OS 10.9.2
>>> $ which python
>>> /usr/bin/python
>>> $ python --version
>>> Python 2.7.5
>>>
>>> Steps
>>> download web2py_src.zip
>>> unzip the archive into $basedir
>>> from an Mac administrator account, launch Terminal
>>> $ cd $basedir
>>> $ python web2py.py
>>> ...
>>> Version 2.9.4-stable+timestamp.2014.03.05.04.44.09
>>> ...
>>> The web2py graphical interface launches
>>> Leave "server ip" on "local"
>>> Set "Server Port" to "80"
>>> Enter a password in "Choose password" field
>>> Click on "start server"
>>>
>>> Expected result
>>> web2py framework, start listening on port 80
>>>
>>> Actual result
>>> The terminal output :
>>> ERROR:Rocket.Errors.Port80:Socket 127.0.0.1:80 in use by other process 
>>> and it won't share.
>>> WARNING:Rocket.Errors.Port80:Listener started when not ready.
>>>
>>> What have I tried
>>> Check active ports with Apple's network utility (port scan) : no active 
>>> port between 10 and 100
>>>
>>> Use 
>>> $ sudo python web2py.py
>>> instead of 
>>> $ python web2py.py
>>> Then you can actually launch web2py on port 80
>>> Terminal output :
>>> ...
>>> please visit:
>>> http://127.0.0.1/
>>> starting browser...
>>>
>>> It seems this is related to Mac OS policy to keep use of some ports for 
>>> it's own usage.
>>> My question is wether this is a bug or an enhancement request to have an 
>>> error message in the graphical web2py launch app to inform user ?
>>> (When using the Mac OS package instead of the source version, you don't 
>>> have any feedback on this issue, the server is just not starting).
>>>
>>> As this is my first post on this list, let me know if I made any mistake.
>>> thanks,
>>> Manuel
>>>
>>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.