Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 11/18/2018 12:20 PM, Bruce Dubbs via blfs-dev wrote: After sleeping on it, I suppose it does not make a huge difference. Go ahead and make the change at your convenience. Thank you. Will do. Just waiting on confirmation of the firewall issue for current systemd. I have an outstanding commit that is a bit larger than I'd like to stash. --DJ -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 11/18/2018 01:12 PM, Xi Ruoyao via blfs-dev wrote: On 2018-11-18 01:41 -0600, Bruce Dubbs via blfs-dev wrote: I'm not sure I agree agree. If I greo the systemd sources for /bin/touch, the only places I see it is in man/systemd-run.xml and test/test-execute/exec-basic.service. The later has a line: ExecStart=touch /tmp/a ; /bin/touch /tmp/b ; touch /tmp/c So if we just remove the /bin/ from that service file, it should be OK. I believe this `/bin/touch` is intended to test a command with absolute path. So I changed it to `/bin/sh -c "touch /tmp/b"' and gived them a pull request (#10829). Excellent. Thank you! --DJ -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 2018-11-18 01:41 -0600, Bruce Dubbs via blfs-dev wrote: > I'm not sure I agree agree. If I greo the systemd sources for > /bin/touch, the only places I see it is in man/systemd-run.xml and > test/test-execute/exec-basic.service. The later has a line: > > ExecStart=touch /tmp/a ; /bin/touch /tmp/b ; touch /tmp/c > > So if we just remove the /bin/ from that service file, it should be OK. I believe this `/bin/touch` is intended to test a command with absolute path. So I changed it to `/bin/sh -c "touch /tmp/b"' and gived them a pull request (#10829). -- Xi Ruoyao School of Aerospace Science and Technology, Xidian University -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 11/18/2018 11:49 AM, DJ Lucas via blfs-dev wrote: On November 18, 2018 1:41:07 AM CST, Bruce Dubbs via blfs-dev wrote: On 11/17/2018 11:51 PM, DJ Lucas via blfs-dev wrote: The only mention of touch in rc is if [ "$runlevel" == "6" -a -n "${FASTBOOT}" ]; then touch /fastboot fi So that uses the PATH and is only used when rebooting so /usr will be available. Network mounted /usr will not be available at this time. We do use /bin/head and /bib/sleep in init-functions, but not tail or touch. We also have $PATH nice in init-functions, but the function that uses that [start_daemon()] is not called before /usr is mounted. Network mounted /usr is the only argument here. See below. /usr/bin/touch should be moved as well for SysV (and all four tucked away in the earlier command block for FHS compliance with the extra command block and text removed) and init-functions and rc should probably have explicit paths supplied to be absolutely correct. rc starts with: export PATH="/bin:/usr/bin:/sbin:/usr/sbin" If anything, we should be able to remove /bin from the (single) invocation of head. Ok, I suppose I can go that direction as well. I'd rather not be dependent on PATH, but I agree that it's cleaner overall and my preferences should take a back seat to consistency. I rarely use the scripts anymore, though at some point I plan to again. You forget that despite being forced to use systemd for the systems that I want (i.e.: Gnome), I'm not necessarily a fan. I, however, don't particularly like FUD that often gets thrown at it either, so I argue those points as well. It's mostly functional. There are still seemingly better methods to get all of the new functionality IMO, but I've yet to explore them. AFAIK, none of this applies to systemd. Half of what is in /etc/systemd probably belongs in /var or /lib. :-) FHS is a lost cause there. I'm arguing this entirely for the SysV book. It just happened to be an issue in systemd that brought to light an error that *I* missed many years ago. FYI /bin/sleep is used in killproc(), /bin/head is used in pidofproc(), /bin/touch is used in the rc script to set fastboot, and /bin/nice is used in start_daemon(). See ny comments above. That still doesn't fix the broken systemd test, but it works around it in LFS because the SysV book needs touch to be where systemd happens to expect it to be. I'm not sure I agree agree. If I greo the systemd sources for /bin/touch, the only places I see it is in man/systemd-run.xml and test/test-execute/exec-basic.service. The later has a line: ExecStart=touch /tmp/a ; /bin/touch /tmp/b ; touch /tmp/c So if we just remove the /bin/ from that service file, it should be OK. To be honest, though, I haven't built a network mounted /usr in many years, or even NFS in some time for that matter. You do raise an issue here about a network mounted /usr. I have not tested that. To be complete we would need to test that, but from a practical point of view, do we really need to do that? No. We do not. It's just an attempt to be exceedingly exact that drives that train of thought. However, that is the very reason that I argue that touch should be added to the list. It's always been about teaching. To top it off, it's a mistake on my part years ago that is driving this convo and my annoying insistence. :-) It always should have been there and I missed it. After sleeping on it, I suppose it does not make a huge difference. Go ahead and make the change at your convenience. -- Bruce -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On November 18, 2018 1:41:07 AM CST, Bruce Dubbs via blfs-dev wrote: >On 11/17/2018 11:51 PM, DJ Lucas via blfs-dev wrote: > >The only mention of touch in rc is > >if [ "$runlevel" == "6" -a -n "${FASTBOOT}" ]; then >touch /fastboot >fi > >So that uses the PATH and is only used when rebooting so /usr will be >available. Network mounted /usr will not be available at this time. >We do use /bin/head and /bib/sleep in init-functions, but not tail or >touch. > >We also have $PATH nice in init-functions, but the function that uses >that [start_daemon()] is not called before /usr is mounted. > Network mounted /usr is the only argument here. See below. >> /usr/bin/touch should be >moved >> as well for SysV (and all four tucked away in the earlier command >block >> for FHS compliance with the extra command block and text removed) and > >> init-functions and rc should probably have explicit paths supplied to >be >> absolutely correct. > >rc starts with: > >export PATH="/bin:/usr/bin:/sbin:/usr/sbin" > >If anything, we should be able to remove /bin from the (single) >invocation of head. Ok, I suppose I can go that direction as well. I'd rather not be dependent on PATH, but I agree that it's cleaner overall and my preferences should take a back seat to consistency. I rarely use the scripts anymore, though at some point I plan to again. You forget that despite being forced to use systemd for the systems that I want (i.e.: Gnome), I'm not necessarily a fan. I, however, don't particularly like FUD that often gets thrown at it either, so I argue those points as well. It's mostly functional. There are still seemingly better methods to get all of the new functionality IMO, but I've yet to explore them. AFAIK, none of this applies to systemd. Half of what is in /etc/systemd probably belongs in /var or /lib. :-) FHS is a lost cause there. I'm arguing this entirely for the SysV book. It just happened to be an issue in systemd that brought to light an error that *I* missed many years ago. > >FYI /bin/sleep is used in killproc(), /bin/head is >> used in pidofproc(), /bin/touch is used in the rc script to set >> fastboot, and /bin/nice is used in start_daemon(). > >See ny comments above. > >> That still doesn't fix the broken systemd test, but it works around >it >> in LFS because the SysV book needs touch to be where systemd happens >to >> expect it to be. > >I'm not sure I agree agree. If I greo the systemd sources for >/bin/touch, the only places I see it is in man/systemd-run.xml and >test/test-execute/exec-basic.service. The later has a line: > >ExecStart=touch /tmp/a ; /bin/touch /tmp/b ; touch /tmp/c > >So if we just remove the /bin/ from that service file, it should be OK. > >> To be honest, though, I haven't built a > >> network mounted /usr in many years, or even NFS in some time for that > >> matter. > >You do raise an issue here about a network mounted /usr. I have not >tested that. To be complete we would need to test that, but from a >practical point of view, do we really need to do that? > No. We do not. It's just an attempt to be exceedingly exact that drives that train of thought. However, that is the very reason that I argue that touch should be added to the list. It's always been about teaching. To top it off, it's a mistake on my part years ago that is driving this convo and my annoying insistence. :-) It always should have been there and I missed it. --DJ -- Sent from my Android device with K-9 Mail. Please excuse my brevity. -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 11/17/2018 11:51 PM, DJ Lucas via blfs-dev wrote: On 11/17/2018 11:00 PM, Bruce Dubbs via blfs-dev wrote: On 11/17/2018 08:34 PM, DJ Lucas via blfs-dev wrote: Sorry for multiple messages, moving to LFS-Dev. All of the ones that we have separate should be moved into the section above. /bin/sleep is used in init-functions (as well as /bin/head and /bin/nice). As to touch, I'm kind of indifferent (but see below). We've done it before, but it would be a loaner. We do use the touch builtin in rc, and could can change that to /bin/touch and just sidestep the issue completely and lump it in with the others. Thoughts? The only files that need to be moved to support the scripts are those in S00mountvirtfs S08localnet S20swap S40mountfs S05modules S10udev S30checkfs Nope. My assessment was almost correct. You forgot init-functions and the rc script that ties them all together where all four of these are required. The only mention of touch in rc is if [ "$runlevel" == "6" -a -n "${FASTBOOT}" ]; then touch /fastboot fi So that uses the PATH and is only used when rebooting so /usr will be available. We do use /bin/head and /bib/sleep in init-functions, but not tail or touch. We also have $PATH nice in init-functions, but the function that uses that [start_daemon()] is not called before /usr is mounted. /bin/head is used explicitly, but the others use PATH. Bash does not provide a nice built-in (nor head, sleep, or touch built-ins). I moved the binaries out of the way and disabled hashing to test (see below). I could have sworn that bash did provide nice, but turns out it only sets nice level via command or job. /usr/bin/touch should be moved as well for SysV (and all four tucked away in the earlier command block for FHS compliance with the extra command block and text removed) and init-functions and rc should probably have explicit paths supplied to be absolutely correct. rc starts with: export PATH="/bin:/usr/bin:/sbin:/usr/sbin" If anything, we should be able to remove /bin from the (single) invocation of head. FYI /bin/sleep is used in killproc(), /bin/head is used in pidofproc(), /bin/touch is used in the rc script to set fastboot, and /bin/nice is used in start_daemon(). See ny comments above. That still doesn't fix the broken systemd test, but it works around it in LFS because the SysV book needs touch to be where systemd happens to expect it to be. I'm not sure I agree agree. If I greo the systemd sources for /bin/touch, the only places I see it is in man/systemd-run.xml and test/test-execute/exec-basic.service. The later has a line: ExecStart=touch /tmp/a ; /bin/touch /tmp/b ; touch /tmp/c So if we just remove the /bin/ from that service file, it should be OK. After those, /usr is mounted (or should be). I've tested using a separate /usr partition and have not run into any issues. Anything that systemd wants and is not available should be fixed in systemd. IIRC, systemd doesn't even support a separate /usr partition so specifying /usr/bin should always work when using systemd. It didn't some years ago, but we have -Dsplit-usr=true. Most of the distros do have a merged /usr, so it doesn't get much testing, but it has remained mostly compatible so far. /lib/systemd/system vs /usr/lib/systemd/system was a sore spot for a short time, but was bent to be compliant. There was also was some issue for udev as well at one time, but, if memory serves, this was corrected in evdev and eventually made its way back to systemd. To be honest, though, I haven't built a network mounted /usr in many years, or even NFS in some time for that matter. You do raise an issue here about a network mounted /usr. I have not tested that. To be complete we would need to test that, but from a practical point of view, do we really need to do that? -- Bruce -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 11/17/2018 11:00 PM, Bruce Dubbs via blfs-dev wrote: On 11/17/2018 08:34 PM, DJ Lucas via blfs-dev wrote: Sorry for multiple messages, moving to LFS-Dev. All of the ones that we have separate should be moved into the section above. /bin/sleep is used in init-functions (as well as /bin/head and /bin/nice). As to touch, I'm kind of indifferent (but see below). We've done it before, but it would be a loaner. We do use the touch builtin in rc, and could can change that to /bin/touch and just sidestep the issue completely and lump it in with the others. Thoughts? The only files that need to be moved to support the scripts are those in S00mountvirtfs S08localnet S20swap S40mountfs S05modules S10udev S30checkfs Nope. My assessment was almost correct. You forgot init-functions and the rc script that ties them all together where all four of these are required. /bin/head is used explicitly, but the others use PATH. Bash does not provide a nice built-in (nor head, sleep, or touch built-ins). I moved the binaries out of the way and disabled hashing to test (see below). I could have sworn that bash did provide nice, but turns out it only sets nice level via command or job. /usr/bin/touch should be moved as well for SysV (and all four tucked away in the earlier command block for FHS compliance with the extra command block and text removed) and init-functions and rc should probably have explicit paths supplied to be absolutely correct. FYI /bin/sleep is used in killproc(), /bin/head is used in pidofproc(), /bin/touch is used in the rc script to set fastboot, and /bin/nice is used in start_daemon(). That still doesn't fix the broken systemd test, but it works around it in LFS because the SysV book needs touch to be where systemd happens to expect it to be. After those, /usr is mounted (or should be). I've tested using a separate /usr partition and have not run into any issues. Anything that systemd wants and is not available should be fixed in systemd. IIRC, systemd doesn't even support a separate /usr partition so specifying /usr/bin should always work when using systemd. It didn't some years ago, but we have -Dsplit-usr=true. Most of the distros do have a merged /usr, so it doesn't get much testing, but it has remained mostly compatible so far. /lib/systemd/system vs /usr/lib/systemd/system was a sore spot for a short time, but was bent to be compliant. There was also was some issue for udev as well at one time, but, if memory serves, this was corrected in evdev and eventually made its way back to systemd. To be honest, though, I haven't built a network mounted /usr in many years, or even NFS in some time for that matter. dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ set +h dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /usr/bin/touch{,-bak} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ touch blah -bash: touch: command not found dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /usr/bin/touch{-bak,} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /bin/head{,-bak} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ head blah -bash: head: command not found dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /bin/head{-bak,} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /bin/sleep{,-bak} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sleep 1 -bash: sleep: command not found dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /bin/sleep{-bak,} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /bin/nice{,-bak} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ nice --help -bash: nice: command not found dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ sudo mv /bin/nice{-bak,} dj [ ~/LFS/LFS/trunk/BOOK/bootscripts ]$ --DJ -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 11/17/2018 08:34 PM, DJ Lucas via blfs-dev wrote: On 11/17/2018 04:56 PM, Xi Ruoyao via lfs-dev wrote: systemd-239 test suite fails in BLFS: exec-basic.service: Executing: /bin/touch /tmp/b exec-basic.service: Failed to execute command: No such file or directory We can list `touch` as "a Coreutils programs expected by BLFS packages to be in /bin", and move it to /bin in Sect. 6.54 (along with `head`, `sleep`, and `nice`), or, mention this issue in BLFS. Sorry for multiple messages, moving to LFS-Dev. All of the ones that we have separate should be moved into the section above. /bin/sleep is used in init-functions (as well as /bin/head and /bin/nice). As to touch, I'm kind of indifferent (but see below). We've done it before, but it would be a loaner. We do use the touch builtin in rc, and could can change that to /bin/touch and just sidestep the issue completely and lump it in with the others. Thoughts? The only files that need to be moved to support the scripts are those in S00mountvirtfs S08localnet S20swap S40mountfs S05modules S10udev S30checkfs After those, /usr is mounted (or should be). I've tested using a separate /usr partition and have not run into any issues. Anything that systemd wants and is not available should be fixed in systemd. IIRC, systemd doesn't even support a separate /usr partition so specifying /usr/bin should always work when using systemd. -- Bruce -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
Re: [blfs-dev] [lfs-dev] systemd-239 testsuite assumes "/bin/touch"
On 11/17/2018 04:56 PM, Xi Ruoyao via lfs-dev wrote: systemd-239 test suite fails in BLFS: exec-basic.service: Executing: /bin/touch /tmp/b exec-basic.service: Failed to execute command: No such file or directory We can list `touch` as "a Coreutils programs expected by BLFS packages to be in /bin", and move it to /bin in Sect. 6.54 (along with `head`, `sleep`, and `nice`), or, mention this issue in BLFS. Sorry for multiple messages, moving to LFS-Dev. All of the ones that we have separate should be moved into the section above. /bin/sleep is used in init-functions (as well as /bin/head and /bin/nice). As to touch, I'm kind of indifferent (but see below). We've done it before, but it would be a loaner. We do use the touch builtin in rc, and could can change that to /bin/touch and just sidestep the issue completely and lump it in with the others. Thoughts? --DJ -- http://lists.linuxfromscratch.org/listinfo/blfs-dev FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page