LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-27-2015, 10:39 AM   #16
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled

Ok, sounds better because I doubt this system can boot from USB and I have trouble finding a ready-made iso from any fedora page.

Some comments on these instructions. I cannot connect a SATA disk to IDE socket and vice versa. I can surely check if this small IDE disk is connected to the first IDE or not.

Why is using Live CD so important? I can try mounting that SATA disk any time, but I don't think it mounts. I would just like to get the possible data out of that disk.
 
Old 04-27-2015, 10:47 AM   #17
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Live CD is so important here because you mentioned that when you have new hdd connected to the system your system won't boot. Using liveCD you can boot the system and can see both hdd at the sametime. If you are saying that new hdd works fine without being part of LVM, though you haven't mentioned if it worked after you removed it from LVM only thing we are are aware of that after initial setup it didn't work post reboot.

If new hdd works fine without being part of LVM then boot without liveCD and try to mount the partition from new hdd onto an empty directory.
 
Old 04-27-2015, 11:04 AM   #18
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
After removing from LVM, trying to mount the SATA disk has failed. Otherwise I wouldn't have any problem.
So, mounting fails giving this output:
mount: wrong fs type, bad option, bad superblock on /dev/sda,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
 
Old 04-27-2015, 11:23 AM   #19
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Seems I really didn't say it clearly in the first post. This bigger SATA disk won't mount. I tested with a smaller SATA disk that the successful boot depends on not having any SATA disks in LVM configuration. Separately I can mount that smaller SATA disk. And I suspect that the bigger works the same. The smaller disk was also not mountable after being removed from LVM. But there was nothing valuable inside, so I reformatted it and made it mount traditionally.

But I was left with the bigger disk arguably having something inside, but it wouldn't mount nor anyway reveal it has something inside.
 
Old 04-28-2015, 12:32 PM   #20
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
BTW, is there a way to add a disk to LVM without formatting it first?

In my issue I wonder, why did LVM make the disk unmountable when removing it from the configuration? Now I wonder if it was possible to add it to the configuration without formatting it...
 
Old 04-28-2015, 08:56 PM   #21
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
I haven't tried that and I doubt it will be possible because when you add a partition or a whole disk to VG it is considered as unallocated space. The idea of LVM is to provide you with flexibility of expanding your existing partition within that VG. If you are adding an existing partition or partition that already contains data which I doubt it will allow, basically it will wipe all the stuff before adding and then add the available LEs to VG.

Here are the simple steps on how we create LV:

1. Create pv using pvcreate.
2. Create vg using vgcreate and then add the partition to it.
3. Create lv using lvcreate within the vg.
4. Format lv using mkfs.

According to your query what you are looking for is when you do vgextend pointing to a partition which contains data it should allow you to mount that partition or atleast allow you to mount it when you remove it from lv. As per my understanding when you add a partition to VG it is added as unallocated space and when you remove it from VG the partition still considered as unallocated space.
 
Old 04-28-2015, 10:33 PM   #22
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,187

Rep: Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129
You can't mount a LVM pv - you need to activate it first, then see what vg(s), lv(s) it contains. If any, the lv(s) can then be mounted.
Code:
vgscan
vgchange -a y
pvs
vgs
lvs
That should give you an idea of what's around. Then you can use the display commands for detail. Then mount as normal once you know the lv name(s).
 
Old 04-29-2015, 12:09 AM   #23
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Thanks guys!
When doing experiments with the small SATA disk, I tried to find a way to prevent the overwriting of the disk, but I was forced to follow the path Initialize -> Add physical volume -> Add logical volume (or something like that) when using the graphical interface.
Does this Initialize or Activate phase already overwrite the disk somehow or is this safe for testing?
 
Old 04-29-2015, 01:24 AM   #24
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,187

Rep: Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129Reputation: 4129
The activate in this sense (-a in the vgchange) is merely telling LVM to include ("activate") any new/unknown vgs it finds so you can see them in the LVM commands. Nothing is changed on the disk.
This is how you bring preformatted LVM entities into your system - no other way that I know of.
 
Old 04-29-2015, 01:43 AM   #25
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Ok, thank you! I will try those command line versions this time.
 
Old 04-29-2015, 11:24 AM   #26
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
Hi,
I tried those command line commands and indeed, terms activation and initialization are really very different.
Activation seems to activate visible volume groups with visible logical volumes, but does not affect removed logical or physical volumes.
Initialization is on the other hand a function provided by the graphical user interface and it remains unknown to me, if it overwrites the disk it tries to initialize. I assume it does as T3RM1NVT0R pointed out.

All in all, it seems I am in a deadlock. I cannot get anything out of that removed SATA disk.
 
Old 04-29-2015, 11:44 AM   #27
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
You could give a try with gparted live: http://gparted.org/livecd.php

See if you are able to get anything out of that partition. As of now you are not able to get anything out of that partition, so I thought gparted worth a try. Check out both command lines and graphical utilities available with it.
 
Old 04-29-2015, 12:12 PM   #28
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
All right, thanks! I am pretty desperate, but let's see how it works.
 
Old 04-29-2015, 12:38 PM   #29
vpp
Member
 
Registered: Apr 2015
Posts: 62

Original Poster
Rep: Reputation: Disabled
How should use of this live CD differ from using Gparted available in this system?

Actually I tried the CD version, but it wouldn't even start. Probably my CD burner cannot burn reliably any more.
 
Old 04-29-2015, 12:48 PM   #30
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Quote:
Originally Posted by vpp View Post
How should use of this live CD differ from using Gparted available in this system?

Actually I tried the CD version, but it wouldn't even start. Probably my CD burner cannot burn reliably any more.
gparted utility within the OS can only perform operation on the filesystem which it can see / detect and which are of Linux type (recognized by Linux). On the other hand gparted live is bootable version of gparted and can perform operations on hdd as whole, for example you can resize partition even which belongs to Windows.

The reason I suggested to you gparted live because it will boot itself and you will have more control over hdd as it will not be locked by OS.

As you will be playing around with disks it is always good to have backup. Gparted live it pretty easy to use but make sure that you don't touch or modify the existing disk using which you are booting your system.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LVM issue circus78 Linux - Server 5 12-12-2014 01:32 AM
LVM issue call_krushna Linux - Virtualization and Cloud 0 10-30-2012 10:58 AM
LVM issue AndyD236 Linux - General 2 11-24-2009 07:26 AM
LVM Issue bondoq Linux - General 8 05-12-2009 09:35 AM
LVM issue pauloco Linux - Hardware 1 11-14-2006 11:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:21 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration