Sponsored Content
Operating Systems Linux Red Hat Device-mapper behaviour booting on init=bin/bash Post 302913653 by Ikaro0 on Tuesday 19th of August 2014 05:22:47 AM
Old 08-19-2014
Wrench Device-mapper behaviour booting on init=bin/bash

Good morning

Recently we needed to change the password from a redhat 6.5 system that no one knew the root password.

Starting the system with the init=/bin/bash method took us to the following scenario:

system_vg active with only root_lv and tmpfs mounted.

our entries at fstab are like "/dev/mapper/system_vg-root_lv /" kind of thing so the problem came when we tried to mount any other fs cause there were no other objects at /dev/mapper except system_vg-root_lv.

Is there anyway to reload the other lvs into /dev/mapper in order to be able to mount them?

I tried to scan with vgscan and lvscan after changing the lock file for lvm2 to /lock cause the lock file for lvm is located at /var/lock/lvm and that fs did not exist.

Thanks for the help in advance.
Regards
 

10 More Discussions You Might Find Interesting

1. Linux

Problem of booting system in init 5 level

Hi, I am using RHEL4 and I am not booting my computer into graphics mode i.e. It gets hangs after the step of Enabling swap space... I.e system is not able to enter into runlevel 5. However, when I boot it into 'runlevel3' and then I do "#startx", It enetrs... (1 Reply)
Discussion started by: jagdish.machhi@
1 Replies

2. Solaris

Solaris 8 booting from wrong device

Hi, I'm trying to boot solaris 8 box and it seems to boot off from wrong device: ok boot -s Boot device: /pci@1f,0/pci@1/scsi@8/disk@0,0:a File and args: -s SunOS Release 5.8 Version Generic_108528-20 64-bit Copyright 1983-2003 Sun Microsystems, Inc. All rights reserved. ifconfig:... (7 Replies)
Discussion started by: Juha
7 Replies

3. Red Hat

device-mapper-multipath path [undef]

I have an HP blade with Qlogic HBA's connected to an EVA8000. I have downloaded the latest multipath.conf from HP's website. The drive presented to the server appears to be configured and working except the output of "multipath -l" shows for all paths. What is causing this output? mpath0... (2 Replies)
Discussion started by: manzier
2 Replies

4. Red Hat

Device Mapper Notations and LVM

Hi, I had a doubt regarding device mapper notations and their corresponding LVM volumes. I have configured a volume group with two logical volumes in it as root and swap. The entries in the /etc/fstab file show the dm notations namely, /dev/mapper/VolGroup00-LogVol01... (2 Replies)
Discussion started by: kanna_geekworkz
2 Replies

5. Linux

If i don't have raid disks can i shut down dmraid device-mapper?

hello my centOS newly installed system loading dmraid modules on startup I did remove all LVM/raid things from system installation menus and after installation too but dmraid is still there and he says: no raid disks found also I did modprobe -r dm_raid45 and it do remove it but only until... (7 Replies)
Discussion started by: tip78
7 Replies

6. Programming

How to init the SPI device in daemon?

I have to make a linux monitoring daemon that works with a SPI device (/dev/spidev). However, I always failed to init this SPI device. The return error code is 25, which means "inappropriate ioctl for device". As I know, daemon runs in background and doesn't have a control terminal and this might... (3 Replies)
Discussion started by: bus147
3 Replies

7. Shell Programming and Scripting

Bash syntax behaviour : [[ vs [

Hello. In the following : RESTORE_FF contain a file name : a_file.tar.gz I am testing in a directory if "a_file.tar.gz" exists and or if any file like "a_file.tar.gz" exists. So "a_file.tar.gz" will give me file exists So "a_file.tar.gz." will give me file exists So... (5 Replies)
Discussion started by: jcdole
5 Replies

8. Shell Programming and Scripting

Usage of #!/bin/sh vs #!/bin/bash shell scripts?

Some question about the usage of shell scripts: 1.) Are the commands of the base shell scripts a subset of bash commands? 2.) Assume I got a long, long script WITHOUT the first line. How can I find out if the script was originally designed für "sh" or "bash"? 3.) How can I check a given... (3 Replies)
Discussion started by: pstein
3 Replies

9. UNIX for Advanced & Expert Users

Command to see the logical volume path, device mapper path and its corresponding dm device path

Currently I am using this laborious command lvdisplay | awk '/LV Path/ {p=$3} /LV Name/ {n=$3} /VG Name/ {v=$3} /Block device/ {d=$3; sub(".*:", "/dev/dm-", d); printf "%s\t%s\t%s\n", p, "/dev/mapper/"v"-"n, d}' Would like to know if there is any shorter method to get this mapping of... (2 Replies)
Discussion started by: royalibrahim
2 Replies

10. UNIX for Beginners Questions & Answers

In Bash shell - the ps -ef shows only the /bin/bash but the script name is not displayed

In Bash shell - the ps -ef shows only the /bin/bash but the script name is not displayed ? Is there any way to get the script names for the process command ? --- Post updated at 08:39 AM --- in KSH (Korn Shell), my command output shows the script names but when run in the Bash Shell... (3 Replies)
Discussion started by: i4ismail
3 Replies
SULOGIN(8)						Linux System Administrator's Manual						SULOGIN(8)

NAME
sulogin - Single-user login SYNOPSIS
sulogin [ -e ] [ -p ] [ -t SECONDS ] [ TTY ] DESCRIPTION
sulogin is invoked by init(8) when the system goes into single user mode. (This is done through an entry in inittab(5).) Init also tries to execute sulogin when the boot loader (e.g., grub(8)) passes it the -b option. The user is prompted Give root password for system maintenance (or type Control-D for normal startup): If the root account is locked, no password prompt is displayed and sulogin behaves as if the correct password were entered. sulogin will be connected to the current terminal, or to the optional device that can be specified on the command line (typically /dev/con- sole). If the -t option is used then the program only waits the given number of seconds for user input. If the -p option is used then the single-user shell is invoked with a dash as the first character in argv[0]. This causes the shell process to behave as a login shell. The default is not to do this, so that the shell will not read /etc/profile or $HOME/.profile at startup. After the user exits the single-user shell, or presses control-D at the prompt, the system will (continue to) boot to the default runlevel. ENVIRONMENT VARIABLES
sulogin looks for the environment variable SUSHELL or sushell to determine what shell to start. If the environment variable is not set, it will try to execute root's shell from /etc/passwd. If that fails it will fall back to /bin/sh. This is very valuable together with the -b option to init. To boot the system into single user mode, with the root file system mounted read/write, using a special "fail safe" shell that is statically linked (this example is valid for the LILO bootprompt) boot: linux -b rw sushell=/sbin/sash FALLBACK METHODS
sulogin checks the root password using the standard method (getpwnam) first. Then, if the -e option was specified, sulogin examines these files directly to find the root password: /etc/passwd, /etc/shadow (if present) If they are damaged or nonexistent, sulogin will start a root shell without asking for a password. Only use the -e option if you are sure the console is physically protected against unauthorized access. AUTHOR
Miquel van Smoorenburg <miquels@cistron.nl> SEE ALSO
init(8), inittab(5). 17 Jan 2006 SULOGIN(8)
All times are GMT -4. The time now is 02:40 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy