Saturday, November 5, 2022

How to change default ssh login banner

To create a cool ASCII art banner for your server, first start off by going here:

ASCII art creator/

To change the message displayed before login, edit /etc/ssh/sshd_config :
sudo vim /etc/ssh/sshd_config
and add (or uncomment) the line:
Banner /etc/banner
/etc/banner can be whatever file you want. Then edit /etc/banner
sudo vim /etc/banner
You’ll probably need to restart sshd before your changes take effect:
sudo /etc/init.d/ssh restart
To change the message displayed after login, edit /etc/motd :
sudo vim /etc/motd
and enter the message you want to display.

Friday, November 4, 2022

Linux system and Hardware details via command line

Uname command

Basic information can be access with command uname. Which is short for unix name.
  1. Linux Kernel Name
  2. uname -s
  3. Linux Kernel Release
  4. uname -r
  5. Linux Kernel Version
  6. uname -v
  7. Network Node Hostname
  8. uname -n
  9. Machine Hardware Architecture
  10. uname --m
  11. Processor Type
  12. uname -p
  13. Hardware Platform
  14. uname -i
  15. Operating System information
  16. uname -o
  17. Displaying All Information of Uname Command
  18. uname -a

CPU Information with lscpu command:

lscpu

Block Device Information with lsblk

lsblk
More detailed information for all devices:
lsblk -a

USB Device Info with lsusb

lsusb
More detailed information on each device:
lsusb -v

How to Install PostgreSQL on Debian 12: A Step-by-Step Guide

PostgreSQL, commonly known as Postgres, is a powerful, open-source relational database management system renowned for its advanced features ...