Skip to main content

Command Palette

Search for a command to run...

Basic concepts of linux

Updated
3 min read
Basic concepts of linux

Day 4

Hello everyone welcome back !!!

Myself Swanik Santosh Gudekar and I am back with my blog. This is the fourth blog of Linux series. Today I attended the fourth session conducted by Master Pranav Jambare. It was a fun and exciting session.

Points Covered in This Session :

  • Find and Locate

  • Secure Shell

Find and Locate :

Find :

  • The find command is to search the specified files in all of your computer's directories.

  • The find command is a more aggressive search tool than locate or which.

  • Using the file command we can search for files by name, owner, group, permissions, type, size, time modified, date and various other criteria.

  • The find command is highly efficient but this efficiency comes at a cost of time.

  • It produces real time output.

  • SYNTAX : find <where to start search> <what to find> <-options> <file/directory name>

Locate :

  • Locate command is used to find files and directives quickly.

  • This command is a more convenient and efficient alternative to the find command.

  • The locate command doesn't search the entire file system , but looks through a regularly updated file database in the system .

  • It is faster than find command but may not provide real-time outputs.

  • Locate command works better and faster than the find command.

  • SYNTAX : locate <file name>

Secure shell :

  • The SSH command provides a secure encrypted connection between two hosts over an insecure network.

  • SSH is a network protocol that enables secure remote connections between two system.

  • It is used to manage machines, copy, or move files between systems.

  • It is a secured remote access protocol and works on port no 22.

  • It transfers the data in an encrypted format.

There are two keys available in the ssh for encryption and decryption :

  1. Public key :
  • The public key is used for encryption and can be freely shared with others.

  • When someone wants to send you encrypted data, they will use your public key to encrypt it.

  • Its mechanism is slow.

  • It can be given to anyone with whom an individual wants to communicate.

  1. Private Key :
  • The private key is a secret key and can not be shared with anyone. This key is used to decrypt the received data.

  • The private key is used for both encrypting and decrypting sensitive data.

  • A user's private key is a key kept secret by the SSH user on his/her client machine.

  • The private key mechanism is faster.

There are two important package for creation of SSH connection :

  • openssh-client

  • openssh-server

SYNTAX :

  • Installing package : yum install <package name> -y

  • Check port : netstat -tumlp|grep 22

  • Check service status : systemctl status <service name>

  • SSH configuration file : vi /etc/ssh/sshd_config

  • To allow and deny user to connect to a specify user :

    Allow : vi /etc/host.allow

    Deny : vi /etc/host.deny

These were the topics covered by Master Pranav Jambare in the fourth session of Linux.

More from this blog

Swanik

9 posts