This repository contains some useful linux commands.
ssh-keygen -t rsa -b 4096 -C "your_email@example.com"
-> Simplify remote access command create a config file in your ~/.ssh folder. Each host you want to reach are configured in this config file. Here is an example of template for one host:
Host <hostNickName>
HostName <hostfullName>
IdentityFile ~/.ssh/certif.pem
User <theUser>
Here is a link heading to a nice interactive cheatsheet.
git log --graph --oneline --all --decorate=short
here is a link heading to a nice cheatsheet.
Add a temporary user
sudo adduser temporary
Add this user to sudoers
sudo adduser temporary sudo
Then log out, and log in using created user.
sudo usermod -l newUsername oldUsername
usermod -d /home/newHomeDir -m newUsername
( You may need to killall oldUsername before executing the 2 commands above to make sure no process is running for this user)
pkill -f <processName>
cat /proc/cpuinfo | grep processor | wc -l
update-rc.d <service-name> disable
wget http://ipinfo.io/ip -qO -