2015년 1월 9일 금요일

[hue-user] Hue mysql Database setup fails

I have been trying to set up hue to an external mysql database & it fails with below error when I try to do a         

    sudo -u hue hue/build/env/bin/hue dumpdata > tmp.json   
        
mysql host is 127.0.1.1

I granted privileges to hue user using command:
grant all on hue.* to 'hue'@'%' identified by '123';

in pseudo-distributed.ini i made the following changes in [database] section:
 engine=mysql
    host=127.0.1.1
    port=3306
    user=hue
    password=123
    name=hue
    ## options={}
& yet it fails with below error:        

    
    File "hue/build/env/bin/hue", line 8, in <module>
        load_entry_point('desktop==3.7.0', 'console_scripts', 'hue')()
      File "/home/vamsi/hue/desktop/core/src/desktop/manage_entry.py", line 60, in entry
        execute_manager(settings)
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/core/management/__init__.py", line 459, in execute_manager
        utility.execute()
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/core/management/__init__.py", line 382, in execute
        self.fetch_command(subcommand).run_from_argv(self.argv)
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/core/management/base.py", line 196, in run_from_argv
        self.execute(*args, **options.__dict__)
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/core/management/base.py", line 231, in execute
        self.validate()
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/core/management/base.py", line 266, in validate
        num_errors = get_validation_errors(s, app)
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/core/management/validation.py", line 103, in get_validation_errors
        connection.validation.validate_field(e, opts, f)
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/db/backends/mysql/validation.py", line 14, in validate_field
        db_version = self.connection.get_server_version()
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/db/backends/mysql/base.py", line 415, in get_server_version
        self.cursor().close()
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/db/backends/__init__.py", line 317, in cursor
        cursor = self.make_debug_cursor(self._cursor())
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/Django-1.4.5-py2.7.egg/django/db/backends/mysql/base.py", line 387, in _cursor
        self.connection = Database.connect(**kwargs)
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/MySQL_python-1.2.3c1-py2.7-linux-i686.egg/MySQLdb/__init__.py", line 81, in Connect
        return Connection(*args, **kwargs)
      File "/home/vamsi/hue/build/env/lib/python2.7/site-packages/MySQL_python-1.2.3c1-py2.7-linux-i686.egg/MySQLdb/connections.py", line 188, in __init__
        super(Connection, self).__init__(*args, **kwargs2)
    _mysql_exceptions.OperationalError: (2003, "Can't connect to MySQL server on '127.0.1.1' (111)")    

Any help would be really appreciated. I am ready for a team viewer interaction too, if someone could solve this issue for me.



Perhaps there's a typo in the config -- to use the IPv4 loopback address, I believe it should be "127.0.0.1"



Thank U so much Andrew. It solved my issue. Thx for such quick response. I owe U.



Now I am experiencing this issue when I try to run a pigscript. what could have been the problem?.Please help!



댓글 없음:

댓글 쓰기