diff --git a/src/rhcsa.md b/src/rhcsa.md index 7014c6b..d2a55c9 100644 --- a/src/rhcsa.md +++ b/src/rhcsa.md @@ -410,6 +410,11 @@ fi ### Change the grub2 configuration ```bash sudo grub2-mkconfig -o /boot/grub2/grub.cfg # Create a new grub configuration file + +sudo nano /etc/default/grub # Edit the grub configuration file + +# Add the following line to the grub configuration file: +GRUB_CMDLINE_LINUX="quiet splash" ``` ### dmesg @@ -462,4 +467,33 @@ runlevel # Display the current run level sudo systemctl get-default # Display the default target sudo systemctl set-default runlevel3.target # Set the default target to runlevel3.target sudo telinit 3 # Change to runlevel 3 -``` \ No newline at end of file +``` + +## Manage SSH Connections + +### ssh +```bash +ssh user@host # Connect to the host as the user + +ssh -p 2222 user@host # Connect to the host as the user on port 2222 + +ssh -i /path/to/private_key user@host # Connect to the host as the user using a private key + +ssh-copy-id user@host # Copy the user's public key to the host + +ssh-keygen -t ed25519 -C "comment" -f ~/.ssh/id_ed25519 -N "" # Generate a new ed25519 key + +ssh-keygen -t rsa -b 4096 -C "comment" -f ~/.ssh/id_rsa -N "" # Generate a new rsa key +``` + +### sshd_config +```bash +sudo nano /etc/ssh/sshd_config # Edit the sshd configuration file + +# Add the following line to the sshd configuration file: +Port 2222 + +sudo systemctl restart sshd # Restart the sshd service +``` + +## NFS & NTP \ No newline at end of file