Linux Crash Course - sudo

Поділитися
Вставка
  • Опубліковано 19 вер 2024

КОМЕНТАРІ • 84

  • @CjqNslXUcM
    @CjqNslXUcM 2 роки тому +16

    9:43
    another good tip is: !* is all arguments from the last command (not the command itself), super useful if you want to do a bunch of things to the same files
    !:1 is the first argument !:2 the second etc..
    !:1-3 group of arguments
    !$ last argument
    !:0 the command only (0th argument)

  • @OferSadan85
    @OferSadan85 2 роки тому +30

    I've been a Linux user for 15 years without knowing some of the basics you're teaching. Thank you!

  • @Ollital
    @Ollital 2 роки тому +3

    I'm using sudo for many years now. Thanks to your video I'm understanding the /etc/sudoers file for the first time.

  • @12Q46HPRN
    @12Q46HPRN 2 роки тому +24

    Outstanding as always. I've been a Linux user for a few years now, but I always learn something from your videos. Thank you so much!

  • @jofastuff
    @jofastuff 2 роки тому +8

    Very informative video as usual, however, please note that allowing sudo access to apt (like in the example at @18:20) makes it trivially easy to escalate into a root shell (by appending -o APT::Update::Pre-Invoke::="/bin/bash" as an argument) and thus should be avoided.

  • @BigBlueMotors
    @BigBlueMotors 2 роки тому +5

    Love your Linux lessons - straight to the point without a lot of fluff. 👍 Fever distractions.

  • @n0madfernan257
    @n0madfernan257 2 роки тому +3

    Channel underrated. Thanks for these lectures.

  • @nirabhmani9523
    @nirabhmani9523 Рік тому +1

    sudo -l command as well as visudo with different options of fixing the sudo file was fantastic!! 😃

  • @mila-sz7lz
    @mila-sz7lz 2 роки тому +6

    I think you have the most, if not the only, useful linux channel. Thank you man 🙏

  • @OulahceneYousra
    @OulahceneYousra 7 місяців тому

    hey , i just wanna say that your videos are so informative and easy to grasp ,especially for a beginner like me who is still tyring to learn the ABc of linux , a huge thanks buddy

  • @slaxmax9219
    @slaxmax9219 3 місяці тому

    It never gets to old ;)

  • @skug978
    @skug978 2 роки тому +1

    As a Linux SysAdmin, I avoid using "sudo" for admin of Linux systems. With Debian Linux, "sudo" is not active by default, and the distro expects you to use the "root" account for maintenance. The preferred usage for "sudo" is for giving some elevated privileges to specific users, as you demonstrated. However, "sudo" isn't needed for working on Linux, and it comes down to preference - I feel you should have made that clear in your video. (I do agree that the root account shouldn't be accessible remotely, i.e. you need to logon to the machine as a regular user, then use "su -" to gain root after that.)

  • @froid_san
    @froid_san 2 роки тому +1

    Great video! Now the thing i put or edit on sudoers files makes more sense. Hope in the future you tackle ACL.

  • @ObsidianMercian
    @ObsidianMercian 2 роки тому +1

    Awesome video as usual, I love this series. Thanks Jay!

  • @Dean-vd5wr
    @Dean-vd5wr 2 роки тому +5

    Great video Jay. I am a newbie, and I'm still trying to understand the commands in the terminal.

  • @GuardianApe
    @GuardianApe 2 роки тому +2

    I love you man , thank you so much for these videos. I have a question. In what order am I to go through the Linux essentials playlist ?

  • @guypartush2976
    @guypartush2976 10 місяців тому

    Dear Jay thank you very much for all your work and effort educating us with your vast knowledge. I am making my first cybersecurity steps and your videos are an enormous help!

    • @LearnLinuxTV
      @LearnLinuxTV  9 місяців тому

      I’m glad my videos are a great help to you. Thank you so much for your kind comment.

  • @radioactive828
    @radioactive828 8 місяців тому

    THANK YOU THANK YOU THANK YOU! Really saved me SO much trouble! Subbed!

  • @Indigenous_Patriot_1175
    @Indigenous_Patriot_1175 2 місяці тому

    I am new to Linux and Im loving your content. I am interested in running Arch Linux. I just watched this video and I notice while going along that visudo is not found in Arch.

  • @CeeTheJay
    @CeeTheJay Рік тому +2

    I've always pronounced it "pseudo," assuming it was GNU-style wordplay. It's a fake super user account, therefore: 'pseudo' (sudo). Does anyone else think of it this way? :)

  • @LeonardoMarioMartinez
    @LeonardoMarioMartinez 2 роки тому +1

    Another interesting thing is the use of the /etc/sudoers.d/ directory for custom setup. It's a more clear aproach and a better way to manage users and groups privileges.

  • @Im.Tabachnik
    @Im.Tabachnik 2 роки тому +1

    I love the way you teach, and I learn from you a lot, Thank you for all the great investment.
    and I will happy if you can create a video about NFS share from Linux to Linux\Windows.

  • @DL-xf3ur
    @DL-xf3ur 2 роки тому

    Thank you as always Jay! You're the best.

  • @NoEgg4u
    @NoEgg4u 2 роки тому +4

    @20:50 -- "NOPASSWD"
    What if there were some commands where you do not want to be asked for a password, and other commands where you do want to be asked for the password?
    How would that syntax be laid out in the sudoers file?

    • @d00dEEE
      @d00dEEE 2 роки тому +2

      Just add multiple lines, one with NOPASSWD and the other without. There might be ordering issues, so try it and if it doesn't work one way, swap the NOPASSWD line before or after the other one for a given user.

  • @Liam_Tomhet
    @Liam_Tomhet 2 роки тому +1

    @10:20 as he stated: normally you would not edit/modify that file. Not sure if the same for arch linux. But in artix linux it is required modify that file to uncomment (delete #) the wheel group to allow sudo in that group.

    • @hvacmisadventures
      @hvacmisadventures 3 місяці тому

      I know it’s been a year since you commented but if you see this …
      That was a question I had: what is the best practice?
      Is it best to just add users to sudo group and leave the file alone except for special circumstances?

    • @Liam_Tomhet
      @Liam_Tomhet 3 місяці тому

      @@hvacmisadventures best practice is to leave it unless required otherwise.

    • @hvacmisadventures
      @hvacmisadventures 3 місяці тому

      @@Liam_Tomhet thanks man 🫡

  • @x91w
    @x91w 2 роки тому +1

    Jay, as usual nice presentation.
    The problem I found when working was big companies like IBM saying "MQ/DB2/WAS/etc can only be updated from root NOT sudo" and we had a method to temporarily change root, turn on insane syslog give it to IBM and change it back after and hope they hadn't installed some pkexec.c elevation stuff.
    How would you approach that problem ?
    Thankfully I'm now retired

  • @mahsumsaetgareev
    @mahsumsaetgareev 2 роки тому +1

    I am new to linux, so I am sorry if I ask silly question. Isn't there a user jay in the system and if so shouldn't information about it be in sudoers?

  • @framebrain
    @framebrain 11 місяців тому

    Thanks Jay! Great content

  • @TheExard3k
    @TheExard3k 2 роки тому +1

    neofetch next? :)

  • @relytheone853
    @relytheone853 11 місяців тому

    More videos like this, please!

  • @darren537
    @darren537 2 роки тому +2

    Thanks! Can you please do an install and walk through of EndeavorOS for beginners that are interested in ARCH,pacman and the AUR but are intimidated by the are way installation?

    • @systemuser9636
      @systemuser9636 2 роки тому

      @Darren hey man I just switched from Ubuntu to Endeavour. That would be a great video.

    • @rahilarious
      @rahilarious 2 роки тому

      i think this channel is more targeted towards server linux than desktop. For arch content u should ermano ferrari

  • @darklinux_
    @darklinux_ 9 місяців тому

    Very very good your explain. Thanks a lot

  • @jayvuillermin1414
    @jayvuillermin1414 3 місяці тому

    Hey Jay, I love your content bro, sorry, this is a bit unrelated, but while watching this video I was playing around and I ran HTOP and grepped for systemd on kali 2024. I slowed my system right down which I can't say I was surprised by. So I thought after a few seconds, I'll Control+C out of this. I did and all was well. I sort of accidentally knocked my mouse and noticed something odd. I noticed that the terminal started printing what I believe was my wireless mouse' current position in some kind of code (coordinates) that constantly changed depending on where I'd move the mouse. I'm a noob. I listen and watch and re-watch again and again to cement it in my head which is what I was doing (listening to you) while doing something else when I noticed this. Could just be my system. Maybe you can replicate it? Maybe you're already well aware of it? Maybe it's nothing? To me it was odd. I know to you it'll be nothing new but it was really interesting mate. Hey, thanks for the time you take and the energy you put in to educate and help others! We need more folks like you mate. Cheers

  • @catupeloco
    @catupeloco 2 роки тому

    I'll leave the video with something New. Sudo !! Is a good one

  • @richardkruse4663
    @richardkruse4663 3 місяці тому

    I know this is old, but what's new is that in Debian-12, neither the 'adduser' command nor the 'usermod' command is available.even as 's -'. Any comment? (I enjoy your 'Learn Linux TV' posts!)

  • @TMavC5
    @TMavC5 2 роки тому

    I like to see ESXI with VM of Ubuntu GPU passthrough in this channel.

  • @kiasalimi5108
    @kiasalimi5108 7 місяців тому

    thank you for the content, A++++

  • @JefferyOwusu-ft8ci
    @JefferyOwusu-ft8ci 3 місяці тому

    how do i set password to my root when using ssh root@ip

  • @amanwehib8367
    @amanwehib8367 2 роки тому

    Clear and concise!!!!!!!!!!!

  • @jothamsia
    @jothamsia 10 місяців тому

    Is it possible to make specific sudo commands to require password

  • @zeppelinmexicano
    @zeppelinmexicano 7 місяців тому

    With regard to that botched sudoers file, does the errant "ALL" affect just user tux, or is the file then just botched for all use?

  • @mramosch
    @mramosch Рік тому

    Created a ‘tux’ user without any further changes and this user can reboot the machine running RaspberryOS - That doesn’t seem appropriate…

  • @cristoforopontikas
    @cristoforopontikas 2 роки тому

    Hello, great video but i would like to mention that the last command for the NOPASSWD isn’t correct.
    I have give it a try and verify that the correct line to type is the next one. Suppose the user is called chris
    chris ALL=(ALL) NOPASSWD:ALL
    if you type as you describe then it want work. Al least on Raspberry os 64 bit latest official release
    chris ALL=(ALL:ALL) NOPASSWD:
    This will not work. Why?

  • @noonewhocares654
    @noonewhocares654 10 місяців тому

    excelent!

  • @ravitejareddy3818
    @ravitejareddy3818 Рік тому

    Is this for linux admin?

  • @evodefense
    @evodefense 9 місяців тому

    thx

  • @temoshee7477
    @temoshee7477 2 роки тому +1

    Why is the 'jay' user not in the sudoers file?

    • @TheDillio187
      @TheDillio187 2 роки тому +3

      jay is a member of the sudoers group

  • @efeley44
    @efeley44 2 роки тому

    Guys help!!!!!
    When I try to put my password, it says password invalid. I don't why tho cuz it's literally is my account password, what should I do?

  • @kamertonaudiophileplayer847
    @kamertonaudiophileplayer847 2 роки тому

    Anyway, if you do sudo, somehow it will consider your home directory as /root, how can I keep it as /home/user?

  • @AliTwaij
    @AliTwaij 2 роки тому

    excellent thabkyou

  • @andrewmunro8830
    @andrewmunro8830 2 роки тому

    Newish to Linux and I'm sure I should have more insightful questions by now, but what I really want to know is ... what's the font in your terminal emulator? I really like the @ symbol!

  • @El_Bartto
    @El_Bartto 8 місяців тому

    using linux for the first time, sudo asks me for a password, which password is that? the one that I use to log in or the super user one?

  • @abdulqayyumshah9217
    @abdulqayyumshah9217 2 роки тому

    Great

  • @Steamrick
    @Steamrick 2 роки тому

    Sudo? The thing that CVE-2021-4034 has made superfluous?

    • @LearnLinuxTV
      @LearnLinuxTV  2 роки тому

      Unless I'm misunderstanding your comment, that CVE specifically refers to polkit not sudo. Unless you're referring to a vulnerability chain, but vulnerabilities and chaining vulnerabilities is not uncommon.

    • @Steamrick
      @Steamrick 2 роки тому +1

      @@LearnLinuxTV I was basically referring to a comment in the Veeam Newsletter (formally "Veeam R&D Forums Digest"), trying to poke some fun:
      "Another way to look at it: that sudoers file was completely optional for the past 12 years, as anyone in the know could just run any command as root"

  • @belldiogbo2193
    @belldiogbo2193 2 роки тому

    How can I reach you I need to get some more lesson on linode

    • @LearnLinuxTV
      @LearnLinuxTV  2 роки тому +2

      There's a "request assistance" page on the main website. But I'm already working on new Linode content, so it's possible that content might already address your question.

  • @jeremyleonbarlow
    @jeremyleonbarlow 2 роки тому

    sudo apt install doas, sudo dnf install doas, or sudo pacman -S doas is what I've heard is the best use of sudo.

  • @semikolondev
    @semikolondev 2 роки тому +2

    Sudo win lottery

  • @bernard1475
    @bernard1475 2 роки тому

    doas* ;p

  • @fsxspen
    @fsxspen Рік тому

    Q is a stupid option

  • @tacticaldepartment1929
    @tacticaldepartment1929 2 роки тому

    can you tich me sir linux

  • @vampiregoat69
    @vampiregoat69 6 місяців тому

    So you don't tell people how to install sudo since you have it already that is a bit messed up I thought this was LEARNING to do not I have it already if you don't tough sht

    • @SR-mj9ei
      @SR-mj9ei 4 місяці тому

      As root "apt install sudo"
      Edit: replace apt with your package manager dnf pacman etc

  • @shkjuy6935
    @shkjuy6935 2 роки тому +1

    Thnx