You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2022/06/12 19:57:00 UTC

[jira] [Commented] (SOLR-16191) Sanity-check assumptions about Linux `ps` command in `solr/bin/solr` script

    [ https://issues.apache.org/jira/browse/SOLR-16191?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17553327#comment-17553327 ] 

ASF subversion and git services commented on SOLR-16191:
--------------------------------------------------------

Commit 97ff472bb29ec4acc7c35d5e95355f40434c4b43 in lucene-solr's branch refs/heads/branch_8_11 from Mike Drob
[ https://gitbox.apache.org/repos/asf?p=lucene-solr.git;h=97ff472bb29 ]

SOLR-16191: Fix backport issues


> Sanity-check assumptions about Linux `ps` command in `solr/bin/solr` script
> ---------------------------------------------------------------------------
>
>                 Key: SOLR-16191
>                 URL: https://issues.apache.org/jira/browse/SOLR-16191
>             Project: Solr
>          Issue Type: Improvement
>          Components: scripts and tools
>    Affects Versions: 9.0, 8.11.2, main (10.0)
>            Reporter: Michael Gibney
>            Assignee: Mike Drob
>            Priority: Minor
>             Fix For: 8.11.2, 9.1, main (10.0), 9.0.1
>
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> SOLR-15558 made more apparent some assumptions/implicit dependencies on the Linux {{ps}} command in the {{solr/bin/solr}} script. The script already [disables running in cygwin|https://github.com/apache/solr/blob/f5e927ed1ed9cb43ac843cac4e12b6edc1b8a904/solr/bin/solr#L58-L63] because of utility version incompatibility, but perhaps we could also/instead add "walks like a duck" sanity-check, e.g.:
> {code:sh}
> if [ "$$" != "`ps -o pid='' $$`" ]; then
>   exit 1
> fi
> {code}
> The issue arose while running {{gradlew :solr:packaging:integrationTests}} for Alpine Linux with BusyBox {{ps}} installed, for which {{ps -o pid='' $WHATEVER}} dumps all running pids, regardless of the value of {{$WHATEVER}}. The behavior observed appeared mainly to affect {{solr stop}}, where the command watches for the PID to exit, but the pid is never detected as having exited. I'm not sure, it's possible that jstack/kill was being run against random PIDs!



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org