Skip to content

Instantly share code, notes, and snippets.

@AjeetK
AjeetK / reset_root_passowrd.md
Created September 27, 2017 19:28
Reset MySQL "root" User Password

How To Reset "root" User Password In MySQL

Following are the set of commands to be run to reset root user password:

# 1. Stop mysql process
> sudo service mysqld stop

# 2. Change user to mysql & run mysql process using --skip-grant-tables option
> sudo su - mysql
@AjeetK
AjeetK / linux_users_management.md
Last active July 10, 2024 16:57
User Management in Linux

Types of user:

  1. Root User - It is the super user which can run any command generally used for administration.
  2. System User - Users needed for system specific operation/components, like mysql user to run mysql.
  3. Normal User - Other users which are created by root and have limited access given to them.

Attributes:

  1. User Type: Super user
  2. User Name: root
@AjeetK
AjeetK / .bash_aliases
Last active December 9, 2015 19:40
custom aliases to shorten the unix commands. Make a file ~/.bash_aliases and source the ~/.bashrc file.
alias cls='clear'
alias pag='ps aux | grep'
alias nreload='sudo servince nginx reload'
alias nstop='sudo service nginx stop'
alias nstart='sudo servince nginx start'
alias nrestart='sudo service nginx restart'
alias ebe='ember build --environment='
alias chmodx='sudo chmod +x'
alias epreprod='RAILS_ENV=pre_prod'
alias eprod='RAILS_ENV=production'