Solved: Install ifconfig and ssh in Ubuntu

In this post we will see how to install ifconfig and ssh in Ubuntu 16.04 Xenial Xerus. You can install both or either of them independently .
ifconfig
By default you can check IP details in Ubuntu using
ip addr
But if you are more comfortable with “ifconfig”  then follow on.
Ensure that your Ubuntu instance is connected to internet or to your local package repository server from which it can pull packages.
If you need ifconfig in your ubuntu server use following commands.
sudo apt-get updatesudo apt-get install net-tools
“ifconfig” command should now work
ifconfig -a
ssh
If you are trying to get ssh. Use the below command.
sudo apt-get install openssh-server
Once the ssh installation is done check the status of ssh service
sudo service ssh status
If the service is not running you will have to start it with following command.
sudo service ssh start
Once this is done you should get a message of service started ok. You can check service status again with
sudo service ssh status
The default configuration file for ssh is /etc/ssh/sshd_config . If you make any changes to this file you will have to restart the ssh service to make the changes effective.
sudo service ssh restart
If you are using docker you can create a golden image after doing this installation. So that you don’t have to do this installation in all new containers. To check how to create a golden image for a docker container check this post .

No comments:

Post a Comment