IT Nota

  • Home
  • How To
  • .NET
  • WordPress
  • Contact

How to Create SSH Keys

The recommendation now is to use ED25519 whenever you can.

Commands

Using ED25519

ssh-keygen -t ed25519 -C "[email protected]"

Using RSA

ssh-keygen -t rsa -b 4096 -C "[email protected]"

-C is optional, if not used then the login and machine name is going to be used instead.

Use -b to specify key size.

Ways to create SSH keys on macOS

On Mac OSX and Linux

You just get to Terminal and start typing:

ssh-keygen -t ed25519 -C "[email protected]"

You can use either your email address as label or anything that can be used to remind you what you use the SSH key for.

On PC

You need to download an external client such as puttygen (from putty) or if you have GIT, you can use the bash shell interface as well and the command is the same.

ssh-keygen -t ed25519 -C "[email protected]"

Adding the Key

eval $(ssh-agent -s)

ssh-add ~/.ssh/id_keys

To see the Keys

ssh-add -l

To copy key to clipboard:

$ pbcopy < ~/.ssh/id_keys.pub

Further Reading

PuTTY: a free SSH and Telnet client
Git
SSH key-type, rsa, dsa, ecdsa, are there easy answers for which to choose when?
Use SSH keys to communicate with GitLab

February 7, 2023 Filed Under: How To Tagged With: Git, Linux, macOS, Windows

How to Fix Ubuntu Missing add-apt-repository Command

Ubuntu Logo

If you happened to see a “sudo: add-apt-repository: command not found” error when typing sudo add-apt-repository command, then you need to install the software-properties-common package by typing the following:

sudo apt-get install software-properties-common python-software-properties

This error typically happens when you try to add a PPA to install any program that’s not in the official repositories in Ubuntu.

Further Reading

Ubuntu Linux Unleashed 2021 Edition (14th Edition)
The Linux Command Line: A Complete Introduction (2nd Edition)
How Linux Works: What Every Superuser Should Know (3rd Edition)

February 12, 2016 Filed Under: How To Tagged With: Linux, Ubuntu

What To Do Next After Installing Linux Mint

After installing Linux Mint, these are the things you may want to keep it up to date and configured properly.

Get Updates

Open Update Manager by clicking on the shield icon on the bottom right-hand corner (see inset) and click on the Install Updates button.

Linux Mint Update Manager Shield Icon Inset

Or from the terminal run the following command:

sudo apt-get update && sudo apt-get upgrade

Set UTF-8 Locale

Open Terminal and type in this command:

ls /usr/lib/locale

You will see this result.

# ls /usr/lib/locale/
C.UTF-8  locale-archive

Now, type in the following command:

sudo locale-gen --purge --no-archive

# ls /usr/lib/locale/
C.UTF-8     de_LI.utf8  en_CA.utf8  en_IN       en_US.utf8
de_AT.utf8  de_LU.utf8  en_DK.utf8  en_NG       en_ZA.utf8
de_BE.utf8  en_AG       en_GB.utf8  en_NZ.utf8  en_ZM
de_CH.utf8  en_AU.utf8  en_HK.utf8  en_PH.utf8  en_ZW.utf8
de_DE.utf8  en_BW.utf8  en_IE.utf8  en_SG.utf8

Further Reading

How-to fix “Warning: No support for locale: en_US.utf”

June 15, 2013 Filed Under: How To Tagged With: Linux

Installing Apache, MySQL and PHP on Linux Mint

This setup is intended for those who need to get their system up and running to do PHP web development. It is not recommended for production websites.

Install Apache

Open Terminal and type:

sudo apt-get install apache2

At the end of installation you will see a message saying:

* Starting web server apache2
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName

It’s nothing to worry about because most personal computers don’t have one.

Test Apache

Open a web browser and point it to URL:

http://localhost/

You should see a message saying:

It works!
This is the default web page for this server.
The web server software is running but no content has been added, yet.

Install PHP

Open up Terminal again and type in the following command:

sudo apt-get install php5 libapache2-mod-php5

Test PHP

In the terminal, type this command:

sudo pluma /var/www/test.php

This will create a new php file in Pluma text editor. Copy/Paste this line into the .php file.

<?php phpinfo(); ?>

Save and close the file.

From a web browser, try to load the file:

http://localhost/test.php

It should render a page with all information on the PHP installation.

Install MySQL

Still in the Terminal, type this command:

sudo apt-get install mysql-server

You will be prompted with Configuring mysql-server dialog to setup a root password. It’s recommended that you set a password.

Configuring mysql-server-5.5 Set Root Password

Install phpMyAdmin

sudo apt-get install libapache2-mod-auth-mysql php5-mysql phpmyadmin

In Configuring phpmyadmin window, press spacebar to check apache2 and press TAB key to move to and press Enter.

Configuring phpmyadmin on Apache2

Choose when asked to configure database for phpmyadmin with dbconfig-common.

Configuring phpmyadmin dbconfig-common

Test phpMyAdmin

From the browser, open this address:

http://localhost/phpmyadmin

You should see phpMyAdmin’s login page and be able to login using ‘root’ as Username and the password you setup earlier when you installed MySQL.

phpMyAdmin Login Page

Further Reading

Installing LAMP (Linux, Apache, MySQL and PHP) On Linux Mint

June 12, 2013 Filed Under: How To Tagged With: Linux

How to Install Sublime Text in Linux

Sublime Text 2 This short tutorial is based on the link provided on the bottom of this post with slight modifications. The example is shown with 64-bit version of Linux Mint.

Download Sublime Text

Open your browser and go to Sublime Text and download the file to directory Downloads.

Setup

Open Terminal and type in the following command:

cd ~/Downloads

Then type in this command to extract the file:

tar -jxvf "Sublime Text 2.0.1 x64.tar.bz2"

Once the file is extracted, type the following commands individually:

sudo mv "Sublime Text 2" /opt/sublime/

sudo chown -R root:root /opt/sublime

sudo chmod -R +r /opt/sublime

Create a Sublime Text Executable

Execute the following commands to create a Sublime Text executable in your path:

sudo touch /usr/bin/sublime_text

sudo chmod 777 /usr/bin/sublime_text

Launch Pluma Text Editor by typing ALT+F2 (RUN) and enter this command:

gksu pluma /usr/bin/sublime_text

Copy & paste the code below:

#!/bin/sh
export SUBLIME_HOME="/opt/sublime"
$SUBLIME_HOME/sublime_text "$*"

Pluma Text Editor Sublime Text 2

Save the file and exit.

Next, type in this command:

sudo chmod 755 /usr/bin/sublime_text

Create a Menu Icon

Launch the default text editor (Pluma) again by typing Alt+F2 and type in:

gksu pluma /usr/share/applications/sublime.desktop

Copy & paste the code below:

[Desktop Entry]
Encoding=UTF-8
Name=Sublime Text 2
Comment=Edit text, code and markup
Exec=sublime_text
Icon=/opt/sublime/Icon/256x256/sublime_text.png
Terminal=false
Type=Application
Categories=GNOME;GTK;Utility;TextEditor;
StartupNotify=true

Pluma Text Editor Sublime Text Desktop

That’s it. If you go to the Menu, you should see Sublime Text 2 under the Applications, Accessories.
Sublime Text 2 in Linux Mint Applications Menu

Download

Sublime Text

Further Reading

Install Sublime text editor

June 2, 2013 Filed Under: How To Tagged With: Code Editor, Linux, Sublime Text

Next Page »
Buy me a coffee Support this site
Buy Me a Coffee?

Categories

  • .NET
  • Coding
  • Cybersecurity
  • Database
  • How To
  • Internet
  • Multimedia
  • Photography
  • Programming
  • Resources
  • Review
  • Tips and Tricks
  • Uncategorized
  • Use Case
  • WordPress
  • Writing

Recent Posts

  • How to View Stored Procedure Code in SQL Server
  • How to Find a String in SQL Server Stored Procedures
  • How to Remove Cached Credentials without Rebooting Windows
  • ESP Work Automation: Empowering Enterprises with Streamlined Workflows and Operational Efficiency
  • How to Search for a String in All Tables in a Database

Recent Posts

  • How to View Stored Procedure Code in SQL Server
  • How to Find a String in SQL Server Stored Procedures
  • How to Remove Cached Credentials without Rebooting Windows
  • ESP Work Automation: Empowering Enterprises with Streamlined Workflows and Operational Efficiency
  • How to Search for a String in All Tables in a Database

Tags

.NET .NET Core AdSense ASP.NET Cdonts Dll Classic ASP Code Editor ETL FSharp Genesis Framework Git Google HP Asset Manager HTML5 Hugo IIS Information Security Internet Internet Information Services iOS JAMStack Linux macOS Microsoft Microsoft SQL Server MVC PHP PowerShell Python Simple Mail Transfer Protocol Smtp Server SQL SQL Server SSIS SSMS SSRS Sublime Text Visual Studio Visual Studio Code VPN Windows Windows 8 Windows 10 Windows 2012 Windows Server

Copyright © 2011-2025 IT Nota. All rights reserved. Terms of Use | Privacy Policy | Disclosure