Arter reboot sshd service is stop??

Issues related to configuring your network
Post Reply
mayank_pasi
Posts: 21
Joined: 2016/12/25 16:04:05

Arter reboot sshd service is stop??

Post by mayank_pasi » 2017/01/11 09:32:04

hi

My server is stop service of sshd after reboot
Avery time fast start sshd start

after save iptables
then again it's stopd
what I do for save or start ssh service
Regards
Mayank

mghe
Posts: 766
Joined: 2015/11/24 12:04:43
Location: Katowice, Poland

Re: Arter reboot sshd service is stop??

Post by mghe » 2017/01/11 09:40:14

You have to enabled services to start during restart server.

# systemctl enable sshd.service

For iptables you have to allow for 22 port.

mayank_pasi
Posts: 21
Joined: 2016/12/25 16:04:05

Re: Arter reboot sshd service is stop??

Post by mayank_pasi » 2017/01/11 10:10:34

in my Laptop says that

ssh 10.63.35.156
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
ca:a8:48:77:8d:b3:40:10:c2:d3:e6:fa:5a:a5:35:5c.
Please contact your system administrator.
Add correct host key in /home/mayank/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /home/mayank/.ssh/known_hosts:1
RSA host key for 10.63.35.156 has changed and you have requested strict checking.
Host key verification failed.
[mayank@localhost ~]$


what is that

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Arter reboot sshd service is stop??

Post by TrevorH » 2017/01/11 11:18:01

Did you read the messages? They tell you what is wrong. You have previously connected to this ip address and stored its ssh key fingerprint. Now you are connecting again and ssh is warning you that the fingerprint has changed. Either you have reinstalled the system, it's not the system you thought it was or someone has compromised your target machine and changed its ssh key.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

mayank_pasi
Posts: 21
Joined: 2016/12/25 16:04:05

Re: Arter reboot sshd service is stop??

Post by mayank_pasi » 2017/01/11 12:17:44

command is not working

[root@localhost /]# systemctl enable sshd.service
bash: systemctl: command not found

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Arter reboot sshd service is stop??

Post by TrevorH » 2017/01/11 12:34:21

There is no systemctl command on CentOS 6.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

mayank_pasi
Posts: 21
Joined: 2016/12/25 16:04:05

Re: Arter reboot sshd service is stop??

Post by mayank_pasi » 2017/01/11 12:43:03

this is Wright by mghe

see post by mghe upper post

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Arter reboot sshd service is stop??

Post by TrevorH » 2017/01/11 13:01:26

The command still won't exist on CentOS 6.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

mghe
Posts: 766
Joined: 2015/11/24 12:04:43
Location: Katowice, Poland

Re: Arter reboot sshd service is stop??

Post by mghe » 2017/01/11 14:25:24

mayank_pasi wrote:command is not working

[root@localhost /]# systemctl enable sshd.service
bash: systemctl: command not found

Sorry, it should be :

For check services runlevel
# chkconfig --list

For set sshd servces run during start system
# chkconfig --level 3 sshd on

Whoever
Posts: 1357
Joined: 2013/09/06 03:12:10

Re: Arter reboot sshd service is stop??

Post by Whoever » 2017/01/12 02:41:45

mghe wrote: For set sshd servces run during start system
# chkconfig --level 3 sshd on
This may or may not work. You should allow for other runlevels:

Code: Select all

# chkconfig sshd on
In the case of sshd, this will turn it on for runlevels 2, 3, 4 and 5

Post Reply