Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Open `~/.bashrc` :
- ```bash
- sudo nano ~/.bashrc
- ```
- and insert :
- ```bash
- # ES
- alias stopEs='sudo /etc/init.d/elasticsearch stop'
- alias startEs='sudo /etc/init.d/elasticsearch start'
- alias restartEs='sudo /etc/init.d/elasticsearch restart'
- # Redis
- alias stopRedis='sudo /etc/init.d/redis-server stop'
- alias startRedis='sudo /etc/init.d/redis-server start'
- alias restartRedis='sudo /etc/init.d/redis-server restart'
- # Apache
- alias stopApache='sudo apachectl stop'
- alias startApache='sudo apachectl start'
- alias restartApache='sudo apachectl restart'
- # Mysql
- alias stopMysql='sudo service mysql stop'
- alias startMysql='sudo service mysql start'
- alias restartMysql='sudo service mysql restart'
- # All
- alias startAll='sudo apachectl start && sudo service mysql start && sudo /etc/init.d/redis-server start && sudo /etc/init.d/elasticsearch start'
- alias stopAll='sudo apachectl stop && sudo service mysql stop && sudo /etc/init.d/redis-server stop && sudo /etc/init.d/elasticsearch stop'
- ```
- Then :
- ```bash
- source ~/.bashrc
- ```
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement