Path: ...!weretis.net!feeder9.news.weretis.net!feeder8.news.weretis.net!news.szaf.org!inka.de!mips.inka.de!.POSTED.localhost!not-for-mail From: Christian Weisgerber Newsgroups: comp.unix.shell Subject: Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs? Date: Sun, 12 May 2024 09:47:16 -0000 (UTC) Message-ID: References: Injection-Date: Sun, 12 May 2024 09:47:16 -0000 (UTC) Injection-Info: lorvorc.mips.inka.de; posting-host="localhost:::1"; logging-data="64859"; mail-complaints-to="usenet@mips.inka.de" User-Agent: slrn/1.0.3 (FreeBSD) Bytes: 1387 Lines: 25 On 2024-05-12, Lawrence D'Oliveiro wrote: >> If no job is running, a new job gets 1, otherwise new jobs are numbered >> consecutively. > > Job numbers are reused after it has notified you of termination of the > previous job. At least in Bash. Demonstrably false: bash$ sleep 10 & [1] 64882 bash$ sleep 200 & [2] 64883 bash$ sleep 300 & [3] 64884 bash$ sleep 400 & [4] 64885 [1] Done sleep 10 bash$ sleep 500 & [5] 64886 bash$ sleep 600 & [6] 64887 -- Christian "naddy" Weisgerber naddy@mips.inka.de