RHCSA 7 and upstart, init, systemd

MinaryMinary Member Posts: 74 ■■□□□□□□□□
Any thoughts on this ? I suppose I just have to learn the lot anyway. But what about the exam ? Thoughts on the whole thing are welcome.

RH7 has sytemmd, Ubuntu is moving to it in the future and older RH has upstart and/or int. ( And slackware think it is to complicated)


Here Red Hat RHCSA & RHCE minor changes. - CertDepot

The video course I am doing doesn't mention it at all so far. (A good intro course BTW, was great value at $25 on the Udemy sale)

(https://www.udemy.com/red-hat-certified-system-administrator-exam-ex200-rhcsa/#/ )

Comments

  • darkerosxxdarkerosxx Banned Posts: 1,343
    Systemd is not hard at all to use and I agree with the move to it. Learn it by doing all the things you would before over and over on a test system with every single service on the system. Then do that again the next day, and the next, and the next... ;)
  • MinaryMinary Member Posts: 74 ■■□□□□□□□□
    What I mean is that I will be practicing mostly with systemd as the exam is on this. Should I go out of my way to do alot of work with upstart and init too ? I think I probably should.

    Also any general discussion on the different systems in the real world would be welcome.
  • brombulecbrombulec Member Posts: 186 ■■■□□□□□□□
    You should know how init works and generally as startup sequence for system looks like.
    My way for learning for RHCSA/RHCEv7 exam is to do all the tasks from RHCEv6 on RHEL v7 with IPv6 and MariaDB as additional tasks.
    I have to recertify my RHCE to get RHCA :)
  • dirkxxvidirkxxvi Member Posts: 7 ■□□□□□□□□□
    I'm getting ready to take it next week as well and one thing I've come across that I strongly suspect will be on the test will be employing the grub2 command line. In past study guides I've found fixing a broken MRB from GRUB consisted of the following
    grub->root
    grub-> setup (hd0)

    These commands no longer work in Grub2's bash shell. Unfortunately I'm still trying to learn how to find the root partition in case the grub entry is messed up but at the very least you should probably learn how to boot an OS from Grub2 manually. The link below is what I learned from last night.

    Load kernel and boot your system with GRUB2 - markomedia Technologies

    So here is what it meant for me
    grub->set root=(hd0,msdos1)
    #The following line you treat like appending the linux line in any grub bootloader, the same line where rghb quiet usually is. Without a root=device your system won't boot. You can also add rw to the end of it if you want it to boot with read-write permissions. Otherwise you use mount -o remount, rw / when you boot into the bash shell. To have a chance to reset the root password you add init=/bin/sh. I explain that a little more in the next part of this post.
    grub->linux /vmlinuz-3(tab autocomplete) root=/dev/mapper/cl-root rw init=/bin/sh
    #make sure .img is added to the end of this next command
    grub->initrd /initramfs-3(tab autocomplete).img
    grub->boot

    Other things I've learned from Grub2
    1. especially in a case where you're going to be reading files you're going to want to enter the following
    grub->set pager=1
    Without this any output you get will simply scroll to the bottom. So if you're trying to view a grub.cfg file without it you'll go straight to the end with no way to scroll up. set pager=1 pipes it to more so you can scroll long blocks of text that are longer than the screen

    2. To view all available devices you use the ls command
    grub->ls
    (hd0) (hd0,msdos2) (hd0,msdos1)

    2a. To view the files on that device you add / to the end of the device
    grub-> ls (hd0,msdos1)/
    At this point if your partition is on here you'll see stuff like
    grub/ grub2/ vmlinuz-3.10.0-123.el7.x86_64 and a bunch of other files

    3. set root=(device) allows you just type / instead of something like (hd0,msdos1)/ when bringing up files



    Another big thing is that changing the root password is no longer the same on RHEL 7.
    RHEL 7 / CentOS 7 : Recovering / Reset Root Password @ All Linux User's Blog

    The link above provides step by step instructions but I'll elaborate as well.

    As you probably know by now to change the root password in RHEL 6 you would boot into runlevel 1 by either adding single or 1 to the end of the line on the bootloader starting with Linux. That will not work anymore as even if you get to run level 1 you won't be able to set the root password that way as you'll only be given the option to enter an existing root password or ctrl+D for maintenance.

    In RHEL 7 you have to add init=/bin/sh instead of 1 or single.

    Also the part that will absolutely kill you if you forget to take care of it is in order for the new root password to sync for when you reboot the system you must MUST MUST ABSOLUTELY HAVE TO do the following otherwise SELinux will block the new root password you set and you'll be back to square 1.
    touch /.autorelabel

    The only thing I want to learn now is how to reinstall grub from the grub2 minimal Bash shell so if anyone knows that please let me know.
Sign In or Register to comment.