Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

steampipe service status gives "invalid memory address or nil pointer dereference" error #3159

Closed
e-gineer opened this issue Feb 26, 2023 · 4 comments
Labels
bug Something isn't working needs reproduction Reproduction steps are not defined for this issue stale No recent activity has been detected on this issue/PR and it will be closed

Comments

@e-gineer
Copy link
Contributor

I was running steampipe service yesterday. Today when starting my machine I couldn't connect to it. I ran steampipe service status to check, and got a crash.

Killing the stray steampipe processes got everything working again.

Details:

~/src/steampipe-pipelines $ steampipe --version
Steampipe v0.19.0-rc.3
~/src/steampipe-pipelines $ STEAMPIPE_LOG=trace steampipe service status
2023-02-26 14:35:12.054 UTC [TRACE] steampipe: parse complete after 1 decode passes
2023-02-26 14:35:12.054 UTC [TRACE] steampipe: ensureInstallDir /Users/nathan/.steampipe
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: Connection.PopulateChildren for aggregator connection aws
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: Connection.PopulateChildren no connection matches * - treating as a wildcard
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: connection 'aws_nagraj' matches pattern '*'
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: connection 'aws_morales' matches pattern '*'
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: Connection.PopulateChildren for aggregator connection exec
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: Connection.PopulateChildren no connection matches * - treating as a wildcard
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: connection 'instance' matches pattern '*'
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: connection 'exec22' matches pattern '*'
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: connection 'exec23' matches pattern '*'
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: No memory limit set
2023-02-26 14:35:12.058 UTC [TRACE] steampipe: GetRunStatus - loadRunningInstanceInfo returned nil
Error: runtime error: invalid memory address or nil pointer dereference
~/src/steampipe-pipelines $ ps aux | grep steampipe
nathan           25260   0.0  0.1 409330128  44784 s002  S    10:05AM   0:11.05 /usr/local/bin/steampipe plugin-manager --install-dir /Users/nathan/.steampipe
nathan           76957   0.0  0.0 408495808   1104 s000  R+    9:35AM   0:00.00 grep steampipe
nathan           25317   0.0  0.3 410053760 105680 s002  S    10:05AM   0:10.14 /Users/nathan/.steampipe/plugins/hub.steampipe.io/plugins/turbot/aws@latest/steampipe-plugin-aws.plugin
nathan           25271   0.0  0.1 409659984  17504 s002  S    10:05AM   0:06.16 /Users/nathan/.steampipe/plugins/hub.steampipe.io/plugins/turbot/csv@latest/steampipe-plugin-csv.plugin
~/src/steampipe-pipelines $ pkill -f steampipe
~/src/steampipe-pipelines $ ps aux | grep steampipe
nathan           76960   0.0  0.0 408626880   1328 s000  S+    9:35AM   0:00.00 grep steampipe
~/src/steampipe-pipelines $ STEAMPIPE_LOG=trace steampipe service status
2023-02-26 14:35:34.967 UTC [TRACE] steampipe: parse complete after 1 decode passes
2023-02-26 14:35:34.967 UTC [TRACE] steampipe: ensureInstallDir /Users/nathan/.steampipe
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: Connection.PopulateChildren for aggregator connection aws
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: Connection.PopulateChildren no connection matches * - treating as a wildcard
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: connection 'aws_nagraj' matches pattern '*'
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: connection 'aws_morales' matches pattern '*'
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: Connection.PopulateChildren for aggregator connection exec
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: Connection.PopulateChildren no connection matches * - treating as a wildcard
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: connection 'exec22' matches pattern '*'
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: connection 'exec23' matches pattern '*'
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: connection 'instance' matches pattern '*'
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: No memory limit set
2023-02-26 14:35:34.970 UTC [TRACE] steampipe: GetRunStatus - loadRunningInstanceInfo returned nil
Service is not running
@e-gineer e-gineer added the bug Something isn't working label Feb 26, 2023
@e-gineer
Copy link
Contributor Author

Today my status command works, but stop crashes.

~/src/steampipe-pipelines $ steampipe service status
Steampipe service is running:

Database:

  Host(s):            localhost, 127.0.0.1, 192.168.7.232
  Port:               9193
  Database:           steampipe
  User:               steampipe
  Password:           ********* [use --show-password to reveal]
  Connection string:  postgres://steampipe@localhost:9193/steampipe

Managing the Steampipe service:

  # Get status of the service
  steampipe service status
	 
  # View database password for connecting from another machine
  steampipe service status --show-password
  
  # Restart the service
  steampipe service restart
  
  # Stop the service
  steampipe service stop

~/src/steampipe-pipelines $ 
~/src/steampipe-pipelines $ 
~/src/steampipe-pipelines $ steampipe service stop
Error: runtime error: invalid memory address or nil pointer dereference
~/src/steampipe-pipelines $ 
~/src/steampipe-pipelines $ STEAMPIPE_LOG=trace steampipe service stop
2023-02-27 16:13:57.109 UTC [TRACE] steampipe: parse complete after 1 decode passes
2023-02-27 16:13:57.109 UTC [TRACE] steampipe: ensureInstallDir /Users/nathan/.steampipe
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: Connection.PopulateChildren for aggregator connection aws
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: Connection.PopulateChildren no connection matches * - treating as a wildcard
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: connection 'aws_morales' matches pattern '*'
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: connection 'aws_nagraj' matches pattern '*'
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: Connection.PopulateChildren for aggregator connection exec
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: Connection.PopulateChildren no connection matches * - treating as a wildcard
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: connection 'exec23' matches pattern '*'
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: connection 'instance' matches pattern '*'
2023-02-27 16:13:57.112 UTC [TRACE] steampipe: connection 'exec22' matches pattern '*'
2023-02-27 16:13:57.113 UTC [TRACE] steampipe: No memory limit set
2023-02-27 16:13:57.159 UTC [TRACE] steampipe: SQLInfoMap >>> map[dbname:steampipe host:localhost port:9193 sslmode:disable user:root]
2023-02-27 16:13:57.159 UTC [TRACE] steampipe: PSQLInfo >>> [host=localhost port=9193 user=root dbname=steampipe sslmode=disable]
Error: runtime error: invalid memory address or nil pointer dereference
~/src/steampipe-pipelines $ 
~/src/steampipe-pipelines $ 
~/src/steampipe-pipelines $ ps aux | grep steampipe
nathan           77395   0.0  0.3 410108864  92416 s000  S    Sun09AM   0:15.77 /Users/nathan/.steampipe/plugins/hub.steampipe.io/plugins/turbot/aws@latest/steampipe-plugin-aws.plugin
nathan           77242   0.0  0.1 409650000  17040 s000  S    Sun09AM   0:09.63 /Users/nathan/.steampipe/plugins/hub.steampipe.io/plugins/turbot/csv@latest/steampipe-plugin-csv.plugin
nathan           77231   0.0  0.1 409337456  41088 s000  S    Sun09AM   0:16.83 /usr/local/bin/steampipe plugin-manager --install-dir /Users/nathan/.steampipe
nathan           77219   0.0  0.0 408931232   2896   ??  Ss   Sun09AM   0:00.02 postgres: steampipe: logical replication launcher                   
nathan           77218   0.0  0.0 408717440   2064   ??  Ss   Sun09AM   0:04.06 postgres: steampipe: stats collector                   
nathan           77217   0.0  0.0 408962976   3600   ??  Ss   Sun09AM   0:01.00 postgres: steampipe: autovacuum launcher                   
nathan           77216   0.0  0.0 408931232   1952   ??  Ss   Sun09AM   0:00.19 postgres: steampipe: walwriter                   
nathan           77215   0.0  0.0 408939424   4224   ??  Ss   Sun09AM   0:00.20 postgres: steampipe: background writer                   
nathan           77214   0.0  0.0 408940448   5264   ??  Ss   Sun09AM   0:00.06 postgres: steampipe: checkpointer                   
nathan           77212   0.0  0.0 408691840   1344   ??  Ss   Sun09AM   0:00.01 postgres: steampipe: logger                   
nathan           77211   0.0  0.0 408794336   9152 s000  S    Sun09AM   0:01.44 /Users/nathan/.steampipe/db/14.2.0/postgres/bin/postgres -p 9193 -c listen_addresses="*" -c application_name=steampipe -c cluster_name=steampipe -c log_directory=/Users/nathan/.steampipe/logs -c ssl=on -c ssl_cert_file=/Users/nathan/.steampipe/db/14.2.0/data/server.crt -c ssl_key_file=/Users/nathan/.steampipe/db/14.2.0/data/server.key -D /Users/nathan/.steampipe/db/14.2.0/data
nathan           60794   0.0  0.0 408636096   1488 s000  S+   11:14AM   0:00.00 grep steampipe
nathan           56961   0.0  0.2 410008144  52112   ??  Ss   10:44AM   0:01.12 postgres: steampipe: steampipe steampipe ::1(60600) idle                  
~/src/steampipe-pipelines $ 

@github-actions
Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days.

@github-actions github-actions bot added the stale No recent activity has been detected on this issue/PR and it will be closed label Apr 29, 2023
@binaek binaek added needs reproduction Reproduction steps are not defined for this issue and removed stale No recent activity has been detected on this issue/PR and it will be closed labels May 10, 2023
@github-actions
Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days.

@github-actions github-actions bot added the stale No recent activity has been detected on this issue/PR and it will be closed label Jul 10, 2023
@github-actions
Copy link

This issue was closed because it has been stalled for 90 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Aug 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs reproduction Reproduction steps are not defined for this issue stale No recent activity has been detected on this issue/PR and it will be closed
Projects
None yet
Development

No branches or pull requests

2 participants