You are not logged in.
Pages: 1
Hey Guys,
I've been using Linux for quite sometime, but historically I have gone for the "maintenance" free option of Ubuntu. I know, I know -- it wasn't so bad (I don't think) in the past, but lately I feel like it has become the "Windows of the Linux world". At any rate, after struggling for the better part of year to get my desktop workstation to perform to it's full potential (including 4 heads) I decided that I would try something a little more raw and ground up it. Arch is what I chose and let me just start by saying -- I #@$!! love it. I don't know why it took me so long to move over. With that said, I am posting in the newbie forum because I am having an issue with something and while I am not totally clueless on it, the post is probably most meaningful in here.
I have a 256 SSD that I have setup with the initial install. I have 25G for the boot partition, 128G for swap (following the 2X memory model), and the remainder set up as a (external) ext4. All of these partitions were created using cfdisk and come from /dev/sda* -- and with this in place, the system starts (all monitors work OUT OF THE BOX! Which was a real treat!) and the system is as blazing fast as I had once expected it to be.
Now, finally, my problem . The system has a series of hot swap bays. To get the install going I pulled all of them out, except for the 256 SSD of course. Now that everything is up and running though, I want to continue by putting these drives back in and mounting them to various areas of the OS. First up is a 500 GB SSD. When I am booted and in my display manager (deepin) I plug in the drive and it gets auto mounted. /dev/sdb1 is the reference. I have used cfdisk again here to create a new external partition that is the full size of the drive. I update my fstab with the following entry --
# UUID= ...
/dev/sdb1 /opt ext4 defaults 0 0
.. and truthfully I have tried a whole whack of other options in place of defaults. When I reboot the machine though I end up seeing some kind of processing or scanning that occurs for sdb1 and then once it stops I get --
/dev/sdb1: clean 174622/1638400 files, 1953254/6553600 blocks
[ TIME ] Time out waiting or device dev-sda.device
[DEPEND] Dependency failed for /dev/sda2
[DEPEND] Dependency failed for Swap
[ TIME ] Timed out waiting for device dev-sda5.device
[DEPEND] Dependency failed for File System Check on /dev/sda5
[DEPEND] Dependency failed for /home
[DEPEND] Dependency failed for Local File Systems
[ OK ] Reached target Timers
[ OK ] Reached target for Network
[ OK ] Reached target for Sockets
...
...
...
You are in emergency mode. After logging in, type ..
etc.
If I unplug the drive and reboot though, then all is well and the computer starts without issue -- so clearly I have either setup the drive incorrectly? or my fstab entry is wrong? or both. I read the main page for fstab, but I can't seem to figure out what I am doing wrong.
Any help?
Last edited by jardineworks (2017-06-19 16:18:43)
Offline
/dev/sdxX and friends aren't stable identifiers and will change from boot to boot. You seem to have a commented out UUID in your fstab, use those instead. Further info: https://wiki.archlinux.org/index.php/Pe … ice_naming
Offline
Ok -- I'll give that a shot now. It just occurred to me that perhaps I chose the wrong label type when I used cfdisk in the first place. I chose "dos" -- but from what I am reading in the man page perhaps that was the wrong choice? would "gpt" have been a better option?
Offline
Same issue, messaging has changed a little though.
[ TIME ] Timed out waiting for device dev-disk-by\x2duuid....
[ DEPEND] Dependency failed for /opt
[ DEPEND] Dependency failed for Local File System
[ OK ] Reached target Network
...
..
..
You are in emergency mode.
-- so same result . Could it be the type?
Offline
That depends on whether the advantages/disadvantages of GPT/MSDOS matter to you: https://wiki.archlinux.org/index.php/Pa … tion_Table
If it does boot correctly if the disk is alone, that shouldn't matter no. Post your fstab and
lsblk -l -o +UUID
Last edited by V1del (2017-06-19 14:27:31)
Offline
Just to be clear, it does boot correctly if the origina 256 SSD (/dev/sda) is in, the 500 GB SSD (/dev/sdb) is out and the entries in the fstab are only referencing sda. Here is my fstab (commented out the lines for the new disk so I could boot and provide the details you asked for)
#
# /etc/fstab: static file system information
#
# <file system> <dir> <type> <options> <dump> <pass>
# UUID=e6107bad-dd14-4b44-bfef-61e9913c6781
/dev/sda1 / ext4 rw,relatime,data=ordered 0 1
# UUID=3dc96a98-0b45-4990-9da4-9e8bd24bb01e
/dev/sda5 /home ext4 rw,relatime,data=ordered 0 2
# UUID=7da4ec21-6ec8-4fa0-bb70-6598aaf95cec
/dev/sda2 none swap defaults 0 0
#UUID=979d0c8a-e800-4fbd-8a94-83cc54bf71f8 /opt ext4 defaults 0 0
#/dev/sdb1 /opt ext4 defaults 0 0
I plugged the drive in once I was booted and arch auto mounted it for me. The results of the lsblk --
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT UUID
sda 8:0 0 232.9G 0 disk
sda1 8:1 0 25G 0 part / e6107bad-dd14-4b44-bfef-61e9913c6781
sda2 8:2 0 128G 0 part [SWAP] 7da4ec21-6ec8-4fa0-bb70-6598aaf95cec
sda3 8:3 0 1K 0 part
sda5 8:5 0 79.9G 0 part /home 3dc96a98-0b45-4990-9da4-9e8bd24bb01e
sdb 8:16 0 465.8G 0 disk
sdb1 8:17 0 465.8G 0 part /run/media/aj/979d0c8a-e800-4fbd-8a94-83cc54bf71f8 979d0c8a-e800-4fbd-8a94-83cc54bf71f8
sr0 11:0 1 1024M 0 rom
Thanks again for your help.
Last edited by jardineworks (2017-06-19 14:55:46)
Offline
Please use [ code ] tags when pasting command output or config files to the boards.
You should use your UUIDs for all of your disks, replace the /dev/sda1 in your fstab with UUID=e6107bad-dd14-4b44-bfef-61e9913c6781 and so forth (and especially important, make sure you use the UUID for the root partition in your bootloader's config as well)
Last edited by V1del (2017-06-19 14:45:46)
Offline
Just to make sure I am on the right path -- with your suggestions, I now have this in my fstab --
#
# /etc/fstab: static file system information
#
# <file system> <dir> <type> <options> <dump> <pass>
# UUID=e6107bad-dd14-4b44-bfef-61e9913c6781
#/dev/sda1 / ext4 rw,relatime,data=ordered 0 1
UUID=e6107bad-dd14-4b44-bfef-61e9913c6781 / ext4 rw,relatime,data=ordered 0 1
# UUID=3dc96a98-0b45-4990-9da4-9e8bd24bb01e
#/dev/sda5 /home ext4 rw,relatime,data=ordered 0 2
UUID=3dc96a98-0b45-4990-9da4-9e8bd24bb01e /home ext4 rw,relatime,data=ordered 0 2
# UUID=7da4ec21-6ec8-4fa0-bb70-6598aaf95cec
#/dev/sda2 none swap defaults 0 0
UUID=7da4ec21-6ec8-4fa0-bb70-6598aaf95cec none swap defaults 0 0
#UUID=979d0c8a-e800-4fbd-8a94-83cc54bf71f8
#/dev/sdb1 /opt ext4 defaults 0 0
UUID=979d0c8a-e800-4fbd-8a94-83cc54bf71f8 /opt ext4 defaults 0 0
.. and then I should update my /boot/grub/grub.cfg as well? I checked that file and I don't see any references to sda specifically, jsut references to hd0,msdos1. I've included the grub.cfg so you can see what I am looking at
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#
### BEGIN /etc/grub.d/00_header ###
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="0"
fi
if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi
export menuentry_id_option
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}
if [ x$feature_default_font_path = xy ] ; then
font=unicode
else
insmod part_msdos
insmod ext2
set root='hd0,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 e6107bad-dd14-4b44-bfef-61e9913c6781
else
search --no-floppy --fs-uuid --set=root e6107bad-dd14-4b44-bfef-61e9913c6781
fi
font="/usr/share/grub/unicode.pf2"
fi
if loadfont $font ; then
set gfxmode=auto
load_video
insmod gfxterm
set locale_dir=$prefix/locale
set lang=en_US
insmod gettext
fi
terminal_input console
terminal_output gfxterm
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
set timeout=5
fi
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/10_linux ###
menuentry 'Arch Linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-e6107bad-dd14-4b44-bfef-61e9913c6781' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_msdos
insmod ext2
set root='hd0,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 e6107bad-dd14-4b44-bfef-61e9913c6781
else
search --no-floppy --fs-uuid --set=root e6107bad-dd14-4b44-bfef-61e9913c6781
fi
echo 'Loading Linux linux ...'
linux /boot/vmlinuz-linux root=UUID=e6107bad-dd14-4b44-bfef-61e9913c6781 rw quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initramfs-linux.img
}
submenu 'Advanced options for Arch Linux' $menuentry_id_option 'gnulinux-advanced-e6107bad-dd14-4b44-bfef-61e9913c6781' {
menuentry 'Arch Linux, with Linux linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-advanced-e6107bad-dd14-4b44-bfef-61e9913c6781' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_msdos
insmod ext2
set root='hd0,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 e6107bad-dd14-4b44-bfef-61e9913c6781
else
search --no-floppy --fs-uuid --set=root e6107bad-dd14-4b44-bfef-61e9913c6781
fi
echo 'Loading Linux linux ...'
linux /boot/vmlinuz-linux root=UUID=e6107bad-dd14-4b44-bfef-61e9913c6781 rw quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initramfs-linux.img
}
menuentry 'Arch Linux, with Linux linux (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-fallback-e6107bad-dd14-4b44-bfef-61e9913c6781' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_msdos
insmod ext2
set root='hd0,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 e6107bad-dd14-4b44-bfef-61e9913c6781
else
search --no-floppy --fs-uuid --set=root e6107bad-dd14-4b44-bfef-61e9913c6781
fi
echo 'Loading Linux linux ...'
linux /boot/vmlinuz-linux root=UUID=e6107bad-dd14-4b44-bfef-61e9913c6781 rw quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initramfs-linux-fallback.img
}
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
### BEGIN /etc/grub.d/41_custom ###
if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
Offline
grub doesn't have the slightest clue of what is in your fstab and it uses UUID by default. Look at the lines startiung with "linux". (The "linux" lines tell grub where on a filesystem the kernel is and the options to pass to the kernel.)
aur S & M :: forum rules :: Community Ethos
Resources for Women, POC, LGBT*, and allies
Offline
Ok -- if I understand correctly then, it looks like the grub.cfg is already using the UUID. So all I should need are the changes to the fstab to reference the UUIDs explicitly?
Offline
Well yes, does it work now? If it does, please mark your thread as SOLVED by editing the title of your initial post.
Offline
Sorry -- got caught up in something else. Just rebooted and it works like a charm. Thanks for all your help! Will definitely mark this as the answer -- as soon as I figure out where there CTA to do that is.
Last edited by jardineworks (2017-06-19 16:16:15)
Offline
Pages: 1