LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-13-2021, 01:33 PM   #1
CJBIII
Member
 
Registered: Dec 2020
Location: Oak Lawn, IL
Distribution: openmediavault5, debian
Posts: 41

Rep: Reputation: Disabled
"You are in emergency mode." Editing fstab - UUID instead of label


I have set up an LVM on a RAID10 with the generous help of computersavvy. Running a headless openmediavault5 server.

I was setting up my folder system through the OMV5 interface on the RAID10 LVM through PuTTy from my Windows10 machine and then rebooted. Then I couldn't get back in to the server.

Broke down and made a hard shutdown of the server and added monitor, keyboard and mouse and restarted. Got an error.

After some research, it appears that maybe the UUID needs to be used instead of the label in the fstab. Never edited it before. Trying to get familiar with Vi.

I am a noob and don't know if I am on the right track. If I am not please advise.
Attached Thumbnails
Click image for larger version

Name:	IMG_20210113_110719x.jpg
Views:	16
Size:	205.6 KB
ID:	35255   Click image for larger version

Name:	IMG_20210113_110624x.jpg
Views:	13
Size:	107.7 KB
ID:	35256   Click image for larger version

Name:	IMG_20210113_114128x.jpg
Views:	11
Size:	200.3 KB
ID:	35257  
 
Old 01-13-2021, 04:29 PM   #2
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: CentOS 7
Posts: 3,483

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Did you create an mdadm.conf file? That's what is used to automatically assemble your array. You should also set up mdadm monitor to notify you if a disk fails.
 
1 members found this post helpful.
Old 01-13-2021, 05:04 PM   #3
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: A few
Posts: 5,934

Rep: Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822
Quote:
Originally Posted by CJBIII View Post
After some research, it appears that maybe the UUID needs to be used instead of the label in the fstab. Never edited it before. Trying to get familiar with Vi.
It seems that the UUID is not found. Run blkid or lsblk -f to find the correct UUID. If you set a label on that filesystem, it will also be printed.

If you are afraid of vi, use nano, or sed:
Code:
sed -i s/INCORRECTUUID/CORRECTUUID/ /etc/fstab
(replace the all-caps text with appropriate values)

Instead of repairing the UUID, you can also comment that line in fstab, which allows the server to boot. Then repair it in the more comfortable multi-user environment.

If the RAID has not been assembled, you need to assemble it first, as smallpond remarks.

Better make a backup copy of fstab (or any other file) before trying to edit it.

EDIT:

I had not seen the blkid output among your screenshots. Yes, there is an unassembled MD RAID array. Since it is not assembled, the LVM structures on top of the RAID are not detected, and the filesystem on top of LVM isn't either.

I would start by commenting the line with UUID 2450... from fstab, boot normally, and work on the RAID problem when the system has started.

This command:
Code:
sed -i.bak '/UUID=245044/s/^/#/' /etc/fstab
copies /etc/fstab to /etc/fstab.bak, then inserts a hash sign in front of the offending line. This should allow you to boot normally.

Last edited by berndbausch; 01-13-2021 at 06:34 PM.
 
1 members found this post helpful.
Old 01-13-2021, 06:05 PM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 20,832

Rep: Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738
In addition the output of blkid does not show the /dev/md0 as a LVM member or any logical volumes. As stated make sure the RAID is assembled and active.

Look at the output of the command:

cat /proc/mdstat
or
mdadm --detail /dev/md0

Once that is confirmed look at the output of the command
pvdisplay
 
2 members found this post helpful.
Old 01-14-2021, 12:00 PM   #5
CJBIII
Member
 
Registered: Dec 2020
Location: Oak Lawn, IL
Distribution: openmediavault5, debian
Posts: 41

Original Poster
Rep: Reputation: Disabled
These are the outputs for all of the requested.

I am looking to output pvdisplay, lvdiplay and vgdisplay. When I can I will post if needed.

I think I am in emergency.target mode, if that effects anyone's advice.

Physical Volume from sda-sde (md0) in a RAID10, Volume Group (mediaVG) and Logical Volume (mediaLV) were all created in LVM2 last week. ext4 was the file system.

I attempted to place my files in a folder (which I created called /one) through the graphical browser of openmediavault from a Windows10 machine. Many steps were done through OMV following online advice. When I rebooted I could no longer get into the server through PuTTY. I shutdown the computer the only way I could think of, hard, and I hooked up a monitor, keyboard and mouse and this is where I am.

Appreciate all the help.
Attached Thumbnails
Click image for larger version

Name:	01142021Forum.jpg
Views:	3
Size:	269.5 KB
ID:	35268   Click image for larger version

Name:	IMG_20210114_104516x.jpg
Views:	2
Size:	78.4 KB
ID:	35269  
 
Old 01-14-2021, 01:18 PM   #6
michaelk
Moderator
 
Registered: Aug 2002
Posts: 20,832

Rep: Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738
I believe I understand. You created a GPT partition table and partitions within the RAID and within partition 1 created the LVM. As far as I know this does not work. You can create partitions on a RAID but that is accomplished when it is created.

https://raid.wiki.kernel.org/index.php/Partitionable

However, is a LVM or logical volumes necessary? If you really want LVM I would suggest following the Arch wiki
https://wiki.archlinux.org/index.php..._software_RAID

If not create a filesystem directly on the RAID.
 
1 members found this post helpful.
Old Yesterday, 03:10 PM   #7
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: CentOS 7
Posts: 3,483

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
You should partition the drives and then create RAID from the partitions. Creating whole-drive RAID means there are no labels on the drives, so no way to find boot information. The platform firmware does not understand Linux RAID so the EFI partition needs to be non-RAID as well.
 
Old Yesterday, 04:19 PM   #8
michaelk
Moderator
 
Registered: Aug 2002
Posts: 20,832

Rep: Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738Reputation: 3738
As far as I know it should not matter since the RAID is just a data drive.
 
  


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
UUID and label - not sure how to edit fstab Captain Brillo Linux - Newbie 3 10-31-2018 09:40 PM
trouble umounting with LABEL=label in fstab JosephS Debian 3 02-01-2010 07:25 AM
[SOLVED] LABEL versus UUID in fstab and menu.lst eldiener Linux - General 7 01-04-2010 12:38 AM
* KipBond "rescue" mode can't mount filesystem w/ LABEL=/ in fstab KipBond Red Hat 0 02-06-2008 08:09 PM
Emergency Emergency kodiak Linux - Newbie 6 04-13-2003 01:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:03 PM.

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