LooseLab / readfish

CLI tool for flexible and fast adaptive sampling on ONT sequencers
https://looselab.github.io/readfish/
GNU General Public License v3.0
167 stars 31 forks source link

which branch of readfish is suitable? #215

Closed Flower9618 closed 1 year ago

Flower9618 commented 1 year ago

Hi, thank you very much for sharing this very useful tool.

I found many branches of readfish, like issue187, guppy_6, guppy_6_minknow_5. I wonder which branch of readfish is suitable for minknow core version 5.3.1 and guppy version 6.3.8.

Thank you very much.

alexomics commented 1 year ago

What operating system or platform are you intending to use? At the moment the dev_staging branch is up to date for MinION and GridION. For example I would use the following conda environment:

_readfishenv.yml:

name: readfish
channels:
  - bioconda
  - conda-forge
  - defaults
dependencies:
  - python=3.8
  - pip
  - pip:
    - git+https://github.com/nanoporetech/read_until_api@v3.0.0
    - ont-pyguppy-client-lib==6.3.8
    - git+https://github.com/LooseLab/readfish@5478d85f3106b6f496279e2ff38d3e172123120a

then:

conda env create -f readfish_env.yml

For PromethION the guppy_6_minknow_5 branch is up to date.

Flower9618 commented 1 year ago

Hi, thank you very much for your reply.

At the present, I installed readfish in Linux system, and used MinION Mk1C sequencer. Because these two softwares are installed in two independent systems, I would like to create a connection between them using host and port parameter.

After seeing the issues, Maybe issue#187 or dev_staging is a choice. Which branch do you recommend?

Thank you again.

alexomics commented 1 year ago

We haven't run readfish on the Mk1C, it might be possible using the dev_staging branch. But the alignment index may not fit into memory if it is a human genome. In addition, you'll probably need to use the sketch basecalling model.

You may have more luck running the MinKNOW built-in adaptive sampling (which is a beta feature).

Flower9618 commented 1 year ago

Thank you very much for your reply. I will try dev_staging branch of Readfish. :)

Flower9618 commented 1 year ago

Unfortunately, there are some problems when I try to run the playback experiment using dev_staging branch of readfish, after start a run on MinION Mk1C about 5 minutes: INFO 2022-11-17 14:53:21,695 Manager /anaconda3/envs/readfish_dev_staging-env/bin/readfish unblock-all --host *.*.*.* --port 9501 --device FAR94051 --experiment-name Testing ReadFish Unblock All 2022-11-17 14:53:21,695 Manager /anaconda3/envs/readfish_dev_staging-env/bin/readfish unblock-all --host *.*.*.* --port 9501 --device FAR94051 --experiment-name Testing ReadFish Unblock All INFO 2022-11-17 14:53:21,695 Manager batch_size=512 2022-11-17 14:53:21,695 Manager batch_size=512 INFO 2022-11-17 14:53:21,695 Manager cache_size=512 2022-11-17 14:53:21,695 Manager cache_size=512 INFO 2022-11-17 14:53:21,696 Manager channels=[1, 512] 2022-11-17 14:53:21,696 Manager channels=[1, 512] INFO 2022-11-17 14:53:21,696 Manager command=unblock-all 2022-11-17 14:53:21,696 Manager command=unblock-all INFO 2022-11-17 14:53:21,696 Manager device=FAR94051 2022-11-17 14:53:21,696 Manager device=FAR94051 INFO 2022-11-17 14:53:21,696 Manager dry_run=False 2022-11-17 14:53:21,696 Manager dry_run=False INFO 2022-11-17 14:53:21,696 Manager experiment_name=Testing ReadFish Unblock All 2022-11-17 14:53:21,696 Manager experiment_name=Testing ReadFish Unblock All INFO 2022-11-17 14:53:21,696 Manager func=<function run at 0x7f979098ae50> 2022-11-17 14:53:21,696 Manager func=<function run at 0x7f979098ae50> INFO 2022-11-17 14:53:21,696 Manager host=*.*.*.* 2022-11-17 14:53:21,696 Manager host=*.*.*.* INFO 2022-11-17 14:53:21,696 Manager log_file=None 2022-11-17 14:53:21,696 Manager log_file=None INFO 2022-11-17 14:53:21,696 Manager log_format=%(asctime)s %(name)s %(message)s 2022-11-17 14:53:21,696 Manager log_format=%(asctime)s %(name)s %(message)s INFO 2022-11-17 14:53:21,696 Manager log_level=info 2022-11-17 14:53:21,696 Manager log_level=info INFO 2022-11-17 14:53:21,696 Manager port=9501 2022-11-17 14:53:21,696 Manager port=9501 INFO 2022-11-17 14:53:21,696 Manager run_time=172800 2022-11-17 14:53:21,696 Manager run_time=172800 INFO 2022-11-17 14:53:21,696 Manager throttle=0.4 2022-11-17 14:53:21,696 Manager throttle=0.4 INFO 2022-11-17 14:53:21,696 Manager unblock_duration=0.1 2022-11-17 14:53:21,696 Manager unblock_duration=0.1 INFO 2022-11-17 14:53:21,696 Manager workers=1 2022-11-17 14:53:21,696 Manager workers=1 DEBUG 2022-11-17 14:53:21,696 minknow_api Reading ssl certificate DEBUG 2022-11-17 14:53:21,696 minknow_api Getting protocol token DEBUG 2022-11-17 14:53:21,696 minknow_api No protocol token found Traceback (most recent call last): File "/anaconda3/envs/readfish_dev_staging-env/bin/readfish", line 8, in <module> sys.exit(main()) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/cli.py", line 43, in main args.func(parser, args) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/unblock_all.py", line 127, in run position = get_device(args.device, host=args.host, port=args.port) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/utils.py", line 922, in get_device manager = Manager(host=host, port=port) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager.py", line 162, in __init__ version_info = self.rpc.get_version_info() File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager_service.py", line 433, in get_version_info return run_with_retry(self._stub.get_version_info, File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager_service.py", line 96, in run_with_retry result = MessageWrapper(method(message, timeout=timeout), unwraps=unwraps) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 946, in __call__ return _end_unary_response_blocking(state, call, False, None) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 849, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses; last error: UNKNOWN: ipv4:*.*.*.*:9501: Failed to connect to remote host: Connection refused" debug_error_string = "UNKNOWN:failed to connect to all addresses; last error: UNKNOWN: ipv4:*.*.*.*:9501: Failed to connect to remote host: Connection refused {grpc_status:14, created_time:"2022-11-17T14:53:21.70007322+08:00"}"

Then, I try to change port to 22, but it doesn't work either. But I can ping ip address of MinION Mk1C(...) successfully on the machine where readfish is installed.

mattloose commented 1 year ago

Hi

can I clarify a couple of things.

  1. Is readfish running on the mk1c or on a separate Linux box? I think you are running from a separate Linux box?
  2. The deviceID you are using looks like a flowcell ID. This is not the correct ID to use. You should use the ID of the actual sequencing device. On a GridION this would be X1-X5. On a minion it would be the minion name (MN12345). I can immediately remember what the format for a mk1c is. Possibly MC-12345 or similar.

hope that helps a bit.

Flower9618 commented 1 year ago

Thank you very much for your quick reply.

  1. Yes, I am running readfish from a separate Linux box. I can ping ip address of mk1c successfully from the box where readfish is installed.
  2. I try to change the device ID from FAR94051 to MC-111121, but there are the same error message.
mattloose commented 1 year ago

Hi,

The port your are specifying is the old insecure port - you can either omit it from your command and readfish will work it out or specify port 9502 - we suggest not using the --port option.

Hope this fixes it.

We do think that you are liekly to encounter problems with network latency and this isn't our advised way to run this!

Matt

Flower9618 commented 1 year ago

Thank you so much for your reply.

I try to change port to 9502, or omit it. There is another error message: DEBUG 2022-11-18 10:07:55,852 root Unable to connect to manager on port '9502' to retrieve local auth token path Traceback (most recent call last): File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager.py", l ine 51, in get_local_authentication_token_file return service.local_authentication_token_path().path File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager_servic e.py", line 1115, in local_authentication_token_path return run_with_retry(self._stub.local_authentication_token_path, File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager_servic e.py", line 96, in run_with_retry result = MessageWrapper(method(message, timeout=timeout), unwraps=unwraps) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 94 6, in __call__ return _end_unary_response_blocking(state, call, False, None) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 84 9, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:9502: Failed to connect to remote host: Conne ction refused" debug_error_string = "UNKNOWN:failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:9502: Failed to connect to remote host: Connection refused {created_time:"2022-11-18T10:07:55.852513881+08:00", grpc_status:14}" DEBUG 2022-11-18 10:07:55,853 minknow_api Getting protocol token DEBUG 2022-11-18 10:07:55,853 minknow_api No protocol token found DEBUG 2022-11-18 10:07:55,854 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:55,854 minknow_api Error received from rpc 2022-11-18 10:07:55,854 minknow_api Error received from rpc WARNING 2022-11-18 10:07:55,854 minknow_api Failed to connect to minknow instance (retry 1/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:55,854 minknow_api Failed to connect to minknow instance (retry 1/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:56,355 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:56,356 minknow_api Error received from rpc 2022-11-18 10:07:56,356 minknow_api Error received from rpc WARNING 2022-11-18 10:07:56,356 minknow_api Failed to connect to minknow instance (retry 2/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:56,356 minknow_api Failed to connect to minknow instance (retry 2/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:56,857 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:56,858 minknow_api Error received from rpc 2022-11-18 10:07:56,858 minknow_api Error received from rpc WARNING 2022-11-18 10:07:56,858 minknow_api Failed to connect to minknow instance (retry 3/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:56,858 minknow_api Failed to connect to minknow instance (retry 3/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:57,359 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:57,359 minknow_api Error received from rpc 2022-11-18 10:07:57,359 minknow_api Error received from rpc WARNING 2022-11-18 10:07:57,359 minknow_api Failed to connect to minknow instance (retry 4/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:57,359 minknow_api Failed to connect to minknow instance (retry 4/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:57,860 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:57,861 minknow_api Error received from rpc 2022-11-18 10:07:57,861 minknow_api Error received from rpc WARNING 2022-11-18 10:07:57,861 minknow_api Failed to connect to minknow instance (retry 5/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:57,861 minknow_api Failed to connect to minknow instance (retry 5/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused ERROR 2022-11-18 10:07:58,362 root Failed to connect to read until at *.*.*.*: 8000 2022-11-18 10:07:58,362 root Failed to connect to read until at *.*.*.*: 8000 Traceback (most recent call last): File "/anaconda3/envs/readfish_dev_staging-env/bin/readfish", line 8, in <module> sys.exit(main()) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/cli.py", line 43, in ma in args.func(parser, args) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/unblock_all.py", line 1 29, in run read_until_client = RUClient( File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/read_until_client.py", line 28, in __init__ super().__init__(*args, **kwargs) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/read_until/base.py", line 137, in __init__ self.connection = Connection(self.mk_grpc_port) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/__init__.py", line 572, in __init__ raise error File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/__init__.py", line 544, in __init__ self.instance.get_version_info() File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/instance_servi ce.py", line 96, in get_version_info return run_with_retry(self._stub.get_version_info, File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/instance_servi ce.py", line 40, in run_with_retry result = MessageWrapper(method(message, timeout=timeout), unwraps=unwraps) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 94 6, in __call__ return _end_unary_response_blocking(state, call, False, None) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 84 9, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Conne ction refused" debug_error_string = "UNKNOWN:failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused {grpc_status:14, created_time:"2022-11-18T10:07:57.861365827+08:00"}"

I do not know why ip change from what I setting by command to 127.0.0.1:8000 I know the problem is about network latency. But it is the thing I can only do at the moment. Thank you again.

Flower9618 commented 1 year ago

Thank you so much for your reply.

I try to change port to 9502, or omit it. There is another error message: DEBUG 2022-11-18 10:07:55,852 root Unable to connect to manager on port '9502' to retrieve local auth token path Traceback (most recent call last): File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager.py", l ine 51, in get_local_authentication_token_file return service.local_authentication_token_path().path File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager_servic e.py", line 1115, in local_authentication_token_path return run_with_retry(self._stub.local_authentication_token_path, File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/manager_servic e.py", line 96, in run_with_retry result = MessageWrapper(method(message, timeout=timeout), unwraps=unwraps) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 94 6, in __call__ return _end_unary_response_blocking(state, call, False, None) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 84 9, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:9502: Failed to connect to remote host: Conne ction refused" debug_error_string = "UNKNOWN:failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:9502: Failed to connect to remote host: Connection refused {created_time:"2022-11-18T10:07:55.852513881+08:00", grpc_status:14}" DEBUG 2022-11-18 10:07:55,853 minknow_api Getting protocol token DEBUG 2022-11-18 10:07:55,853 minknow_api No protocol token found DEBUG 2022-11-18 10:07:55,854 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:55,854 minknow_api Error received from rpc 2022-11-18 10:07:55,854 minknow_api Error received from rpc WARNING 2022-11-18 10:07:55,854 minknow_api Failed to connect to minknow instance (retry 1/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:55,854 minknow_api Failed to connect to minknow instance (retry 1/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:56,355 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:56,356 minknow_api Error received from rpc 2022-11-18 10:07:56,356 minknow_api Error received from rpc WARNING 2022-11-18 10:07:56,356 minknow_api Failed to connect to minknow instance (retry 2/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:56,356 minknow_api Failed to connect to minknow instance (retry 2/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:56,857 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:56,858 minknow_api Error received from rpc 2022-11-18 10:07:56,858 minknow_api Error received from rpc WARNING 2022-11-18 10:07:56,858 minknow_api Failed to connect to minknow instance (retry 3/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:56,858 minknow_api Failed to connect to minknow instance (retry 3/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:57,359 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:57,359 minknow_api Error received from rpc 2022-11-18 10:07:57,359 minknow_api Error received from rpc WARNING 2022-11-18 10:07:57,359 minknow_api Failed to connect to minknow instance (retry 4/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:57,359 minknow_api Failed to connect to minknow instance (retry 4/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused DEBUG 2022-11-18 10:07:57,860 minknow_api Calling get_version_info to test connection INFO 2022-11-18 10:07:57,861 minknow_api Error received from rpc 2022-11-18 10:07:57,861 minknow_api Error received from rpc WARNING 2022-11-18 10:07:57,861 minknow_api Failed to connect to minknow instance (retry 5/5): failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused 2022-11-18 10:07:57,861 minknow_api Failed to connect to minknow instance (retry 5/5): failed to connect to all addresses; last error: U NKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused ERROR 2022-11-18 10:07:58,362 root Failed to connect to read until at *.*.*.*: 8000 2022-11-18 10:07:58,362 root Failed to connect to read until at *.*.*.*: 8000 Traceback (most recent call last): File "/anaconda3/envs/readfish_dev_staging-env/bin/readfish", line 8, in <module> sys.exit(main()) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/cli.py", line 43, in ma in args.func(parser, args) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/unblock_all.py", line 1 29, in run read_until_client = RUClient( File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/ru/read_until_client.py", line 28, in __init__ super().__init__(*args, **kwargs) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/read_until/base.py", line 137, in __init__ self.connection = Connection(self.mk_grpc_port) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/__init__.py", line 572, in __init__ raise error File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/__init__.py", line 544, in __init__ self.instance.get_version_info() File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/instance_servi ce.py", line 96, in get_version_info return run_with_retry(self._stub.get_version_info, File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/minknow_api/instance_servi ce.py", line 40, in run_with_retry result = MessageWrapper(method(message, timeout=timeout), unwraps=unwraps) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 94 6, in __call__ return _end_unary_response_blocking(state, call, False, None) File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 84 9, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Conne ction refused" debug_error_string = "UNKNOWN:failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8000: Failed to connect to remote host: Connection refused {grpc_status:14, created_time:"2022-11-18T10:07:57.861365827+08:00"}"

I do not know why ip change from what I setting by command to 127.0.0.1:8000 I know the problem is about network latency. But it is the thing I can only do at the moment. Thank you again.

When I check the code according to the error message, I found no host parameter passed into 'minknow_api.connection' class, so this class will use the default host 127.0.0.1. So I change the host into ip address of mk1c and rerun the readifsh unblock-all command, there is new error message: DEBUG 2022-11-18 14:23:18,480 minknow_api Reading ssl certificate DEBUG 2022-11-18 14:23:18,480 minknow_api Getting protocol token DEBUG 2022-11-18 14:23:18,480 minknow_api No protocol token found DEBUG 2022-11-18 14:23:18,481 minknow_api Calling get_version_info to test connection INFO 2022-11-18 14:23:18,552 minknow_api Error received from rpc 2022-11-18 14:23:18,552 minknow_api Error received from rpc ... File "/anaconda3/envs/readfish_dev_staging-env/lib/python3.8/site-packages/grpc/_channel.py", line 84 9, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAUTHENTICATED details = "No authorisation metadata supplied" debug_error_string = "UNKNOWN:Error received from peer ipv4:*.*.*.*:8000 {created_time:"2022-11-18T14:23:18.552639502+08: 00", grpc_status:16, grpc_message:"No authorisation metadata supplied"}"

alexomics commented 1 year ago

This error stems from accessing MinKNOW remotely. You will need to enable guest access to MinKNOW for readfish to connect.

To do this through MinKNOW:

  1. Open 'Host settings' when directly connected to a device
  2. Navigate to the 'Device settings'
  3. Under 'Remote access availability' turn off the switch labeled 'Nanopore account required'

If you do not have 'Device settings' available you can also do this through the command line on the Mk1C:

  1. SSH onto the Mk1C
  2. Run the following commands
    cd /opt/ont/minknow 
    sudo bin/config_editor --conf user --filename conf/user_conf --set network_security.guest_rpc_enabled=enabled
  3. Restart MinKNOW
    sudo systemctl restart minknow

To undo this change:

  1. SSH onto the Mk1C
  2. Run the following commands
    cd /opt/ont/minknow 
    sudo bin/config_editor --conf user --filename conf/user_conf --set_default network_security.guest_rpc_enabled
  3. Restart MinKNOW
    sudo systemctl restart minknow
Flower9618 commented 1 year ago

This error stems from accessing MinKNOW remotely. You will need to enable guest access to MinKNOW for readfish to connect.

To do this through MinKNOW:

  1. Open 'Host settings' when directly connected to a device
  2. Navigate to the 'Device settings'
  3. Under 'Remote access availability' turn off the switch labeled 'Nanopore account required'

If you do not have 'Device settings' available you can also do this through the command line on the Mk1C:

  1. SSH onto the Mk1C
  2. Run the following commands
    cd /opt/ont/minknow 
    sudo bin/config_editor --conf user --filename conf/user_conf --set network_security.guest_rpc_enabled=enabled
  3. Restart MinKNOW
    sudo systemctl restart minknow

To undo this change:

  1. SSH onto the Mk1C
  2. Run the following commands
    cd /opt/ont/minknow 
    sudo bin/config_editor --conf user --filename conf/user_conf --set_default network_security.guest_rpc_enabled
  3. Restart MinKNOW
    sudo systemctl restart minknow

Thank you so much for your patient answer. I will try it and give you feedback in time. Thank you very much again.

Flower9618 commented 1 year ago

Hi, sorry to bother you again. I try to enable guest access to MinKNOW for readfish to connect through MinKNOW. Like this: 图片 1 Then I try to run readfish unblock-all command again. But there is still the same error message as https://github.com/LooseLab/readfish/issues/215#issuecomment-1319603570, "Unable to connect to manager on port '9502' to retrieve local auth token path".

Adoni5 commented 1 year ago

Hi @Flower9618 - do you still need help with this? I'm going to close this issue, but please re-open it if you do!

I think you might have the command set up wrong.

Many Thanks, Rory