You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pegasus.apache.org by "ninsmiracle (via GitHub)" <gi...@apache.org> on 2024/08/30 11:37:50 UTC
[I] How to connected to target cluster via pegasus shell config [incubator-pegasus]
ninsmiracle opened a new issue, #2108:
URL: https://github.com/apache/incubator-pegasus/issues/2108
## General Question
I have read the documentation, but can not found the way that use `./run.sh shell --config my_config.ini` to connected to my target cluster. In other word, I don't know how to config it.
I tried to use the config file named `my_cluster.cfg` which I used to deployed cluster. But it not work,with the error like this:
```
W2024-08-30 11:17:43.874 (1725016663874826365 42119) : overwrite default thread pool for task RPC_CM_QUERY_PARTITION_CONFIG_BY_INDEX_ACK from THREAD_POOL_META_SERVER to THREAD_POOL_DEFAULT
Pegasus Shell 2.4.5-without-slog
Type "help" for more information.
Type "Ctrl-D" or "Ctrl-C" to exit the shell.
cannot find factory '' with factory type provider
the following 2 factories are registered:
nativerun (type: provider)
simulator (type: provider)
Please specify the correct factory name in your tool_app or in configuration file
got signal id: 11
./run.sh: line 1724: 42119 Segmentation fault ./pegasus_shell ${CONFIG} $CLUSTER_NAM
```
And I read the code , I think we should get the section named[meta] to get meta list , I just konw how to write the xxxx.ini file

--
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: dev-unsubscribe@pegasus.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pegasus.apache.org
For additional commands, e-mail: dev-help@pegasus.apache.org
Re: [I] How to connected to target cluster via pegasus shell config [incubator-pegasus]
Posted by "ninsmiracle (via GitHub)" <gi...@apache.org>.
ninsmiracle commented on issue #2108:
URL: https://github.com/apache/incubator-pegasus/issues/2108#issuecomment-2323744215
When I change the file `src/shell/main.cpp` and `run.sh` (I want to make pegasus shell connected to target cluster forcely).
Executing any command will time out.

If I'm not change the file , pegasus shell will be never connected to target cluster and always connected to `onebox` cluster.
--
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: dev-unsubscribe@pegasus.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pegasus.apache.org
For additional commands, e-mail: dev-help@pegasus.apache.org
Re: [I] How to connected to target cluster via pegasus shell config [incubator-pegasus]
Posted by "ninsmiracle (via GitHub)" <gi...@apache.org>.
ninsmiracle commented on issue #2108:
URL: https://github.com/apache/incubator-pegasus/issues/2108#issuecomment-2320966698
I also copy the config.ini file in `CONFIG=${ROOT}/config-shell.ini.$PID`
file like this:
```
[apps..default]
run = true
count = 1
[apps.mimic]
type = dsn.app.mimic
arguments =
pools = THREAD_POOL_DEFAULT,THREAD_POOL_META_SERVER
run = true
count = 1
[core]
tool = nativerun
pause_on_start = false
logging_start_level = LOG_LEVEL_DEBUG
logging_factory_name = dsn::tools::simple_logger
logging_flush_on_exit = false
enable_default_app_mimic = true
data_dir = ./pegasus_shell.data
[tools.simple_logger]
short_header = false
fast_flush = true
max_number_of_log_files_on_disk = 10
stderr_start_level = LOG_LEVEL_FATAL
[tools.simulator]
random_seed = 0
[network]
io_service_worker_count = 4
[threadpool..default]
worker_count = 4
partitioned = false
worker_priority = THREAD_xPRIORITY_NORMAL
[threadpool.THREAD_POOL_DEFAULT]
name = default
worker_count = 20
[threadpool.THREAD_POOL_META_SERVER]
name = meta_server
[task..default]
is_trace = false
is_profile = false
allow_inline = false
rpc_call_header_format = NET_HDR_DSN
rpc_call_channel = RPC_CHANNEL_TCP
rpc_timeout_milliseconds = 10000
[pegasus.clusters]
my_cluster = ip:port,ip2:port
[security]
enable_auth = true
krb5_keytab = /home/work/pegasus/xxxxx.keytab
krb5_config = /etc/krb5.conf
krb5_principal = xxxx@xxxx.realm
sasl_plugin_path = /home/work/pegasus/thirdparty/output/lib/sasl2
service_fqdn = my_cluster_master_meta_host_name
service_name = my_cluster
```
It worked,
But pegasus-shell connected to onebox, I am so confused , because I think I configed meta-list in `[pegasus.clusters]`.
During my operation, the output of the shell is as follows
```
[root@xxxxxx pegasus]# ./run.sh shell --config ker.ini
W2024-08-30 11:41:19.453 (1725018079453708642 42130) : overwrite default thread pool for task RPC_CM_QUERY_PARTITION_CONFIG_BY_INDEX from THREAD_POOL_META_SERVER to THREAD_POOL_DEFAULT
W2024-08-30 11:41:19.453 (1725018079453808438 42130) : overwrite default thread pool for task RPC_CM_QUERY_PARTITION_CONFIG_BY_INDEX_ACK from THREAD_POOL_META_SERVER to THREAD_POOL_DEFAULT
Pegasus Shell 2.4.5-without-slog
Type "help" for more information.
Type "Ctrl-D" or "Ctrl-C" to exit the shell.
The config file is: ker.ini
The cluster name is: onebox
The cluster meta list is:
>>> ls
list apps failed, error=ERR_TIMEOUT
>>>
```
--
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: dev-unsubscribe@pegasus.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pegasus.apache.org
For additional commands, e-mail: dev-help@pegasus.apache.org