[GeoNode-users] GeoNode Updateip Error (No module named relationships)

Jeffy John Tomarong jeffytoms at gmail.com
Wed Jul 1 01:08:39 PDT 2015


Nope we dont have a custom configuration. After I installed geonode, all I
editted were on the ipaddress part or the site url. I did not touch the DB
config in the local_settings.py ..

Or is there a way to restore back the local_settings.py, say restore it
back to two days ago? Because I'm afraid I might have overwritten the
local_settings.py with the old backup file of local_settings.py the moment
it got the internal server error..

Thank you Simone!

On Wed, Jul 1, 2015 at 3:54 PM, Simone Dalmasso <simone.dalmasso at gmail.com>
wrote:

> That is because it can't connect to postgresql. Do you have some kind of
> custom configuration?
> That command uses /etc/geonode/local_settings.py to get the db
> configuration
>
> 2015-07-01 9:43 GMT+02:00 Jeffy John Tomarong <jeffytoms at gmail.com>:
>
>> Hi Simone,
>>
>> It did help! Thank you very much for your quick response.. I also did pip
>> install django-request after that.
>>
>> However, when I issued updateip again, I got this:
>>
>> /usr/lib/python2.7/dist-packages/django/conf/__init__.py:221:
>> DeprecationWarning: You have no filters defined on the 'mail_admins'
>> logging handler: adding implicit debug-false-only filter. See
>> http://docs.djangoproject.com/en/dev/releases/1.4/#request-exceptions-are-now-always-logged
>>   DeprecationWarning)
>>
>> OperationalError: could not connect to server: Connection refused
>> Is the server running on host "localhost" (127.0.0.1) and accepting
>> TCP/IP connections on port 5432?
>>
>> Hmm.. ??
>>
>>
>> On Wed, Jul 1, 2015 at 3:31 PM, Simone Dalmasso <
>> simone.dalmasso at gmail.com> wrote:
>>
>>> Hi, I see you are using geonode 2.0
>>>
>>> the missing package should be django-relationships and since your
>>> geonode is installed systemwide you have to use sudo so:
>>> $ sudo pip install  django-relationships
>>>
>>> Hope this helps
>>>
>>> 2015-07-01 9:23 GMT+02:00 Jeffy John Tomarong <jeffytoms at gmail.com>:
>>>
>>>> Hi Good Fellas!
>>>>
>>>> Our GeoNode instance was running well in the previous months. But now,
>>>> it got Internal Server Error 500.
>>>> What I did was to update the IP of geonode (which is just the same
>>>> anyway), and it caused me this error:I also tried "pip install
>>>> relationship" since it displayed there "Error: No Module named
>>>> relationships". But it caused another set of error. GeoNode has been
>>>> running well in the last months, I do not know what happened.
>>>>
>>>> I need your help guys on this. I'm at the end of my wits.
>>>>
>>>> Will be very much appreciated. Thank you!
>>>>
>>>> Here's the error message:
>>>>
>>>> Replacing SITEURL in /etc/geonode/local_settings.py
>>>> Adding entry for local ip in
>>>> /usr/share/geoserver/data//printing/config.yaml
>>>>   IP was already added to the printing whitelist.
>>>> Replacing ALLOWED_HOSTS in /etc/geonode/local_settings.py
>>>>  * Restarting web server apache2
>>>>          apache2: Could not reliably determine the server's fully qualified
>>>> domain name, using 127.0.1.1 for ServerName
>>>>  ... waiting .apache2: Could not reliably determine the server's fully
>>>> qualified domain name, using 127.0.1.1 for ServerName
>>>>
>>>>  [ OK ]
>>>> /usr/lib/python2.7/dist-packages/django/conf/__init__.py:221:
>>>> DeprecationWarning: You have no filters defined on the 'mail_admins'
>>>> logging handler: adding implicit debug-false-only filter. See
>>>> http://docs.djangoproject.com/en/dev/releases/1.4/#request-exceptions-are-now-always-logged
>>>>   DeprecationWarning)
>>>>
>>>> Traceback (most recent call last):
>>>>   File "/usr/bin/django-admin", line 5, in <module>
>>>>     management.execute_from_command_line()
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 453, in execute_from_command_line
>>>>     utility.execute()
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 392, in execute
>>>>     self.fetch_command(subcommand).run_from_argv(self.argv)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 272, in fetch_command
>>>>     klass = load_command_class(app_name, subcommand)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 77, in load_command_class
>>>>     module = import_module('%s.management.commands.%s' % (app_name,
>>>> name))
>>>>   File "/usr/lib/python2.7/dist-packages/django/utils/importlib.py",
>>>> line 35, in import_module
>>>>     __import__(name)
>>>>   File
>>>> "/usr/local/lib/python2.7/dist-packages/geonode/layers/management/commands/updatelayers.py",
>>>> line 23, in <module>
>>>>     from geonode.geoserver.helpers import gs_slurp
>>>>   File
>>>> "/usr/local/lib/python2.7/dist-packages/geonode/geoserver/helpers.py", line
>>>> 31, in <module>
>>>>     from geonode.utils import _user, _password, ogc_server_settings
>>>>   File "/usr/local/lib/python2.7/dist-packages/geonode/utils.py", line
>>>> 36, in <module>
>>>>     from geonode.security.enumerations import AUTHENTICATED_USERS,
>>>> ANONYMOUS_USERS, INVALID_PERMISSION_MESSAGE
>>>>   File
>>>> "/usr/local/lib/python2.7/dist-packages/geonode/security/enumerations.py",
>>>> line 28, in <module>
>>>>     ANONYMOUS_USERS: _('Anonymous Users'),
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/__init__.py",
>>>> line 71, in ugettext
>>>>     return _trans.ugettext(message)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 276, in ugettext
>>>>     return do_translate(message, 'ugettext')
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 258, in do_translate
>>>>     _default = translation(settings.LANGUAGE_CODE)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 172, in translation
>>>>     default_translation = _fetch(settings.LANGUAGE_CODE)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 154, in _fetch
>>>>     app = import_module(appname)
>>>>   File "/usr/lib/python2.7/dist-packages/django/utils/importlib.py",
>>>> line 35, in import_module
>>>>     __import__(name)
>>>> ImportError: No module named relationships
>>>> jjqt at GeoNode:/usr/local/lib/python2.7/dist-packages/geonode$ sudo pico
>>>> local_settings.py
>>>> jjqt at GeoNode:/usr/local/lib/python2.7/dist-packages/geonode$ sudo pico
>>>> settings.py
>>>> jjqt at GeoNode:/usr/local/lib/python2.7/dist-packages/geonode$ sudo pip
>>>> install -e.
>>>> [sudo] password for jjqt:
>>>> --editable=. should be formatted with svn+URL, git+URL, hg+URL or
>>>> bzr+URL
>>>> Storing complete log in /home/jjqt/.pip/pip.log
>>>> jjqt at GeoNode:/usr/local/lib/python2.7/dist-packages/geonode$ sudo
>>>> geonode-updateipcrisp.norminet.org.ph
>>>> Replacing SITEURL in /etc/geonode/local_settings.py
>>>> Adding entry for local ip in
>>>> /usr/share/geoserver/data//printing/config.yaml
>>>>   IP was already added to the printing whitelist.
>>>> Replacing ALLOWED_HOSTS in /etc/geonode/local_settings.py
>>>>  * Restarting web server apache2
>>>>          apache2: Could not reliably determine the server's fully qualified
>>>> domain name, using 127.0.1.1 for ServerName
>>>>  ... waiting .apache2: Could not reliably determine the server's fully
>>>> qualified domain name, using 127.0.1.1 for ServerName
>>>>
>>>>  [ OK ]
>>>> /usr/lib/python2.7/dist-packages/django/conf/__init__.py:221:
>>>> DeprecationWarning: You have no filters defined on the 'mail_admins'
>>>> logging handler: adding implicit debug-false-only filter. See
>>>> http://docs.djangoproject.com/en/dev/releases/1.4/#request-exceptions-are-now-always-logged
>>>>   DeprecationWarning)
>>>>
>>>> Traceback (most recent call last):
>>>>   File "/usr/bin/django-admin", line 5, in <module>
>>>>     management.execute_from_command_line()
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 453, in execute_from_command_line
>>>>     utility.execute()
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 392, in execute
>>>>     self.fetch_command(subcommand).run_from_argv(self.argv)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 272, in fetch_command
>>>>     klass = load_command_class(app_name, subcommand)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line
>>>> 77, in load_command_class
>>>>     module = import_module('%s.management.commands.%s' % (app_name,
>>>> name))
>>>>   File "/usr/lib/python2.7/dist-packages/django/utils/importlib.py",
>>>> line 35, in import_module
>>>>     __import__(name)
>>>>   File
>>>> "/usr/local/lib/python2.7/dist-packages/geonode/layers/management/commands/updatelayers.py",
>>>> line 23, in <module>
>>>>     from geonode.geoserver.helpers import gs_slurp
>>>>   File
>>>> "/usr/local/lib/python2.7/dist-packages/geonode/geoserver/helpers.py", line
>>>> 31, in <module>
>>>>     from geonode.utils import _user, _password, ogc_server_settings
>>>>   File "/usr/local/lib/python2.7/dist-packages/geonode/utils.py", line
>>>> 36, in <module>
>>>>     from geonode.security.enumerations import AUTHENTICATED_USERS,
>>>> ANONYMOUS_USERS, INVALID_PERMISSION_MESSAGE
>>>>   File
>>>> "/usr/local/lib/python2.7/dist-packages/geonode/security/enumerations.py",
>>>> line 28, in <module>
>>>>     ANONYMOUS_USERS: _('Anonymous Users'),
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/__init__.py",
>>>> line 71, in ugettext
>>>>     return _trans.ugettext(message)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 276, in ugettext
>>>>     return do_translate(message, 'ugettext')
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 258, in do_translate
>>>>     _default = translation(settings.LANGUAGE_CODE)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 172, in translation
>>>>     default_translation = _fetch(settings.LANGUAGE_CODE)
>>>>   File
>>>> "/usr/lib/python2.7/dist-packages/django/utils/translation/trans_real.py",
>>>> line 154, in _fetch
>>>>     app = import_module(appname)
>>>>   File "/usr/lib/python2.7/dist-packages/django/utils/importlib.py",
>>>> line 35, in import_module
>>>>     __import__(name)
>>>> ImportError: No module named relationships
>>>> jjqt at GeoNode:/usr/local/lib/python2.7/dist-packages/geonode$ pip
>>>> install relationships
>>>> Downloading/unpacking relationships
>>>> Exception:
>>>> Traceback (most recent call last):
>>>>   File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 126,
>>>> in main
>>>>     self.run(options, args)
>>>>   File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line
>>>> 223, in run
>>>>     requirement_set.prepare_files(finder,
>>>> force_root_egg_info=self.bundle, bundle=self.bundle)
>>>>   File "/usr/lib/python2.7/dist-packages/pip/req.py", line 942, in
>>>> prepare_files
>>>>     location = req_to_install.build_location(self.build_dir, not
>>>> self.is_download)
>>>>   File "/usr/lib/python2.7/dist-packages/pip/req.py", line 144, in
>>>> build_location
>>>>     _make_build_dir(build_dir)
>>>>   File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1185, in
>>>> _make_build_dir
>>>>     os.makedirs(build_dir)
>>>>   File "/usr/lib/python2.7/os.py", line 157, in makedirs
>>>>     mkdir(name, mode)
>>>> OSError: [Errno 13] Permission denied:
>>>> '/usr/local/lib/python2.7/dist-packages/geonode/build'
>>>>
>>>> Storing complete log in /home/jjqt/.pip/pip.log
>>>> Traceback (most recent call last):
>>>>   File "/usr/bin/pip", line 9, in <module>
>>>>     load_entry_point('pip==1.0', 'console_scripts', 'pip')()
>>>>   File "/usr/lib/python2.7/dist-packages/pip/__init__.py", line 116, in
>>>> main
>>>>     return command.main(initial_args, args[1:], options)
>>>>   File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 147,
>>>> in main
>>>>     log_fp = open_logfile(log_fn, 'w')
>>>>   File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 176,
>>>> in open_logfile
>>>>     log_fp = open(filename, mode)
>>>> IOError: [Errno 13] Permission denied: '/home/jjqt/.pip/pip.log'
>>>>
>>>> _______________________________________________
>>>> geonode-users mailing list
>>>> geonode-users at lists.osgeo.org
>>>> http://lists.osgeo.org/cgi-bin/mailman/listinfo/geonode-users
>>>>
>>>>
>>>
>>>
>>> --
>>> Simone
>>>
>>
>>
>
>
> --
> Simone
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20150701/141289ec/attachment-0001.html>


More information about the geonode-users mailing list