How to Secure a Linux Server with UFW, SSH Keygen, fail2ban & Two Factor Authentication

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

КОМЕНТАРІ • 175

  • @dejandadude
    @dejandadude 4 роки тому +20

    Someone give this man a Raise!

    • @danci947
      @danci947 3 роки тому

      apparently, he just got it...well deserved!

  • @ryanmitchell8208
    @ryanmitchell8208 4 роки тому +14

    Thank you so much for these videos. I am very interested in learning how to make my server apache and php secured, so I hope you do that video too!

    • @TechGuides
      @TechGuides  4 роки тому +4

      Thanks for watching! I might do it but it will definitely be a while until I can make it

  • @TheNuclearManx
    @TheNuclearManx 3 роки тому +8

    Very helpful video, thanks!
    Just a couple of things to note from my experience of trying to do some of these:
    1. I think you need to edit/add the [sshd] jail in jail.local rather than fail2ban.local
    2. You can set findtime = x (e.g., x = 1d). This is useful if you have maxretry > 1; it can look at the past x to detect previous login attempts rather than just the past 600 seconds
    3. Using `sudo service fail2ban reload` may be preferable. Apparently `reload` is normally a neater/tidier version of `restart`. For example, using reload, you won't reset the currently failed, etc.

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

    I know this video is several years old but instead of adding an alias for ssh it would be better to create a ~/.ssh/config and just add the port assignment there. man ssh_config for more information.

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

      Good tip! I wasn't aware of the config file back then but I do use it almost exclusively now ;)

  • @infodiff
    @infodiff 8 годин тому

    i successfully managed to install the google authenticator n it worked fine. but next day realised the filezella stopped working which i used to download the backups from the server as filezilla doesnt have option for 2 factor authentication. So uninstalled google authenticator

  • @feralshad0w
    @feralshad0w 3 роки тому +7

    I would love an apache webserver tutorial from you. These are very concise and extremely useful. Thank you for making them. There are a lot of verbose and confusing tutorials out there that can be difficult to follow.

    • @TechGuides
      @TechGuides  3 роки тому +3

      Thanks for the nice feedback! I tried to make those as easy to follow while still containing a lot of useful information :)

  • @justinreed1388
    @justinreed1388 4 роки тому +8

    Thanks, I look forward to watching the rest of these when they are uploaded.

    • @TechGuides
      @TechGuides  4 роки тому

      Awesome! More are coming soon

  • @tidusimango9364
    @tidusimango9364 4 роки тому +3

    Discovering your videos is probably the best thing to happen while building my own Ubuntu server. I have already built it and have multiple hard drives, I have dedicated one to PLEX. I'm worried that following this video would block access to plex, thus I won't be able to stream. Any thoughts on how to go about it? Perhaps adding plex into the list of allowed UFW's or allowing plex to access only the one harddrive? Would that compromise my server security? What do you recommend?
    Thanks.

  • @infodiff
    @infodiff 3 дні тому

    Just awesome video. I got stuck at google authenticator ... did everything as told, but it is not asking for ph code

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

    Nice tutorial. The only thing it might have been changed would be the rsa key. Why not use ed25519 key instead. It has an arc algorithm for encryption which is considered better than rsa
    Also how come and while you scp id_rsa.pub to the authorized_keys which are both file has as a result the index of the id_rsa to be copied inside the authorized_keys instead of copying the id_rsa.pub file to the other computer. I thought echo does that not scp

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

    You're videos are fantastic, just having a small issue with the SSH, I change the port in the .config and restarted the SSH service, even rebooted the server but it still only accept connection through the 22. Suggestions?

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

      I'm having the same issue right now.

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

      @@matthewpierce7717 Turned out I didn’t activated the port change. Don’t remember exactly where but there was “#” that shouldn’t be there.

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

    Thank you for this video. I have a question though, i set up the RSA key which is stored on my main PC. I tried to SSH from my phone through the wide area network and was still able to log in provided the port number, ipaddress, and password. I thought the RSA key is supposed to block that? Hope you have some insight, thanks again

    • @TechGuides
      @TechGuides  3 роки тому +1

      Setting up the RSA key is only one part. You also have to disable password based login as I describe after 12:11 :)

  • @beundeteunhaas9601
    @beundeteunhaas9601 4 роки тому +3

    Nice bitesized video for basic security.
    Thanks keep up the good work!

  • @eikominamoto6599
    @eikominamoto6599 3 роки тому

    please HELP ME after changing port i entered everything you said in windows powershell but it says connection timed out. Please tell me what to do? PLEASE HELP ME

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

    Thank you for the wonderful tutorial. One question though, once you've installed the Google pam on the server, can you use another authenticator apart from the Google authenticator to scan the QR code for use?

    • @ronit.dhingra_
      @ronit.dhingra_ 3 роки тому +1

      Yes, I tried this with Duo Mobile and it works just fine.

    • @TechGuides
      @TechGuides  3 роки тому +1

      Thank you! No, you don't necessarily need the google authentication, just one that implements the same algorithm.

  • @ox3965
    @ox3965 3 роки тому

    Tech guides, please could you help I have followed the tutorial but every time I use Google authenticator and I input the verification , my laptop disconnects, the connection.

  • @keiwarcraft
    @keiwarcraft 3 роки тому +1

    one question, can I use microsoft authenticator app instead of google one for this 2 factor auth?

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

    Ubuntu is broken. Nextcloud snap doesn't work with it.
    DietPi works!

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

    I would like to learn more on how to make my server apache and php secured, so I hope you do that video soon!

  • @JoJo-wk5rt
    @JoJo-wk5rt 3 роки тому

    If the port forwarding is set in the router, so setting the public port to something else as '22' in the router, I can still only connect to the server via 'ssh -p 22 user@ip'. How is that possible?
    so before doing this ua-cam.com/video/sO-afVsDJOA/v-deo.html

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

    Is a 64 character PW long enough for Nextcloud? Also with 2FA.

  • @mmroshani
    @mmroshani 3 роки тому +1

    Thanks, the security of NGINX is may be important too...

  • @rosemarieosborn8625
    @rosemarieosborn8625 4 роки тому +1

    I have ungoogled my life so this last bit with the authentication I cannot use but the rest of the video is brilliant, thank you.

    • @TechGuides
      @TechGuides  4 роки тому +1

      You can do the exact same with Authy ;)

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

    Bla, bla,bla you can do it in 2 minutes, not 20. crap

  • @ShibaHack
    @ShibaHack 4 місяці тому

    I had issues with fail2ban on Ubuntu Server 24.04, apparently at the time of me writing this, theres an issue with the python version used in 24.04 and fail2ban. Found a work around but it resulted in even more problems for me so I rolled back to 22.04 and everything worked fine.

    • @TechGuides
      @TechGuides  4 місяці тому

      Damn thanks for the headsul! I wanted to start using 24.04 soon and produce some content on it...

  • @freebyte1983
    @freebyte1983 4 роки тому +1

    Thank you your help and for your time. Please Can you explain how to build a production server ( ubuntu for ex nexcloud ) it will help me.

    • @TechGuides
      @TechGuides  4 роки тому +1

      Hey man! I can't quite follow, what do you want to build?

    • @freebyte1983
      @freebyte1983 4 роки тому

      Thanks. In your video you install home server . I want to know how to install a real server in production ( number of cpu, partitions , swap ) for nextcloud server.

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

    heads up your link for this video (How to secure a linux server ) ua-cam.com/users/redirect?event=video_description&redir_token=QUFFLUhqbW8tN2NoMlhVTUV2NDhxMGZaRHZObUI4STRwd3xBQ3Jtc0tscDFzMzlfd25rUGpjQXdmcDY5bWwtYkVrdzNzcG1MTXFnRjE4UTBqTGk1OS1XQTZkWDlCbTlkTUxMUGMxMmNVWEx1UXdyOHZzYUFpMHFmVE9hZFZTWmNFWElLR3FlcFVnenN5dFZPWWRramlLakZrYw&q=https%3A%2F%2Ftechguides.yt%2Fsecure-linux-server&v=sO-afVsDJOA goes to page with no content :) you can RM this comment :)

  • @IbanMieZ
    @IbanMieZ 3 роки тому +1

    I have never, in my life, learnt so much, from one video, sir! Thank you!

    • @TechGuides
      @TechGuides  3 роки тому

      So nice to hear, thank you!

  • @subashchaudhary891
    @subashchaudhary891 3 роки тому +1

    I am very interested in learning how to make my server apache and php secured

    • @TechGuides
      @TechGuides  3 роки тому

      OK great, I have planned to do a video on that sometime early next year!

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

    amazing video thanks

  • @jackv486
    @jackv486 4 роки тому +1

    Thanks, very helpful video 👍

  • @amr-50
    @amr-50 2 роки тому

    amazing video can you please refer me to the ssl video couldn't find it in the description

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

      Sorry for the late response, here you go I think its that one: ua-cam.com/video/c1t_OrIia1U/v-deo.html

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

    Great job man! Thanks. BTW are you aware of any setup or guide to use ubuntu server to enroll/approve devices connection to the home wifi router?

  • @AbhaySingh-yw2ej
    @AbhaySingh-yw2ej 4 роки тому

    I recently decided to convert my old laptop in a home server for a learning experience and why not. I have a 920m 2b Nvidia gc and 2tb hdd and i7-5500U with 16gb ddr3. My target is to have a secure network storage, a workstation to spin up VMs for small projects so I feel like a developer and learn the art of maintaining a system. I wish to keep the stack private, open source and stable. I got a good start with your videos, and would love to know popular use cases of dedicated home servers you have come across other than plex, nas and dhcp.

  • @smitty683
    @smitty683 3 роки тому

    What is the point of changing the default ssh port if you are just going to point traffic to it anyway from your router? Is there a special way of doing that?

    • @TechGuides
      @TechGuides  3 роки тому

      Cause attackers wont be able to get your ssh port that easily. They can still run a scanner but most attacks will just attempt to connect on port 22 and move on if nothing was detected (or at least thats what I hope)

  • @JoJo-wk5rt
    @JoJo-wk5rt 3 роки тому

    Would it be possible to login from a different IP/computer with a key based authentication and disabled root login?

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

    I realize this tutorial is 3 years old but it's still very informative and also s

  • @renzapolza6808
    @renzapolza6808 4 роки тому +1

    How can you access files from the explorer?

    • @TechGuides
      @TechGuides  4 роки тому

      Google samba file share on linux

  • @Vende-se
    @Vende-se 3 роки тому

    Who are the expert or masterclass that could have the best pratice on the market so i can pay to learn with ? any recomendation ?

    • @TechGuides
      @TechGuides  3 роки тому

      My videos are quite comprehensive but I'm sure you'll fined better "experts" on various paid course sites

  • @everonprofessionalservices6558
    @everonprofessionalservices6558 3 роки тому

    hi have followed all your steps 3 times on different ubuntu 20.04 servers, at file while trying to login i am getting this message " root@192.XXX.0.XXX: Permission denied (publickey)." what could have been wrong can you figure out please

    • @TechGuides
      @TechGuides  3 роки тому

      Did you update the authorized_keys file in the root directory and not the one from your linux user? Btw I do not recommend to login as root as this is generally considered unsafe practice

    • @everonprofessionalservices6558
      @everonprofessionalservices6558 3 роки тому

      @@TechGuides yes i have used root

  • @nikolas8741
    @nikolas8741 3 роки тому

    Thanks allooot

  • @nathan12581
    @nathan12581 3 роки тому

    Or just stick your whole server behind a web reverse proxy, only open port 443 to the public. Use a raspberry PI and use that as a VPN client for open vpn and vpn into your network when you want to access your server outside. No ssh security needed as it’s only available locally.

    • @TechGuides
      @TechGuides  3 роки тому

      Sure, unless you want to SSH from the outside ;)

    • @nathan12581
      @nathan12581 3 роки тому

      @@TechGuides You can SSH locally when connected to your home VPN if I’m not mistaken? I just prefer that over opening any more ports other than port 443 for my web apps, then I know my reverse proxy will handle everything the public internet will throw at my one open port on my network. Great videos by the way, keep it up :)

  • @ahmadimran6231
    @ahmadimran6231 3 роки тому

    Wow learnt something new about the 1024 limit and how the model is becoming obsolete. nice video.

  • @feralshad0w
    @feralshad0w 3 роки тому

    I had everything running great until the google authentication. Now I have an issue with
    "connection closed by **IP address** port **selected port**
    has anyone run into this issue? This error only occured after setting up the google two step authentication

    • @feralshad0w
      @feralshad0w 3 роки тому

      I FOUND THE ANWER!!!
      in the pam.d/sshd_config file, be careful to notice there is a "Standard un*x authentication" line AND a "standard un8x authorization" line.
      commenting out the wrong one will lock you out of SSH connection.

    • @TechGuides
      @TechGuides  3 роки тому

      Sorry to hear that you've locked yourself out :( Which line exactly did you erroneously comment out?

  • @ahmadaisabry
    @ahmadaisabry 3 роки тому

    The most informative video series in a very straightforward manner. You do not just type the command you are explaining what is behind the scene in a few concentrated informative pice of knowlde. Thank you very much. Could you please complete the series by Secure the next cloud instance itself (apache and PHP), also performance tuning for the server. (Apache, PHP, next cloud). Backup and restore.

  • @azo890
    @azo890 3 роки тому

    hey
    thanks alot for this tutorial
    i have a problem, some how, when i add the google authenticator it breaks the ssh and ask for the password then for the token from google
    any idees, to solve that?
    i googled ot, but still no results, if some one know how to solve it, it will be thankfull

    • @azo890
      @azo890 3 роки тому

      okey i found it
      ........
      To disable password prompt, we edit /etc/pam.d/sshd as below:
      sudo nano /etc/pam.d/sshd
      Comment out the line @include common-auth by adding # at the beginning.
      . . .
      # Standard Un*x authentication.
      #@include common-auth
      . . .
      Save the file and restart sshd.
      sudo systemctl restart sshd

    • @TechGuides
      @TechGuides  3 роки тому

      Hi! Great that you've got it resolved! I was slightly confused what didn't work for you, since I explicitly went over commenting out that line at 17:38 ;)

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

    you forgot to comment it out the line @include common-auth This tells PAM not to prompt for a password in /etc/pam.d/sshd

  • @OfficialRDB
    @OfficialRDB 4 роки тому

    Can login via command without password, but mobaxterm returns a error: no supported authentication methods available (server sent publickey)
    Edit: Advanced SSH settings and check "Use private key" and point to the file.
    Sorry i'm new to all this linux stuff whehehe.... Love you're videos.
    Is there something for the google auth in mobaxterm ? Because when i entered the code i need to type another one for the SSH-browser.
    I hope there is something to sync it or use the same.

    • @TechGuides
      @TechGuides  4 роки тому +1

      Thanks man! Hmm I haven't really used mobaxterm together with the google auth on my server. I think I tried it once and simply entered the same token twice. I would have to test it again though

  • @firewall_chronicles
    @firewall_chronicles 4 роки тому

    im trying to set up a server PLEASE MORE SERVER STUFF AND webserver security PLZ

  • @CarlosPerez-xx9gl
    @CarlosPerez-xx9gl 4 роки тому

    Could you show how to setup two factor authentication for a virtual machine in a Ubuntu VirtualBox? ...as I could do it successfully for a physical but the same procedure does not work for a VM, what could be wrong? ...thanks!

    • @TechGuides
      @TechGuides  4 роки тому

      I have no experience with virtual machines I'm afraid...

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

    Thanks for making these very useful videos. I did run into a bit of a problem though, and I haven't been able to get past it. After generating my ssh keys and copying the public key to authorized_keys on the server, I am still being prompted for a password. Any suggestions would be much appreciated.

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

      How do you access your server? Make sure you pass the private SSH key to the ssh command when connecting

  • @alexandragroza2611
    @alexandragroza2611 3 роки тому

    Uhmm, before this i just installed Nextcloud hub which, after i deleted port 80 from firewall, doesn't work anymore. Can it work without that port open?
    Also, you have been soooo helpful, as i only need a home server but this is the first time i am linux-ing, therefore i couldn't have done it without you in one round

    • @TechGuides
      @TechGuides  3 роки тому +1

      Yes you will need to open port 80 to be able to connect to your nextcloud instance. If you ever decide to enable SSL you'll need to open port 443 as well

  • @marcoFVD
    @marcoFVD 3 роки тому

    hi i did all on this video, it was going wel intel the google authenticator after that not possible to login :-( permission denied (publickey).....can some one help me, thanks

    • @TechGuides
      @TechGuides  3 роки тому

      Im sorry about that. Didnt you open another shell to test connecting with the new settings before disconnecting? Also dont you have physical access to your server?

    • @marcoFVD
      @marcoFVD 3 роки тому

      @@TechGuides hi the problem is the permitrootlogin set to no? but i,am a root.....:-( is there any away to get in?

    • @TechGuides
      @TechGuides  3 роки тому

      You should never login as root. You can do anything as any regular user as well. Simply log-in with a user that has sudo privileges. If you then need to become "root" your can just type "sudo su"

  • @ryansamra5
    @ryansamra5 3 роки тому

    Thanks for this tutorial it was very helpful

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

    Your tutorials have changed my IT world man! Danke schöne!

  • @JoostWagensveld
    @JoostWagensveld 3 роки тому

    Hi thanks for the extensive videos, I am looking forward to the rest.
    Why don't you use ssh-copy-id to add your key to the server?
    It is explained here in more detail.
    www.ssh.com/ssh/copy-id

    • @TechGuides
      @TechGuides  3 роки тому

      Thank you so much! I know that command, however it can also very quickly get you locked out of your server if you're not careful and I simply prefer to add keys manually.

  • @brandom301
    @brandom301 3 роки тому

    I want to log in from another machine, my laptop. Thus, I will generate another ssh key on ot. But how can I copy it to the server into the authorized_keys file without being able to log in from the laptop, since it requires an ssh key to log in?
    Thanks a lot for your videos by the way!

    • @TechGuides
      @TechGuides  3 роки тому +1

      I would just copy the new public key to a machine that already has access and write it to the authorized_keys file. Or disable keybased authentication for until you've installed the new key

  • @damiansmith4156
    @damiansmith4156 3 роки тому

    Nice video! I'm following these steps and since I did try updating server to install fail2ban. I can't update or upgrade or ping. Is anyone else having this issue?

    • @TechGuides
      @TechGuides  3 роки тому

      Hey thanks! Sorry for the late reply. What exaclty is your isseu? Did you install fail2ban and can't no longer log-in? If yes, check the list of banned IP addresses (you will need to physically connect to your sever to check if indeed you have accidentally banned yourself)

  • @donhalbert755
    @donhalbert755 3 роки тому

    Great video and thanks for posting it! The last step of adding AuthenticationMethods breaks my ability to login via SSH and the only solution is to login locally and remove that line and then it allows me to again login remotely. Any idea why?

    • @TechGuides
      @TechGuides  3 роки тому

      Thanks! What happens when you attempt to login? You're simply not getting the "Verification" prompt?

  • @6pac149
    @6pac149 4 роки тому

    You should look into a dashboard i.e. Heimdall, Homer, Dashmachine.
    The videos are great keep up the good work! :)

    • @TechGuides
      @TechGuides  4 роки тому

      Thanks for the suggestion and kind feedback! Appreciate it

  • @rosemarieosborn8625
    @rosemarieosborn8625 4 роки тому

    I do have an apache2 server but I haven't done much to it because I haven't secured it as of yet. Videos on how to secure an apache2 server from you would be awesome, thanks.

    • @TechGuides
      @TechGuides  4 роки тому

      Thanks for the suggestion! I'll put it on my list :)

  • @UmmarFarooqMahroof
    @UmmarFarooqMahroof 3 роки тому

    This was amazing. You're awesome. can you please do a video on securing a nginx server. I am trying to setup a dotnet core webserver

    • @TechGuides
      @TechGuides  3 роки тому

      I'm afraid I have never used NGINX so no real experience with that or any security related topics...

  • @yassinenacif418
    @yassinenacif418 3 роки тому

    Chapeau pour toi man!! This video was so useful. Keep up the great job!

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

    😁

  • @theFakeSleepyJoe
    @theFakeSleepyJoe 3 роки тому

    Excellent video. Thanks!

  • @greenland1164
    @greenland1164 3 роки тому

    You are the best. I would love to see more videos about securing an Ubuntu server. Are you still planning to make the other guides?

    • @TechGuides
      @TechGuides  3 роки тому

      Thanks! I have just released part 4 :)

  • @chaingain2196
    @chaingain2196 3 роки тому

    Are you Tech With Tim's older brother? :p

    • @TechGuides
      @TechGuides  3 роки тому +1

      Hahe the similarities are eerie right? :D

    • @chaingain2196
      @chaingain2196 3 роки тому

      ​@@TechGuides Yeah its actually a bit creepy ahhaha. Thanks for the video btw! I really enjoy watching these, very educational and well made :D

    • @TechGuides
      @TechGuides  3 роки тому

      Totally ;) Thank you so much!

  • @kthfriend
    @kthfriend 3 роки тому

    When is part5 coming?... looking for the nextcloud install.. thanks.

    • @TechGuides
      @TechGuides  3 роки тому +1

      I'm currently trying to get it out on the 23rd of January - although I'm not always great with my own deadlines ;)

    • @kthfriend
      @kthfriend 3 роки тому

      @@TechGuides thanks. It is appreciated...

  • @ox3965
    @ox3965 3 роки тому

    Wow one of the best most detailed videos, I have ever seen. I need more of these videos. You are the man. Tech guides

    • @TechGuides
      @TechGuides  3 роки тому

      Really appreciate it! Im trying to produce more videos like this very soon :)

  • @lubenbroadcasting986
    @lubenbroadcasting986 3 роки тому

    Hey, thx for this video! Helped me a lot!
    In case I want to give another user access to the server, I just need to copy his ssh key into the authorized_keys?

    • @TechGuides
      @TechGuides  3 роки тому +1

      Yes exactly! Cheers

    • @lubenbroadcasting986
      @lubenbroadcasting986 3 роки тому

      @@TechGuides Ah cool
      Google Auth doesn't work for me though on Ubuntu Server Version 20.04
      Message: "No supported authentication methods available (server sent: publickey)
      "
      Not sure where the mistake is since I copy-pasted it from your blog. But SSH is fine^^

  • @tolbaahmed
    @tolbaahmed 3 роки тому

    nice video

  • @moritzgeusen3818
    @moritzgeusen3818 3 роки тому

    Hi, I hope this is not too much of a hassle to you, but why did you copy the key a second time into the authorized_keys file at 11:55? I also got problems after this step, as I was prompted for some password(I'm using Ubuntu+Gnome) to unlock my private key.

    • @TechGuides
      @TechGuides  3 роки тому

      Just for the purpose of copying the public key into an already existing authorized_keys file ;)

    • @moritzgeusen3818
      @moritzgeusen3818 3 роки тому

      @@TechGuides I still don't really understand. Does it need to be there two times?

    • @TechGuides
      @TechGuides  3 роки тому

      No absolutely not. Only use one of the methods shown to copy your public key. The first method (copying the entire rsa_key.pub file onto the server) is applicable if you have never set up ssh keys on your server and thus the authorized_keys file does not exist yet. This is likely your situation if you are watching this video.
      The second method is only applicable if the authorized_keys file already exists on your server - so if you have already set up ssh key-based authentication before, i.e. for another computer. In that case, you don't want to simply copy & past the entire public key file onto your server or otherwise the authorized_keys file would obviously be overwritten and your other computer will no longer be able to connect.

  • @bolohead6067
    @bolohead6067 4 роки тому

    I keep getting client_loop: send disconnect: Connection reset by peer. I've changed my port, set up UFW and did keygen. but still get this and have to reconnect, appreciate your help in this matter, Thanks

    • @TechGuides
      @TechGuides  4 роки тому

      Did you allow the new port through UFW? Are you specifying that port when trying to SSH to your server (using the -e flag)?

    • @bolohead6067
      @bolohead6067 4 роки тому

      @@TechGuides yes I allowed new port in UFW. I used -e flag it worked. In my client machine in the bash rc file I still had 22 so I changed to my new port. Thanks for your help and your videos.

    • @TechGuides
      @TechGuides  4 роки тому

      Ah great that you could get it resolved! Cheers

  • @bolohead6067
    @bolohead6067 4 роки тому

    Mine, says Resource temporarily unavailable, when trying to ssh into home server. Any suggestions.

    • @TechGuides
      @TechGuides  4 роки тому

      Sounds like you've specified the wrong port after changing it in the sshd_config. Did you ssh using the -e port flag specifying the new port?

    • @bolohead6067
      @bolohead6067 4 роки тому

      @@TechGuides no I don't think I did that but was able to set different port number. Thanks. When I go into the sshd_config file concerning the keygen, (I set up pass phrase). Do I leave password authentication as yes and do I permit root login as no?

    • @TechGuides
      @TechGuides  4 роки тому

      Please follow the video guide from 09:02 onwards - I discuss exactly which options to set to yes and no

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

    Brilliant Tutorial, thanks! :)

  • @sirmarkalot9934
    @sirmarkalot9934 4 роки тому

    This is pretty cool

  • @gnuPirate
    @gnuPirate 3 роки тому

    Thanks dude! Great video and guide.

    • @nikolas8741
      @nikolas8741 3 роки тому

      My eyes are bleeding from you're picture😵

  • @zwyklyuser44
    @zwyklyuser44 4 роки тому

    Thx

  • @acarzia5580
    @acarzia5580 4 роки тому

    I have a pc build idea for you if your interested in hearing it?

    • @TechGuides
      @TechGuides  4 роки тому

      Dont have a lot of budget but Ill upgrade my PC soon so shoot!

    • @acarzia5580
      @acarzia5580 4 роки тому

      @@TechGuides Thats fine! What are your current specs? If you dont mine me asking.

    • @TechGuides
      @TechGuides  4 роки тому

      basically what I've got here ua-cam.com/video/F-qCbhxdKHE/v-deo.html but with 64GB trident z rgb ram and a different AIO because the kraken broke

  • @divakarrex9546
    @divakarrex9546 4 роки тому

    Can u please share how did u get the system info (temp, processor load ) on ssh login ??

    • @TechGuides
      @TechGuides  4 роки тому +1

      Do you mean glances?

    • @divakarrex9546
      @divakarrex9546 4 роки тому

      @@TechGuides Nope when u login via SSH u get the other machine details just wanted to know how can I get them when I login into my machine

    • @TechGuides
      @TechGuides  4 роки тому +1

      I think this always gets displayed when connecting to a server running Ubuntu

    • @jj-icejoe6642
      @jj-icejoe6642 3 роки тому

      Just web interface

  • @romabilibov7612
    @romabilibov7612 3 роки тому

    Awesome tutorial!!!!

  • @LR-pn6zd
    @LR-pn6zd 3 роки тому

    Awesome work, man

  • @xantra3072
    @xantra3072 3 роки тому

    Please my lord talk about nextcloud again, did it change much from your previous guide series ?

    • @TechGuides
      @TechGuides  3 роки тому +1

      Not really, the install is basically identical but I will show it without snap ;)

  • @salat
    @salat 4 роки тому

    Blocking ICMP echos is just silly as you'd get an 'host unreachable' answer from the last router before the host if the IP was really down instead of just no response. Maybe use reject with 'icmp-net-prohibited' instead..
    ICMP ist helpful - see shouldiblockicmp.com/
    Also: If you use a port >1024 for sshd, as long the sshd is running no other user program could bind to it. And if through some race condition some local user would be able to run a malicious sshd -> the host id would change. I don't really see a risk there..

    • @TechGuides
      @TechGuides  4 роки тому

      Thanks for watching! I agree with the sshd port, just didnt want to get the internet mad. Regarding the ICMP: not sure why I would ever want my private server to be pingable? What do you mean by "if the IP is down"?

    • @TechGuides
      @TechGuides  4 роки тому

      A bit sad you didnt follow up on this... Could you elaborate on what you ment?

    • @kevinjaniak3166
      @kevinjaniak3166 3 роки тому

      @@TechGuides What salat is saying is that blocking echos does not hide your server. A hacker knows your server exists because there is no "host unreachable" response from the router, only a timeout. The lack of this response indicates the router has a route (connection) to your server. I'd like to add, ping is a useful diagnostic tool. It can help you decide if a problem with your server is due to a configuration error or a network outage.

  • @mulletman1705
    @mulletman1705 3 роки тому

    Changing ssh port number from the default 22 is useless advice, it will not make anything more secure. Servers can just be scanned by anyone to see what ports they are listening on.

    • @TechGuides
      @TechGuides  3 роки тому

      This step is about mitigating automated attacks that will always try to use port 22. I get thousands of those each day, none ever try to do a full port scan

    • @mulletman1705
      @mulletman1705 3 роки тому

      @@TechGuides those automated attacks will be stoped by fail2ban, changing the port number does not increase security in any meaningful way.

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

    I used this video to setup my server. Thanks. Any new development since it was made three years ago?