Please note the new address for this forum : forum.excito.org. The old address redirects here but I don't know for how long. Thanks !
New user's registration have been closed due to high spamming and low trafic on this forum. Please contact forum admins directly if you need an account. Thanks !

Cannot boot from rescue usb

Got problems with your B2 or B3? Share and get helped!
Cheeseboy
Posts: 789
Joined: 08 Apr 2007, 12:16

Re: Cannot boot from rescue usb

Post by Cheeseboy »

Just a thought:
You know you have to create the directory that is the mount point before mounting anything on it, right?
paulchany
Posts: 123
Joined: 10 Jul 2009, 15:48
Location: Serbia
Contact:

Re: Cannot boot from rescue usb

Post by paulchany »

Cheeseboy wrote:Just a thought:
You know you have to create the directory that is the mount point before mounting anything on it, right?
Yes, of course.

Code: Select all

$ ssh root@Bubba_IP
# cd /
# ls
bin dev etc home lib linuxrc mnt opt proc root sbin sys tmp usr var

Code: Select all

# ls mnt/
disk home usb

Code: Select all

# ls /dev | grep mapper
device-mapper

Code: Select all

# ls /dev/device-mapper 
/dev/device-mapper

So /dev/device-mapper isn't a directory.

Can one give to me an uImage file of the 'Linux bubba 2.6.32.13'?
Best, Pali
RandomUsername
Posts: 904
Joined: 09 Oct 2009, 18:49

Re: Cannot boot from rescue usb

Post by RandomUsername »

Just thinking, you may need to make the lvm active. Can't remember the command now and not near my B3. Try Google.
paulchany
Posts: 123
Joined: 10 Jul 2009, 15:48
Location: Serbia
Contact:

Re: Cannot boot from rescue usb

Post by paulchany »

Now I'm trying to do this:
Initializing a single partition

If you have already a partition, before you can initialize it, the partition type must be changed. You can do it with fdisk, parted, cfdisk, etc. Cfdisk is really simple and is included in the most distributions.

The partition type must be set to

8E

This creates a LVM partition type.

You can now initialize the single partition executing

pvcreate /dev/PARTITION

This creates a volume group descriptor at the start of the partition.
I have on my Bubba Two following partitions:

Code: Select all

fdisk /dev/sda
Device Boot Start End Blocks Id System
/dev/sda1 1 1217 9775521 83 Linux
/dev/sda2 1218 60669 477548190 8e Linux LVM
/dev/sda3 60670 60801 1060290 82 Linux swap

So I did:

Code: Select all

pvcreate /dev/sda2
File descriptor 5 left open
File descriptor 7 left open
Can't initialize physical volume "/dev/sda2" of volume group "bubba" without -ff

When I run the same command but with -vvv option, I get:

Code: Select all

pvcreate -vvv /dev/sda2
File descriptor 5 left open
File descriptor 7 left open
Processing: pvcreate -vvv /dev/sda2
O_DIRECT will be used
global/locking_type not found in config: defaulting to 1
File-based locking selected.
global/locking_dir not found in config: defaulting to /var/lock/lvm
Locking /var/lock/lvm/P_orphans WB
Opened /dev/sda2 RW O_DIRECT
/dev/sda2: block size is 2048 bytes
/dev/sda2: lvm2 label detected
lvmcache: /dev/sda2: now in VG #orphans_lvm2 (#orphans_lvm2)
/dev/sda2: Found metadata at 5632 size 874 (in area at 4096 size 192512) for bubba (GOrWkw-ZuqG-shPr-7ntg-Z0Jl-UPx5-qNC6r5)
lvmcache: /dev/sda2: now in VG bubba with 1 mdas
lvmcache: /dev/sda2: setting bubba VGID to GOrWkwZuqGshPr7ntgZ0JlUPx5qNC6r5
lvmcache: /dev/sda2: VG bubba: Set creation host to bubbatwo.
Closed /dev/sda2
Using cached label for /dev/sda2
Using cached label for /dev/sda2
Opened /dev/ram0 RW O_DIRECT
/dev/ram0: block size is 1024 bytes
/dev/ram0: No label detected
Closed /dev/ram0
Opened /dev/ram1 RW O_DIRECT
/dev/ram1: block size is 4096 bytes
/dev/ram1: No label detected
Closed /dev/ram1
Opened /dev/sda1 RW O_DIRECT
/dev/sda1: block size is 4096 bytes
/dev/sda1: No label detected
Closed /dev/sda1
Opened /dev/ram2 RW O_DIRECT
/dev/ram2: block size is 4096 bytes
/dev/ram2: No label detected
Closed /dev/ram2
Using cached label for /dev/sda2
Opened /dev/ram3 RW O_DIRECT
/dev/ram3: block size is 4096 bytes
/dev/ram3: No label detected
Closed /dev/ram3
Opened /dev/sda3 RW O_DIRECT
/dev/sda3: block size is 2048 bytes

What can I do to solve this problem?
Best, Pali
Cheeseboy
Posts: 789
Joined: 08 Apr 2007, 12:16

Re: Cannot boot from rescue usb

Post by Cheeseboy »

If you are desperate, why not try the suggested force option -ff?
paulchany
Posts: 123
Joined: 10 Jul 2009, 15:48
Location: Serbia
Contact:

Re: Cannot boot from rescue usb

Post by paulchany »

Cheeseboy wrote:If you are desperate, why not try the suggested force option -ff?
I did it now and get:

Code: Select all

pvcreate /dev/sda2 -ff
File descriptor 5 left open
File descriptor 7 left open
Really INITIALIZE physical volume "/dev/sda2" of volume group "bubba" [y/n]? y
WARNING: Forcing physical volume creation on /dev/sda2 of volume group "bubba"
Physical volume "/dev/sda2" successfully created

and after that I did:

Code: Select all

mount /dev/sda2 /mnt/home/
mount: mounting /dev/sda2 on /mnt/home/ failed: Invalid argument

So what to do further to get mounted my home directory?
Best, Pali
Ubi
Posts: 1549
Joined: 17 Jul 2007, 09:01

Re: Cannot boot from rescue usb

Post by Ubi »

Can we please take a moment and a step back to reflect on this please? I thought the issue was that a partition on the bubba HD could not be mounted. However, now it seems that an entirely new partition has been made under brutal force. It does not surprise me that this partition will not mount, as the disk was likely already fully allocated. Whatever data there was on /dev/sda2, I guess it's gone now...

Maybe it is a good idea if Paul again sums up what exactly it is he wants to achieve here, and please give us the output of vgdisplay and lvdisplay.
paulchany
Posts: 123
Joined: 10 Jul 2009, 15:48
Location: Serbia
Contact:

Re: Cannot boot from rescue usb

Post by paulchany »

Ubi wrote:Can we please take a moment and a step back to reflect on this please? I thought the issue was that a partition on the bubba HD could not be mounted. However, now it seems that an entirely new partition has been made under brutal force. It does not surprise me that this partition will not mount, as the disk was likely already fully allocated. Whatever data there was on /dev/sda2, I guess it's gone now...

Maybe it is a good idea if Paul again sums up what exactly it is he wants to achieve here, and please give us the output of vgdisplay and lvdisplay.
I want to mount /home directory on my Bubba Two because there I made the backup copy of the uImage before I build a new uImage. When I reboot with the new uImage, I can't use Bubba anymore. So now I'm using the rescue USB stick to ssh into my Bubba. I want to mount my home directory and reach there the backup copy of uImage. This uImage want I copy back to the /boot directory so I get my Bubba works again.

Code: Select all

vgdisplay
File descriptor 5 left open
File descriptor 7 left open

Code: Select all

lvdisplay
File descriptor 5 left open
File descriptor 7 left open
Best, Pali
Ubi
Posts: 1549
Joined: 17 Jul 2007, 09:01

Re: Cannot boot from rescue usb

Post by Ubi »

it's a bit disturbing that usenet reports that feature your "file descriptor X left open" all conclude it's a bug in LVM 2.02, which is the exact LVM version we have on the B3...

does pvdisplay return anything more useful than an error message?
do vgscan, pvscan or lvscan return anything at all?

did you read: http://cpenniman.blogspot.com/2010/02/c ... -open.html
paulchany
Posts: 123
Joined: 10 Jul 2009, 15:48
Location: Serbia
Contact:

Re: Cannot boot from rescue usb

Post by paulchany »

Ubi wrote:it's a bit disturbing that usenet reports that feature your "file descriptor X left open" all conclude it's a bug in LVM 2.02, which is the exact LVM version we have on the B3...

does pvdisplay return anything more useful than an error message?
do vgscan, pvscan or lvscan return anything at all?

did you read: http://cpenniman.blogspot.com/2010/02/c ... -open.html
I read it but sorry, I don't understand how affect this in my case.

Code: Select all

pvdisplay
File descriptor 5 left open
File descriptor 7 left open
"/dev/sda2" is a new physical volume of "455.43 GB"
--- NEW Physical volume ---
PV Name /dev/sda2
VG Name
PV Size 455.43 GB
Allocatable NO
PE Size (KByte) 0
Total PE 0
Free PE 0
Allocated PE 0
PV UUID mCuFlS-u4q0-pNMb-Iewm-32Co-KdiP-NsgF1z

Code: Select all

vgscan
File descriptor 5 left open
File descriptor 7 left open
Reading all physical volumes. This may take a while...

Code: Select all

pvscan
File descriptor 5 left open
File descriptor 7 left open
PV /dev/sda2 lvm2 [455.43 GB]
Total: 1 [455.43 GB] / in use: 0 [0 ] / in no VG: 1 [455.43 GB]

Code: Select all

lvscan
File descriptor 5 left open
File descriptor 7 left open
Best, Pali
Ubi
Posts: 1549
Joined: 17 Jul 2007, 09:01

Re: Cannot boot from rescue usb

Post by Ubi »

I'm tempted to suggest your filesystem on sda2 is kaput. I hope someone else here can show that this assumption is wrong...
paulchany
Posts: 123
Joined: 10 Jul 2009, 15:48
Location: Serbia
Contact:

Re: Cannot boot from rescue usb

Post by paulchany »

Ubi wrote:I'm tempted to suggest your filesystem on sda2 is kaput. I hope someone else here can show that this assumption is wrong...
Ah, I understand now.
OK, I'm give up now, and when I shall return to my Bubba Two again after 4 days, I think I shall install on it Debian GNU/Linux Squeeze again. But this time if I build again kernel on it, I shall backup uImage and kernel library not on my /home/username mount point but eg.: in /var directory. So from /var directory I can reach it if I run the rescue image again.

Thank you all for help! :D
Best, Pali
Cheeseboy
Posts: 789
Joined: 08 Apr 2007, 12:16

Re: Cannot boot from rescue usb

Post by Cheeseboy »

I shall backup uImage and kernel library not on my /home/username mount point but eg.: in /var directory.
I'd recommend using a different machine, and if possible one that is off-site.
Ubi
Posts: 1549
Joined: 17 Jul 2007, 09:01

Re: Cannot boot from rescue usb

Post by Ubi »

indeed.
Post Reply