Page 1 of 2 12 LastLast
Results 1 to 10 of 15

Thread: About LVM

  1. #1
    Join Date
    Apr 2006
    Beans
    1,985

    About LVM

    Hi all,

    I newly installed Ubuntu 12.04.1 from ubuntu-12.04.1-desktop-amd64.iso

    Installation went through without problem but without LVM. Ubuntu is now up running.

    I ran following command trying to mount LVM but failed;

    # apt-get install lvm2
    # vgchange -ay
    Code:
    No volume groups found
    Please help.

    Which ISO should I use to install LVM? ubuntu-12.04.1-alternate-amd64.iso ?

    TIA

    B.R.
    satimis

  2. #2
    Join Date
    Nov 2009
    Location
    Mataro, Spain
    Beans
    12,975
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: About LVM

    You can't activate LVM when it doesn't exist.

    Yes, you need to use the alternate cd to configure LVM during installation.
    Darko.
    -----------------------------------------------------------------------
    Ubuntu 14.04 LTS 64bit & Windows 10 Pro 64bit

  3. #3
    Join Date
    Apr 2006
    Beans
    1,985

    Re: About LVM

    Quote Originally Posted by darkod View Post
    You can't activate LVM when it doesn't exist.

    Yes, you need to use the alternate cd to configure LVM during installation.
    Still fail.

    Performed following steps

    1)
    Download "ubuntu-12.04.1-alternate-amd64.iso" and burned it on USB drive/stick

    2)
    Booted up the PC with the said drive/stick. Deleted old partitions and created new partitions with LVM /root. Installation went through without problem

    3)
    Started Ubuntun 12.04 desktop. Ran "sudo apt-get update && sudo apt-get upgrade"

    4)
    On terminal

    $ sudo fdisk -l
    Code:
    Disk /dev/sda: 160.0 GB, 160041885696 bytes
    255 heads, 63 sectors/track, 19457 cylinders, total 312581808 sectors
    Units = sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x000bfde6
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1   *        2048      585727      291840   83  Linux
    /dev/sda2          587774   154882047    77147137    5  Extended
    /dev/sda3       154882048   156835839      976896   82  Linux swap / Solaris
    /dev/sda5          587776   154882047    77147136   83  Linux
    $ sudo apt-get install lvm2

    $ sudo vgchange -a y
    Code:
      No volume groups found
    Pls help. TIA

    B.R.
    satimis
    Last edited by satimis; October 8th, 2012 at 10:32 AM.

  4. #4
    Join Date
    Nov 2009
    Location
    Mataro, Spain
    Beans
    12,975
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: About LVM

    It seems you are missing one of the basic steps, you have no LVM partition on the disk. As you can see from the fdisk results, there are two Linux and one Linux swap partitions. There is no Linux LVM partition.

    Did you read any LVM tutorials first and try to install it or you just came here to ask without bothering to read anything? You haven't done any basic steps.

    When you are doing the partitioning and you create the partition you plan for LVM, when you select it in the Use As option you need to select Physical device for LVM. That will mark it as LVM.

    After that you need to go into the option Configure LVM to configure the volume group and logical volumes.

    And why are you creating many separate partitions, the point of LVM is all LVs to be inside it.

    I don't think you understand how it works and you need to read more, it might not even be suitable for the way you want to use your computer.
    Darko.
    -----------------------------------------------------------------------
    Ubuntu 14.04 LTS 64bit & Windows 10 Pro 64bit

  5. #5
    Join Date
    Apr 2006
    Beans
    1,985

    Re: About LVM

    I followed;
    HowTo: Setup Ubuntu Desktop with LVM Partitions
    https://help.ubuntu.com/community/UbuntuDesktopLVM

    to install Ubuntu. But it didn't start two options of "Try Ubuntu" and "Install Ubuntu"

    Then I continued the installation without manual and came to the result as posted previously. Ubuntu was installed in about half space of the HD leaving the rest space for another Linux OS.

    I made another round installing Ubuntu on the complete space of the HD. Then I was allowed to create LVM.

    $ sudo fdisk -l
    Code:
    Disk /dev/sda: 160.0 GB, 160041885696 bytes
    255 heads, 63 sectors/track, 19457 cylinders, total 312581808 sectors
    Units = sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x000948c6
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1   *        2048      499711      248832   83  Linux
    /dev/sda2          501758   312580095   156039169    5  Extended
    /dev/sda5          501760   312580095   156039168   8e  Linux LVM
    
    Disk /dev/mapper/lvm-root: 70.7 GB, 70678216704 bytes
    255 heads, 63 sectors/track, 8592 cylinders, total 138043392 sectors
    Units = sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x00000000
    
    Disk /dev/mapper/lvm-root doesn't contain a valid partition table
    
    Disk /dev/mapper/lvm-swap_1: 8317 MB, 8317304832 bytes
    255 heads, 63 sectors/track, 1011 cylinders, total 16244736 sectors
    Units = sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x00000000
    
    Disk /dev/mapper/lvm-swap_1 doesn't contain a valid partition table
    But still there is problem on "Disk /dev/mapper/lvm-root doesn't contain a valid partition table"


    > LVM tutorials?

    Whether you meant;
    How To Create LVM Using vgcreate, lvcreate, and lvextend lvm2 Commands
    http://www.thegeekstuff.com/2010/08/...lvm/#more-5125

    Edit:
    I think I have to use "ubuntu-12.04.1-desktop-amd64.iso" NOT "ubuntu-12.04.1-alternate-amd64.iso" The former would start two options of "Try Ubuntu" and "Install Ubuntu"
    Last edited by satimis; October 8th, 2012 at 06:04 PM.

  6. #6
    Join Date
    Nov 2009
    Location
    Mataro, Spain
    Beans
    12,975
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: About LVM

    fdisk can't always read the LVM properly so don't worry it says there is no valid partition table.

    You can use both disks (images), the install procedure is slightly different depending which one you use.

    I think the tutorial you linked is much more complicated, especially since the author creates partitions with fdisk which is not always a good idea.

    The alternate cd supports LVM by default, you don't need the live dekstop and to install the lvm2 package, it already has it. I guess that is confusing you.

    It's up to you what you want to use.
    Darko.
    -----------------------------------------------------------------------
    Ubuntu 14.04 LTS 64bit & Windows 10 Pro 64bit

  7. #7
    Join Date
    Apr 2006
    Beans
    1,985

    Re: About LVM

    Another problem of unknown cause is;

    Root password didn't work after installation. I have to start "recovery" mode and dropped to root shell to run;

    # mount -rw -o remount /
    # passwd root

    I use the same root password through out all OS under testing for years.

    I'm prepared installing Fedora 17 on the same HD making it dual boot. The bitter lesson which I learned before was after running update on Ubuntu Fedora gone. I was NOT the first person encountering this problem. You can find similar thread on Internet.

  8. #8
    Join Date
    Apr 2006
    Beans
    1,985

    Re: About LVM

    Another problem surfaces on installing Fedora 17 as dual boot. There is no spare space.

    see photo attached.

    Neither I can resize Ubuntu with the device provided by the installer.

    I have to follow the steps on;
    Dualboot on lvm with luks
    http://superuser.com/questions/39271...-lvm-with-luks

    Is there an easy way? Otherwise I prefer going back to physical partitioning without LVM

    TIA

    B.R.
    satimis
    Attached Images Attached Images

  9. #9
    Join Date
    Nov 2009
    Location
    Mataro, Spain
    Beans
    12,975
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: About LVM

    You see that Free space in the lvm which is 77GB? Why don't you use that for Fedora?

    Once you have LVM and some unused space in it, you can install other distros that support LVM into it. Forget about the physical partitions, that's why you install LVM.

    And the root username is not used directly any more in ubuntu, so of course what you tried to do failed. The first user created during the installation has root permissions when you use 'sudo' in front of CLI commands, and 'gksu' in front of GUI commands. It will ask you to enter your user password again, and that will confirm the permissions to execute the command as root.
    Darko.
    -----------------------------------------------------------------------
    Ubuntu 14.04 LTS 64bit & Windows 10 Pro 64bit

  10. #10
    Join Date
    Apr 2006
    Beans
    1,985

    Re: About LVM

    Quote Originally Posted by darkod View Post
    You see that Free space in the lvm which is 77GB? Why don't you use that for Fedora?
    Yes, I'm aware. Unfortunately I can't touch it installing Fedora on the fly. If without lvm I can install Fedora on the fly seamlessly. The only way to install Fedora is performing the steps of "Dualboot on lvm with luks" in the thread mentioned on my previous posting.

    And the root username is not used directly any more in ubuntu, so of course what you tried to do failed. The first user created during the installation has root permissions when you use 'sudo' in front of CLI commands, and 'gksu' in front of GUI commands. It will ask you to enter your user password again, and that will confirm the permissions to execute the command as root.
    sudo didn't work complaining "user" NOT on "sudoer". I have to login root to edit that file.

    B.R.
    satimis

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •