First, the Linux network configuration
Ifconfig eno16777736 192.168.19.48/24 | eno16777736 (NIC name) 192.168.19.48/24(temporary IP address)
DNS : vim/etc/resolv.conf content display (nameserver 202.156.16.47 (DNS address))
Gateway : route add default GW (gateway address) netmask 255.255.255.0
View gateway Information : routing Table
change to static IP : cd/etc/sysconfig/network-scripts/ vim ifcfg-eno16777736(NIC name)
Change bootproto= ' static ' ------>static static meaning
After entering the VIM editor, add the following specified content under bootproto= ' static ':
ipaddr=192.168.19.48
netmask=255.255.255.0
gateway=192.168.16.254
dns1= 192.168.16.254
:Wq Save exit
Restart service :systemcal Restart Network
View DNS:cat/etc/resolv.conf
Vim/etc/hosts IP Address domain name
Set host name : hostnamectl set-hostname new_name(new hostname)
SCP /etc/hosts 192.16.19.47 (Destination IP) :/tmp #类似上传
SCP: copy /etc/hosts: file address to be copied 192.16.19.47 (Destination IP): object to be passed to /tmp: Save Address (To be preceded by:)
SCP 192.16.19.47 (Destination IP):/tmp/etc/hosts #类似下载
the client creates the lock and key : Ssh-keygen and then returns
View the locks and keys created : ls/root/.ssh
Display content :id_rsa(key) id_rsa.pub(lock)
s sh-copy id-i 192.168.19.47(Destination IP address, service-side lock)
on the service side :cd/root/.ssh
View content :ls
Display content :authorized_keys(the lock just passed over)
Now the Client Access server does not have to enter the password every time.
008day--linux basic Network configuration and SSH service