Opened 3 months ago

Closed 2 months ago

#1742 closed defect (fixed)

Make some checks ensuring $(MOUNT_PT) is actually a mount point

Reported by: Pierre Labastie Owned by: alfs-log@…
Priority: normal Milestone:
Component: jhalfs Version: GIT
Severity: normal Keywords:
Cc:

Description (last modified by Pierre Labastie)

If $(MOUNT_PT) is not a mount point, some tests in the systemd suite fail. This ticket is for discussion of the various checks and possible fixes.

Change History (5)

comment:1 by Pierre Labastie, 3 months ago

Description: modified (diff)

comment:2 by Pierre Labastie, 3 months ago

There have been several messages on alfs-discuss to tell that having lfs in a regular directory is actually a use case. This discussion originated in ticket #1739, where I also expressed the same view. I moved the conversation here because ticket #1739 has a different subject.

As has also been answered in that ticket and in mails, it is possible to mount a directory onto itself, so that having lfs in a regular directory would be possible even if a mount point is enforced.

But now the question is what should we do if $(MOUNT_PT) is not a mount point: just warn and ask the user whether .s.he wants to continue, or stop and tell user to rerun after mounting $(MOUNT_PT)? And at which stage should this be done? in the initial run of jhalfs (before configuration or just after), or when running the Makefile in $(MOUNT_PT)/jhalfs, or...

comment:3 by Pierre Labastie, 3 months ago

I think we could add a target to the Makefile that warns if $(MOUNT_PT) is not a mount point, propose to hit a key to stop make within a given delay, then continues or exits depending on the user reaction. This target would be a prereq of the all target, so that it is displayed each time make is run, but not more. Internally the Makefile runs make some_other_target, which would not display the warning, and if a user runs make some_target_that_is_not_all, then it is not displayed either, but we suppose the user knows what .s.he is doing in this case...

comment:4 by Pierre Labastie, 3 months ago

Pushed a fix into branch plabs/check-mount at 5eadf60. Thanks for testing if it is acceptable for you...

comment:5 by Pierre Labastie, 2 months ago

Resolution: fixed
Status: newclosed

No comments for two weeks... Merged to trunk at db8ed16eb92

Note: See TracTickets for help on using tickets.