On Mon 14 Jan 2019 at 10:20:51 (-0600), Richard Owlett wrote:
> On 01/14/2019 09:22 AM, Thomas Schmitt wrote:
> > [email protected] wrote:
> > > > Assuming there are entries in fstab for each partition, [...]
> > > > for i in /dev/sd<device_letter>*; do mount $i; done
> >
> > Rchard Owlett wrote:
> > > There are not.
> >
> > In the most general case i would have a where-to-mount directory with
> > lots of directories for the various partitions (here 10 drives with
> > 20 partitions each).
>
> But thankfully I don't have to deal with the most general case as I am
> as compulsive about giving all partitions a reasonably unique label as
> Debian is about assigning UUIDs.
"Reasonably unique" doesn't really cut it. You're better off
generating a nonce name for the real mount point like so:
Newmtpt=/media/richard/$(uuidgen)
mkdir -p "$Newmtpt"
and then making a symlink to it using your LABELs. That way, mounting
will always succeed even if creating the link fails (which tells you
to take some action to rectify things).
Cheers,
David.