Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue #5360: Add /usr/bin/env to COPY_EXEC_LIST in initramfs hooks. #6913

Merged
merged 1 commit into from Dec 4, 2017

Conversation

JKDingwall
Copy link
Contributor

Description

5dc1ff2 changed the user space program to mount a zfs snapshot from /bin/sh to /usr/bin/env. If the executable is not present in the initramfs then snapshots cannot be automounted. The commit adds /usr/bin/env to the list of executables included in the initramfs image.

Motivation and Context

With zfs 0.6.4 our system booted without intervention when it copied the root filesystem image from a snapshot to memory. After upgrading to 0.7.1 (ubuntu daily ppa) this was no longer the case until /usr/bin/env was included in the initramfs image.

#5360

How Has This Been Tested?

We use a custom initramfs hook script which has copy_exec /usr/bin/env. This is the equivalent in the master repository which we anticipate adopting in the near future.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (a change to man pages or other documentation)

Checklist:

  • My code follows the ZFS on Linux code style requirements.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • All commit messages are properly formatted and contain Signed-off-by.
  • Change has been approved by a ZFS on Linux member.

…penzfs#5360.

5dc1ff2 changed the user space program to mount a zfs snapshot from /bin/sh to
/usr/bin/env.  If the executable is not present in the initramfs then snapshots cannot be automounted.

Signed-off-by: James Dingwall <james.dingwall@zynstra.com>
Copy link
Contributor

@behlendorf behlendorf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. I can address the commit message style warnings when this is merged.

@codecov
Copy link

codecov bot commented Dec 2, 2017

Codecov Report

Merging #6913 into master will increase coverage by 0.07%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #6913      +/-   ##
==========================================
+ Coverage   75.18%   75.26%   +0.07%     
==========================================
  Files         296      296              
  Lines       95197    95197              
==========================================
+ Hits        71577    71648      +71     
+ Misses      23620    23549      -71
Flag Coverage Δ
#kernel 74.44% <ø> (-0.08%) ⬇️
#user 67.66% <ø> (+0.09%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d467726...d6d33f8. Read the comment docs.

@behlendorf behlendorf merged commit 9717fe0 into openzfs:master Dec 4, 2017
tonyhutter pushed a commit that referenced this pull request Dec 5, 2017
5dc1ff2 changed the user space program to mount a zfs snapshot
from /bin/sh to /usr/bin/env.  If the executable is not present
in the initramfs then snapshots cannot be automounted.

Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Richard Laager <rlaager@wiktel.com>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Signed-off-by: James Dingwall <james.dingwall@zynstra.com>
Closes #5360
Closes #6913
Conflicts:
	contrib/initramfs/hooks/zfs
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Dec 5, 2017
5dc1ff2 changed the user space program to mount a zfs snapshot
from /bin/sh to /usr/bin/env.  If the executable is not present
in the initramfs then snapshots cannot be automounted.

Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Richard Laager <rlaager@wiktel.com>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Signed-off-by: James Dingwall <james.dingwall@zynstra.com>
Closes openzfs#5360
Closes openzfs#6913
Conflicts:
	contrib/initramfs/hooks/zfs
Nasf-Fan pushed a commit to Nasf-Fan/zfs that referenced this pull request Jan 29, 2018
5dc1ff2 changed the user space program to mount a zfs snapshot
from /bin/sh to /usr/bin/env.  If the executable is not present
in the initramfs then snapshots cannot be automounted.

Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Richard Laager <rlaager@wiktel.com>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Signed-off-by: James Dingwall <james.dingwall@zynstra.com>
Closes openzfs#5360
Closes openzfs#6913
Nasf-Fan pushed a commit to Nasf-Fan/zfs that referenced this pull request Feb 13, 2018
5dc1ff2 changed the user space program to mount a zfs snapshot
from /bin/sh to /usr/bin/env.  If the executable is not present
in the initramfs then snapshots cannot be automounted.

Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Richard Laager <rlaager@wiktel.com>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Signed-off-by: James Dingwall <james.dingwall@zynstra.com>
Closes openzfs#5360
Closes openzfs#6913
FransUrbo pushed a commit to FransUrbo/zfs that referenced this pull request Apr 28, 2019
5dc1ff2 changed the user space program to mount a zfs snapshot
from /bin/sh to /usr/bin/env.  If the executable is not present
in the initramfs then snapshots cannot be automounted.

Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Richard Laager <rlaager@wiktel.com>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Signed-off-by: James Dingwall <james.dingwall@zynstra.com>
Closes openzfs#5360 
Closes openzfs#6913
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants