Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I cannot, for love or money, build a filesystem on my second hard disk. Here is the output from fdisk -l:
# fdisk -l
===================================================================
Disk /dev/sda: 40.0 GB, 40020664320 bytes
255 heads, 63 sectors/track, 4865 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00029c25
Device Boot Start End Blocks Id System
/dev/sda1 * 1 25 200781 83 Linux
/dev/sda2 26 4865 38877300 8e Linux LVM
Disk /dev/sdb: 300.0 GB, 300069052416 bytes
255 heads, 63 sectors/track, 36481 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xffffffff
Disk /dev/sdb doesn't contain a valid partition table
Disk /dev/dm-0: 338.6 GB, 338698436608 bytes
255 heads, 63 sectors/track, 41177 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 1073 MB, 1073741824 bytes
255 heads, 63 sectors/track, 130 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x30307800
Disk /dev/dm-1 doesn't contain a valid partition table
===================================================================
When I run mkfs.ext3 /dev/sdb1
mke2fs 1.40.4 (31-Dec-2007)
/dev/sdb1 is apparently in use by the system; will not make a filesystem here!
I have tried using gparted, every variant of the fdisk command I can think of, and still there is some process that has a lock on /dev/sdb and I cannot build a filesystem on it.
lsof /dev/sdb1 returns nothing.
I have turned of the automounter, and looked through the process table and there is nothing apparently running that is accessing it.
I have even tried to vgreduce the disk from the volume group.
I've tried pvcreate, pvmove, and pvremove.
===================================================================
Here is the output of vgdisplay -v VolGroup00
Using volume group(s) on command line
Finding volume group "VolGroup00"
--- Volume group ---
VG Name VolGroup00
System ID
Format lvm2
Metadata Areas 2
Metadata Sequence No 3
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 2
Open LV 2
Max PV 0
Cur PV 2
Act PV 2
VG Size 316.50 GB
PE Size 32.00 MB
Total PE 10128
Alloc PE / Size 10126 / 316.44 GB
Free PE / Size 2 / 64.00 MB
VG UUID pY4sUu-FYUH-cvGk-mVd1-ef2g-D1SN-AoaT6Z
--- Logical volume ---
LV Name /dev/VolGroup00/LogVol00
VG Name VolGroup00
LV UUID AwEgSy-baAD-ixnq-wP23-Cm1D-0jJk-QAv6Ev
LV Write Access read/write
LV Status available
# open 1
LV Size 315.44 GB
Current LE 10094
Segments 2
Allocation inherit
Read ahead sectors 0
Block device 253:0
--- Logical volume ---
LV Name /dev/VolGroup00/LogVol01
VG Name VolGroup00
LV UUID 3rqvUF-hXZd-0ssk-lS6Y-6AEP-Cmy8-E6Mjv2
LV Write Access read/write
LV Status available
# open 1
LV Size 1.00 GB
Current LE 32
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:1
--- Physical volumes ---
PV Name /dev/sdb1
PV UUID tqgfyY-eq1Y-LZyg-Wx5n-uSPL-L8bR-GGqk00
PV Status allocatable
Total PE / Free PE 8942 / 0
PV Name /dev/sda2
PV UUID 2F1dIW-8B07-GDjz-yxAB-gl0E-q0Mf-YPWCoC
PV Status allocatable
Total PE / Free PE 1186 / 2
===================================================================
So /dev/sdb1 is part of the volume group, but I cannot vgreduce it out.
The error is " Physical volume "/dev/sdb1" still in use"
So somewhere, some process has a lock on this disk. And nothing I am doing can override the lock. Can anyone advise me as to how to unlock the damn thing? I guess I can boot off the rescue disk. Is that the only recourse left?
As I said: I used fdisk, gparted and every disk partitioning tool available. The disk was held locked by the volume group and nothing I could do would unlock it. Evendently, Linux LVM is designed to seize disks and never allow them to be used for anything productive.
I ended up flattening the box...twice. The second time, I disconnected the IDE cable from the second hard disk while installing the OS and overwriting everything. After the 2 hour wait for all the patches to install, I rebooted it again from the Rescue CD. I then partitioned the disk, made an ext3 filesystem on it, then edited /etc/fstab. After rebooting again, the drive mounted as I wanted it to and everything was groovy.
Installing FC8 was the biggest pain-in-the-nether regions I've had the displeasure of in a long, long time. Maybe Win95 compares. I spent the first week just trying to get jigdo to work on my WinXP system, so I could get the ISO's to download. I eventually gave up and was able to make jigdo work on my laptop. I then tried to burn the CD's with the burner in my laptop....HUGE mistake. I probably burned 20 disks trying to make disks 1, 2, and 3. The installation would start, then hang while installing some package (a different package every time). I eventually network-shared the ISO's over to my desktop system, and used the burner there. The first several times I burned the CD's at the rated speed of 4x, and even with read-after-write confirmation, could not get a set of CD's to load. Eventually, I slowed it down to 1x speed, with read-after-write confirmation. Finally I was able to create 3 disks that would load the OS.
Then this disk problem occurred because I accepted the defaults. The LVM would not permit me to create logical volumes. I could not remove the disk, I could do nothing with the 2nd disk.
However, now that the damn thing is up and running, I've already started to configure the applications I wanted to. Streamripper is very cool. My ultimate goal is to convert it into a MIDI sound module.
My estimate is that I have spent over 100 hours of my time installing FC8. I am NOT a happy camper.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.