Did you remember to mkfs.ext4 (or whatever filesystem you wanted) on
/dev/mapper/ubuntu-vg/home ?  If the last thing you did was simply to
create the lv, then it's just blank; there's no filesystem to mount.

On Tue, Dec 12, 2023 at 2:43 PM Howard White <[email protected]> wrote:
>
> Tilghman (and everyone else):
>
> I'm going to step through some of this and maybe someone may point out
> the gaps in my logic.
>
> (to prove that the lv exists)
> root@sass60:/# lvdisplay
>    --- Logical volume ---
>    LV Path                /dev/ubuntu-vg/ubuntu-lv
>    LV Name                ubuntu-lv
>    VG Name                ubuntu-vg
>    LV UUID                sXSZ05-lDLW-5reh-ujb1-Jz92-Rmzk-9xxMrK
>    LV Write Access        read/write
>    LV Creation host, time ubuntu-server, 2023-12-12 14:02:53 +0000
>    LV Status              available
>    # open                 1
>    LV Size                100.00 GiB
>    Current LE             25600
>    Segments               1
>    Allocation             inherit
>    Read ahead sectors     auto
>    - currently set to     256
>    Block device           253:0
>
>    --- Logical volume ---
>    LV Path                /dev/ubuntu-vg/home
>    LV Name                home
>    VG Name                ubuntu-vg
>    LV UUID                CvL3Hy-fSo8-ME2W-ajlZ-3ucf-2Qyw-b6Zvc4
>    LV Write Access        read/write
>    LV Creation host, time sass60, 2023-12-12 17:51:02 +0000
>    LV Status              available
>    # open                 0
>    LV Size                40.00 GiB
>    Current LE             10240
>    Segments               1
>    Allocation             inherit
>    Read ahead sectors     auto
>    - currently set to     256
>    Block device           253:1
>
>    --- Logical volume ---
>    LV Path                /dev/ubuntu-vg/var
>    LV Name                var
>    VG Name                ubuntu-vg
>    LV UUID                0i3a0G-ulkw-Ve22-04yj-ITeP-kHY3-f1eY2i
>    LV Write Access        read/write
>    LV Creation host, time sass60, 2023-12-12 17:55:53 +0000
>    LV Status              available
>    # open                 0
>    LV Size                40.00 GiB
>    Current LE             10240
>    Segments               1
>    Allocation             inherit
>    Read ahead sectors     auto
>    - currently set to     256
>    Block device           253:2
>
> Get the blkid of the original / partition:
> root@sass60:/# blkid /dev/ubuntu-vg/ubuntu-lv
> /dev/ubuntu-vg/ubuntu-lv: UUID="c2b8265f-b025-41ff-a216-0e48c344a121"
> BLOCK_SIZE="4096" TYPE="ext4"
>
> Use the same syntax against the home lv:
> root@sass60:/# blkid /dev/ubuntu-vg/home
> {nothing}
>
> Attempt to mount /dev/ubuntu-vg/home thinking that if it gets mounted,
> maybe it'll get a UUID...
>
> root@sass60:/# pwd
> /
> root@sass60:/# ls
> bin  boot  dev  etc  home  lib  lib32  lib64  libx32  lost+found  media
> mnt  opt  orighome  proc  root  run  sbin  snap  srv  swap.img  sys  tmp
>   usr  var
> root@sass60:/# mkdir -pv dumbshit
> mkdir: created directory 'dumbshit'
> root@sass60:/# mount -t ext4 /dev/mapper/ubuntu-vg/home /dumbshit
> mount: /dumbshit: special device /dev/mapper/ubuntu-vg/home does not exist.
> root@sass60:/# mount -t ext4 /dev/ubuntu-vg/home /dumbshit
> mount: /dumbshit: wrong fs type, bad option, bad superblock on
> /dev/mapper/ubuntu--vg-home, missing codepage or helper program, or
> other error.
>
> _WTF??_
>
> Howard
>
> On 12/12/23 13:54, Tilghman Lesher wrote:
> > I think this is the answer you're looking for:
> >
> > https://askubuntu.com/questions/900309/blkid-cant-find-lvms-uuid
> >
> > For the sake of the archive, in case the link goes stale, the problem
> > is that there are separate block IDs for the logical volume versus the
> > filesystem on the logical volume, and you want to use the block ID for
> > the filesystem to mount it, not the block ID for the logical volume.
> >
> > On Tue, Dec 12, 2023 at 1:40 PM Howard White <[email protected]> wrote:
> >>
> >> My google-foo is in another dimension.  I am creating a new bare-metal
> >> server with Ubuntu 22.04 and LVM.  The initial build uses the installer
> >> defaults which results in a base system with 100GB / directory.  This is
> >> "fine" and it runs.
> >>
> >> Used lvcreate for two new LVM logical items: home and var.  Doing this
> >> one step at a time.  Renamed (mv) /home to /orighome.  Want to modify
> >> /etc/fstab to point to /dev/mapper/ubuntu-vg/home.
> >>
> >> If I run lvdisplay, there is an LV-UUID reported but attempting to use
> >> that value in a mount command or in /etc/fstab results in "nocando"
> >> error.  How to obtain a blkid for an LVM member??
> >>
> >> This is what happens when one uses such commands ever other three years.
> >>
> >> Howard
> >>
> >> --
> >> --
> >> You received this message because you are subscribed to the Google Groups 
> >> "NLUG" group.
> >> To post to this group, send email to [email protected]
> >> To unsubscribe from this group, send email to 
> >> [email protected]
> >> For more options, visit this group at 
> >> http://groups.google.com/group/nlug-talk?hl=en
> >>
> >> ---
> >> You received this message because you are subscribed to the Google Groups 
> >> "NLUG" group.
> >> To unsubscribe from this group and stop receiving emails from it, send an 
> >> email to [email protected].
> >> To view this discussion on the web visit 
> >> https://groups.google.com/d/msgid/nlug-talk/8ffc2fcf-6d59-4d7a-97b3-26b81417b6db%40vcch.com.
> >
> >
> >
>
> --
> --
> You received this message because you are subscribed to the Google Groups 
> "NLUG" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to 
> [email protected]
> For more options, visit this group at 
> http://groups.google.com/group/nlug-talk?hl=en
>
> ---
> You received this message because you are subscribed to the Google Groups 
> "NLUG" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/nlug-talk/8c582224-a809-42c4-8bf1-83506a1df7b2%40vcch.com.



-- 
Tilghman

-- 
-- 
You received this message because you are subscribed to the Google Groups 
"NLUG" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nlug-talk?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"NLUG" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/nlug-talk/CAHPkZcX6pf-2bpFJLwq8DbihcCC7r5oZ9Fj4TH%3DYfnZuwbaX4w%40mail.gmail.com.

Reply via email to