Discussion:
[Sisuite-devel] mount order in _write_out_mkfs_commands
Daniel Goering
15 years ago
Permalink
Hi,

I have a question about _write_out_mkfs_commands in
/usr/lib/systemimager/perl/SystemImager/Server.pm
Currently this function does not obey a certain order in creating and
mounting the filesystems. This leads to problems e.g. if /boot is
mounted before /, as then the bootloader and the kernel will be put on
the root device instead of the boot device.
Would it be reasonable to check all mountpoints for dependencies and
adjust the order correspondingly [so mount / before /mnt before
/mnt/data before /mnt/data/scratch], or should everyone who needs this
just perform some cut and paste in the master script?

If this is too hard to fix [unfortunately my Perl is not that good...] I
think it should at least be mentioned in the Troubleshooting section of
the web page [http://wiki.systemimager.org/index.php/Troubleshooting],
or may be even after every generation of a master script ["Please check
the mount order in ###.master" or something similar]

I am using v4.1.6 of SystemImager

Cheers
Daniel
Daniel Goering
15 years ago
Permalink
Hi again,

the mount order "_write_out_mkfs_commands" uses seems to be the order in
which the partitions are listed in /etc/fstab. May be there should be a
hint in the manual and on the troubleshooting page that the order of
lines in /etc/fstab matters and that one has to put the root filesystem
on top.

Cheers
Daniel
...
Bernard Li
15 years ago
Permalink
Post by Daniel Goering
the mount order "_write_out_mkfs_commands" uses seems to be the order in
which the partitions are listed in /etc/fstab. May be there should be a
hint in the manual and on the troubleshooting page that the order of
lines in /etc/fstab matters and that one has to put the root filesystem
on top.
We could just do a simple sort to make sure that "/" shows up first --
least impact to the users...

What to do you think?

Cheers,

Bernard
Daniel Goering
15 years ago
Permalink
Hi,

I think we should not just put / on top, but sort the mount points by
the number of slashes "/" they contain [least slash count first :-) ].
This way all dependencies should automatically be respected.

Cheers
Daniel
Post by Bernard Li
Post by Daniel Goering
the mount order "_write_out_mkfs_commands" uses seems to be the order in
which the partitions are listed in /etc/fstab. May be there should be a
hint in the manual and on the troubleshooting page that the order of
lines in /etc/fstab matters and that one has to put the root filesystem
on top.
We could just do a simple sort to make sure that "/" shows up first --
least impact to the users...
What to do you think?
Cheers,
Bernard
Loading...