You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/08/04 22:49:36 UTC

[GitHub] [airflow] txicos commented on issue #17120: [Scheduler error] psycopg2.OperationalError: SSL SYSCALL error: Socket operation on non-socket

txicos commented on issue #17120:
URL: https://github.com/apache/airflow/issues/17120#issuecomment-893024484


   Hi, 
   
   Hi I also applied suggested correction and raised an Exception just after entering method  `create_scheduler_job`, which indeed occurred when executing `airflow scheduler -D`.
   
   However, I am also getting the error whose log is added below:
   
   Process Process-1:
   Traceback (most recent call last):
     File "/usr/lib/python3.8/multiprocessing/process.py", line 315, in _bootstrap
       self.run()
     File "/usr/lib/python3.8/multiprocessing/process.py", line 108, in run
       self._target(*self._args, **self._kwargs)
     File "/home/airflow/.local/lib/python3.8/site-packages/airflow/utils/serve_logs.py", line 85, in serve_logs
       app.run(host='0.0.0.0', port=worker_log_server_port)
     File "/home/airflow/.local/lib/python3.8/site-packages/flask/app.py", line 990, in run
       run_simple(host, port, self, **options)
     File "/home/airflow/.local/lib/python3.8/site-packages/werkzeug/serving.py", line 1052, in run_simple
       inner()
     File "/home/airflow/.local/lib/python3.8/site-packages/werkzeug/serving.py", line 996, in inner
       srv = make_server(
     File "/home/airflow/.local/lib/python3.8/site-packages/werkzeug/serving.py", line 847, in make_server
       return ThreadedWSGIServer(
     File "/home/airflow/.local/lib/python3.8/site-packages/werkzeug/serving.py", line 740, in __init__
       HTTPServer.__init__(self, server_address, handler)
     File "/usr/lib/python3.8/socketserver.py", line 452, in __init__
       self.server_bind()
     File "/usr/lib/python3.8/http/server.py", line 138, in server_bind
       socketserver.TCPServer.server_bind(self)
     File "/usr/lib/python3.8/socketserver.py", line 466, in server_bind
       self.socket.bind(self.server_address)
   OSError: [Errno 98] Address already in use
   Traceback (most recent call last):
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/engine/base.py", line 2336, in _wrap_pool_connect
       return fn()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/pool/base.py", line 364, in connect
       return _ConnectionFairy._checkout(self)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/pool/base.py", line 809, in _checkout
       result = pool._dialect.do_ping(fairy.connection)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/engine/default.py", line 575, in do_ping
       cursor.execute(self._dialect_specific_select_one)
   psycopg2.OperationalError: SSL SYSCALL error: Socket operation on non-socket
   
   
   The above exception was the direct cause of the following exception:
   
   Traceback (most recent call last):
     File "/home/airflow//.local/bin/airflow", line 8, in <module>
       sys.exit(main())
     File "/home/airflow/.local/lib/python3.8/site-packages/airflow/__main__.py", line 40, in main
       args.func(args)
     File "/home/airflow/.local/lib/python3.8/site-packages/airflow/cli/cli_parser.py", line 48, in command
       return func(*args, **kwargs)
     File "/home/airflow/.local/lib/python3.8/site-packages/airflow/utils/cli.py", line 91, in wrapper
       return f(*args, **kwargs)
     File "/home/airflow/.local/lib/python3.8/site-packages/airflow/cli/commands/scheduler_command.py", line 63, in scheduler
       job.run()
     File "/home/airflow/.local/lib/python3.8/site-packages/airflow/jobs/base_job.py", line 241, in run
       session.commit()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 1046, in commit
       self.transaction.commit()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 504, in commit
       self._prepare_impl()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 483, in _prepare_impl
       self.session.flush()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 2540, in flush
       self._flush(objects)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 2682, in _flush
       transaction.rollback(_capture_exception=True)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/util/langhelpers.py", line 68, in __exit__
       compat.raise_(
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/util/compat.py", line 182, in raise_
       raise exception
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 2642, in _flush
       flush_context.execute()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/unitofwork.py", line 422, in execute
       rec.execute(self)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/unitofwork.py", line 586, in execute
       persistence.save_obj(
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/persistence.py", line 205, in save_obj
       for (
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/persistence.py", line 373, in _organize_states_for_save
       for state, dict_, mapper, connection in _connections_for_states(
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/persistence.py", line 1602, in _connections_for_states
       connection = uowtransaction.transaction.connection(base_mapper)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 314, in connection
       return self._connection_for_bind(bind, execution_options)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 421, in _connection_for_bind
       conn = self._parent._connection_for_bind(bind, execution_options)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/orm/session.py", line 433, in _connection_for_bind
       conn = bind._contextual_connect()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/engine/base.py", line 2302, in _contextual_connect
       self._wrap_pool_connect(self.pool.connect, None),
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/engine/base.py", line 2339, in _wrap_pool_connect
       Connection._handle_dbapi_exception_noconnection(
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/engine/base.py", line 1583, in _handle_dbapi_exception_noconnection
       util.raise_(
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/util/compat.py", line 182, in raise_
       raise exception
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/engine/base.py", line 2336, in _wrap_pool_connect
       return fn()
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/pool/base.py", line 364, in connect
       return _ConnectionFairy._checkout(self)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/pool/base.py", line 809, in _checkout
       result = pool._dialect.do_ping(fairy.connection)
     File "/home/airflow/.local/lib/python3.8/site-packages/sqlalchemy/engine/default.py", line 575, in do_ping
       cursor.execute(self._dialect_specific_select_one)
   sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) SSL SYSCALL error: Socket operation on non-socket
   
   (Background on this error at: http://sqlalche.me/e/13/e3q8)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org