web2py still unable to create application on WebFaction

319 views
Skip to first unread message

JoeCodeswell

unread,
Feb 22, 2011, 11:15:04 AM2/22/11
to web2py-users
Dear Webfacton Support and "web2py-users" Google Group,

ref: "web2py-users" Google Group thread ""Unable to create
application" on WebFaction" the link is in the text below.

I just made a flurry of webfaction tickets about memory usage and
upgrading my account. Actually doing an upgrade.

This was because i had just used the web2py Custom Installation Script
from the WebFaction Control Panel to install a new web2py instance.
When i went to add a new app to the new web2py, up came a message
saying "unable to create application "home" (it may exist already)". I
tried every name in the book but to no avail. I googled the problem,
and one entry showed there could be a memory issue. That is the cause
of the flurry of tickets. Now i have found out that the memory issue
is NOT the problem. I have plenty of memory, having upgraded, but i
still get the bad behaviour.

I have done more research on the problem in the "web2py-users" Google
Group. There is a recent [Dec 15, 2010] thread on this subject which
seems to imply that running the web2py Custom Installation Script from
the Control Panel causes a critical directory [deposit] to be left off
the installation. Here is the link to that thread:
http://groups.google.com/group/web2py/browse_thread/thread/98d3d1d2de7d2945/0eb856b9762780af?hl=en&lnk=gst&q=unable+to+create+application+#0eb856b9762780af

I have looked at both of my web2py installations and they both have a
"deposit" directory, but i still cannot create an app in my
w2p_mobyjoe installation.

I can easily create a new app on the old instance. Here is the output:
"new application "justforkicks" created".

Does anyone have any ideas?

I am cross posting this on both the "web2py-users" Google Group and
WebFaction Ticket System. All of the folks in both of these groups are
very supportive.

Thanks in advance.

Love and peace,

Joe

Saf Hulou

unread,
Mar 1, 2011, 7:48:06 AM3/1/11
to web2py-users
I have the same problem. Installed today. Admin allows me to edit
current apps such as the examples app - can create new views etc. No
new apps though. Help would be much appreciated...
Thanks,
Saf

On Feb 22, 4:15 pm, JoeCodeswell <joecodesw...@gmail.com> wrote:
> Dear Webfacton Support and "web2py-users" Google Group,
>
> ref: "web2py-users" Google Group thread ""Unable to create
> application" on WebFaction" the link is in the text below.
>
> I just made a flurry of webfaction tickets about memory usage and
> upgrading my account. Actually doing an upgrade.
>
> This was because i had just used the web2py Custom Installation Script
> from the WebFaction Control Panel to install a new web2py instance.
> When i went to add a new app to the new web2py, up came a message
> saying "unable to create application "home" (it may exist already)". I
> tried every name in the book but to no avail. I googled the problem,
> and one entry showed there could be a memory issue. That is the cause
> of the flurry of tickets. Now i have found out that the memory issue
> is NOT the problem. I have plenty of memory, having upgraded, but i
> still get the bad behaviour.
>
> I have done more research on the problem in the "web2py-users"  Google
> Group. There is a recent [Dec 15, 2010] thread on this subject which
> seems to imply that running the web2py Custom Installation Script from
> the Control Panel causes a critical directory [deposit] to be left off
> the installation. Here is the link to that thread:http://groups.google.com/group/web2py/browse_thread/thread/98d3d1d2de...

Massimo Di Pierro

unread,
Mar 1, 2011, 9:23:22 AM3/1/11
to web2py-users
Looks like you have write permission in each app folder, but no write
permission inside the parent applications folder.

danto

unread,
Mar 1, 2011, 1:41:17 PM3/1/11
to web...@googlegroups.com
try creating a new app from ssh and probably will work.

also, you can always dev on localhost and later upload the app to webfaction

Christopher Steel

unread,
Mar 1, 2011, 6:54:42 PM3/1/11
to web2py-users
If you really want to do this you shodl be able to but first you need
to ssh in and manually start Web2py from webapps/yourapp/web2py with
something like the following:

python2.5 web2py.py -p 80

Then shut it down and try again from the web interface

Let me know how it goes...

JoeCodeswell

unread,
Mar 5, 2011, 2:35:47 PM3/5/11
to web2py-users
Dear Christopher and All,

Something like you, Christopher, suggested was also suggested by the
Webfaction Support folks. This suggestion worked for me, after I had
investigated some other possibilities.

You can read my blog post on this subject, "Fixing my "my web2py is
unable to create a new application on WebFaction" problem", which
references THIS web2py-users thread for "a full discussion of the
problem". Here is the link http://joecodeswell.blogspot.com/2011/02/fixing-my-my-web2py-is-unable-to-create.html

Thanks for the help.

Love and peace,

Joe

On Mar 1, 3:54 pm, Christopher Steel <chris.st...@gmail.com> wrote:
> If you really want to do this you shodl be able to but first you need
> to ssh in and manually start Web2py from webapps/yourapp/web2py with
> something like the following:
>
> python2.5 web2py.py -p 80
>
> Then shut it down and try again from the web interface
>
> Let me know how it goes...
>
> On 1 mar, 07:48, Saf Hulou <saf.hu...@gmail.com> wrote:
>
> > I have the same problem. Installed today. Admin allows me to edit
> > current apps such as the examples app - can create new views etc. No
> > new apps though. Help would be much appreciated...
> > Thanks,
> > Saf
>

Jonathan Lundell

unread,
Mar 5, 2011, 3:07:39 PM3/5/11
to web...@googlegroups.com
On Mar 5, 2011, at 11:35 AM, JoeCodeswell wrote:
>
> Something like you, Christopher, suggested was also suggested by the
> Webfaction Support folks. This suggestion worked for me, after I had
> investigated some other possibilities.
>
> You can read my blog post on this subject, "Fixing my "my web2py is
> unable to create a new application on WebFaction" problem", which
> references THIS web2py-users thread for "a full discussion of the
> problem". Here is the link http://joecodeswell.blogspot.com/2011/02/fixing-my-my-web2py-is-unable-to-create.html

Do we know what's going on here? I'm guessing that it's the initialization of the admin password.

Jonathan Lundell

unread,
Mar 5, 2011, 3:54:19 PM3/5/11
to web...@googlegroups.com

On second thought, that's not it. It'd be good to track it down and fix it, though.

Noel Villamor

unread,
Apr 8, 2012, 7:17:22 PM4/8/12
to web...@googlegroups.com

Hi All,

I encountered this issue as well. Here is how I resolved it.

- web2py directory should have welcome.w2p

Happy Easter!

Noel Villamor

JoeCodeswell

unread,
Jun 7, 2012, 9:35:19 PM6/7/12
to web...@googlegroups.com
Hi Noel,

I had this problem occur AGAIN, TODAY on WebFaction, when I upgraded to Version 1.99.7 (2012-03-04 22:12:08) stable, Running on Apache/2.2.17 (Unix) mod_wsgi/3.3 Python/2.7.3. When creating a new simple app from the web admin interface i get "unable to create application "newapp" (it may exist already)"

I checked and there is NO  welcome.w2p in the  web2py directory. Here are the ssh commands i used.

$ cd PATH/w2py/apache2/bin
$ ./stop

$ cd ../..
$ rm web2py_src.zip

$ unzip -q web2py_src.zip
replace web2py/gluon/__init__.py? [y]es, [n]o, [A]ll, [N]one, [r]ename: A

$ cd PATH/w2py/apache2/bin
$ ./start

$ cd ../..
$ cd web2py
$ ls
anyserver
.py         gaehandler.py         options_std.py      setup_exe.py
appengine_config
.py  gluon                 parameters_80.py    setup.py
app
.example.yaml     __init__.py           queue.example.yaml  site-packages
applications         isapiwsgihandler
.py   README              splashlogo.gif
cgihandler
.py        LICENSE               router.example.py   VERSION
CHANGELOG            logging
.example.conf  routes.example.py   web2py.py
deposit              logs                  scgihandler
.py      wsgihandler.py
epydoc
.conf          Makefile              scripts
epydoc
.css           modpythonhandler.py   setup_app.py
fcgihandler
.py       NEWINSTALL            setup_exe_2.6.py



Is the  welcome.w2p file missing in Version 1.99.7? How can it be replaced?

I'll start up a new topic entitled "Is the  welcome.w2p file missing in Version 1.99.7?

Thanks for the help.

Love and peace,

Joe



Massimo Di Pierro

unread,
Jun 7, 2012, 10:52:59 PM6/7/12
to web...@googlegroups.com
The file welcome.w2p does not ship with web2py. It is created when the file NEWINSTALL is present. NEWINSTALL ships with web2py. How did you upgrade? If you upgrade from trunk, it is not there.

pbreit

unread,
Jun 8, 2012, 8:14:27 PM6/8/12
to web...@googlegroups.com
I always just copy applications/welcome. Works perfectly every time.

Alan Etkin

unread,
Aug 3, 2012, 10:13:01 AM8/3/12
to web...@googlegroups.com
On Thursday, June 7, 2012 6:35:19 PM UTC-7, JoeCodeswell wrote:
Hi Noel,

I had this problem occur AGAIN, TODAY on WebFaction, when I upgraded to Version 1.99.7 (2012-03-04 22:12:08) stable, Running on Apache/2.2.17 (Unix) mod_wsgi/3.3 Python/2.7.3. When creating a new simple app from the web admin interface i get "unable to create application "newapp" (it may exist already)"

I checked and there is NO  welcome.w2p in the  web2py directory. Here are the ssh commands i used.

The same issue but with an installation script on CentOS. The web2py daemon does not seem to create the .w2p file, so the NEWINSTALL file remains whenever web2py is started and creating new apps from the admin fails.

I'd like to start and stop the rocket server within the installation .sh script as a workaround, but there is no web2py.py option to start and stop the builtin server.

Perhaps I can download a stable welcome.w2p package during installation from somewhere and remove the NEWINSTALL. Would be that possible?

Jonathan Lundell

unread,
Aug 3, 2012, 10:55:18 AM8/3/12
to web...@googlegroups.com
I didn't check the shell syntax, but you get the idea.

if [ -f NEWINSTALL -a -d applications/welcome ]; then
python -c "from gluon.fileutils import w2p_pack; w2p_pack('welcome.w2p','applications/welcome')"
rm NEWINSTALL
fi


Alan Etkin

unread,
Aug 3, 2012, 12:03:57 PM8/3/12
to web...@googlegroups.com

> I didn't check the shell syntax, but you get the idea.

> if [ -f NEWINSTALL -a -d applications/welcome ]; then
>        python -c "from gluon.fileutils import w2p_pack; w2p_pack('welcome.w2p','applications/welcome')"
>        rm NEWINSTALL
> fi

Looks ok, I found this alternative (which is almost identical, but imports widget.py):

sudo -u uwsgi python$PREFIX -c "from gluon.main import save_password;from gluon import widget;save_password('$PW',443);widget.console()"


Borrowed from the ubuntu deployment script to create the admin password, adding the console() call from the web2py start
At least It works if tested separately

Thanks
Reply all
Reply to author
Forward
0 new messages