Opened 13 years ago
Closed 13 years ago
#3088 closed defect (fixed)
6.2.3. Mounting Virtual Kernel File Systems from a LFS 7.1 host system
Reported by: | Wayne Blaszczyk | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.2 |
Component: | Book | Version: | SVN |
Severity: | normal | Keywords: | |
Cc: |
Description
The instruction 'mount -vt tmpfs shm $LFS/dev/shm' in section 6.2.3 does not work if the host system is LFS 7.1.
This is because the mountvirtfs start script creates a symlynk /dev/shm which points to /run/shm.
So the instruction 'mount -vt tmpfs shm $LFS/dev/shm' mounts onto /run/shm rather than /mnt/lfs/dev/shm.
Change History (5)
comment:1 by , 13 years ago
comment:2 by , 13 years ago
Proposed solution in Chapter 6.2:
Change
mount -vt tmpfs shm $LFS/dev/shm
to
if [ ! -h /dev/shm ]; then mount -vt tmpfs shm $LFS/dev/shm; fi
comment:3 by , 13 years ago
By dropping the 'mount -vt tmpfs shm $LFS/dev/shm' command altogether, after entering the chroot environment, the /dev/shm is pointing to a non existent /run/shm. I'm not sure if this will cause any problems down the line. (I'm currently not going through the process of building another LFS environment).
comment:4 by , 13 years ago
Thinking about this some more, I think the following might work:
if [ -h /dev/shm ]; then rm -f $LFS/dev/shm mkdir $LFS/dev/shm fi mount -vt tmpfs shm $LFS/dev/shm
I'll note that my jhalfs build log has:
shm on /run/shm type tmpfs (rw)
which is wrong, but does not affect the build.
comment:5 by , 13 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Recreated $LFS/dev/shm if it is a symbolic link.
Fixed in revision 9860.
If we are doing 'mount -v --bind /dev $LFS/dev' and $LFS/dev/pts already points to /run, we probably do not need to do 'mount -vt tmpfs shm $LFS/dev/shm' at all.
Do things seem to work OK if you just drop the 'mount -vt tmpfs shm $LFS/dev/shm' command?