How could I debug sshd taking several minutes to start?
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
I use a VM with ssh and X forwarding to run certain applications. When launching the VirtualBox VM, it takes several minutes for ssh to come online, even though the machine is at the desktop environment's login prompt in no time. The machine does not use a lot of resources (CPU, network) while sshd is starting.
Other things that might need to understand the issue:
- The host is a Debian Buster (testing) system running
OpenSSH_7.9p1 Debian-1, OpenSSL 1.1.1 11 Sep 2018
- When I log in on the desktop environment, it also takes a bit, but usually not multiple minutes. It accepts my login (or tells me I typo'd) immediately and switches to a blank screen, but takes a while to show the actual desktop.
- Once the desktop is shown and I can start to debug the issue, the issue has disappeared: sshd invariably works when the desktop environment has loaded. They both seem to block on the same thing.
- While sshd is not yet up, the system responds with "connection refused", i.e. it can reach the host and port, but sshd seems not to have bound to it.
- I can also ping the host, immediately from the moment the boot screen changes to the desktop environment's login prompt. The system seems fully ready, except sshd does not start (or bind to the interface).
Switching to a virtual terminal does not work because it switches to a virtual terminal of my host system, even if set the keyboard to be captured. I could prevent the desktop env from booting and get a terminal immediately, but I only have a short amount of time (2-3 minutes I'd say) so I would have to reboot after every few commands or know where to look in order to figure it out.
How could I debug this issue effectively? Is there a likely cause that I could check?
networking boot virtualbox openssh sshd
add a comment |
up vote
0
down vote
favorite
I use a VM with ssh and X forwarding to run certain applications. When launching the VirtualBox VM, it takes several minutes for ssh to come online, even though the machine is at the desktop environment's login prompt in no time. The machine does not use a lot of resources (CPU, network) while sshd is starting.
Other things that might need to understand the issue:
- The host is a Debian Buster (testing) system running
OpenSSH_7.9p1 Debian-1, OpenSSL 1.1.1 11 Sep 2018
- When I log in on the desktop environment, it also takes a bit, but usually not multiple minutes. It accepts my login (or tells me I typo'd) immediately and switches to a blank screen, but takes a while to show the actual desktop.
- Once the desktop is shown and I can start to debug the issue, the issue has disappeared: sshd invariably works when the desktop environment has loaded. They both seem to block on the same thing.
- While sshd is not yet up, the system responds with "connection refused", i.e. it can reach the host and port, but sshd seems not to have bound to it.
- I can also ping the host, immediately from the moment the boot screen changes to the desktop environment's login prompt. The system seems fully ready, except sshd does not start (or bind to the interface).
Switching to a virtual terminal does not work because it switches to a virtual terminal of my host system, even if set the keyboard to be captured. I could prevent the desktop env from booting and get a terminal immediately, but I only have a short amount of time (2-3 minutes I'd say) so I would have to reboot after every few commands or know where to look in order to figure it out.
How could I debug this issue effectively? Is there a likely cause that I could check?
networking boot virtualbox openssh sshd
maybe dns resolve error.
– Ipor Sircer
Nov 22 at 9:29
@IporSircer I was thinking DNS might be it, but what could I do to fix it? Resolvconf seems to work correctly as, after booting, dns works fine.
– Luc
Nov 22 at 9:50
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I use a VM with ssh and X forwarding to run certain applications. When launching the VirtualBox VM, it takes several minutes for ssh to come online, even though the machine is at the desktop environment's login prompt in no time. The machine does not use a lot of resources (CPU, network) while sshd is starting.
Other things that might need to understand the issue:
- The host is a Debian Buster (testing) system running
OpenSSH_7.9p1 Debian-1, OpenSSL 1.1.1 11 Sep 2018
- When I log in on the desktop environment, it also takes a bit, but usually not multiple minutes. It accepts my login (or tells me I typo'd) immediately and switches to a blank screen, but takes a while to show the actual desktop.
- Once the desktop is shown and I can start to debug the issue, the issue has disappeared: sshd invariably works when the desktop environment has loaded. They both seem to block on the same thing.
- While sshd is not yet up, the system responds with "connection refused", i.e. it can reach the host and port, but sshd seems not to have bound to it.
- I can also ping the host, immediately from the moment the boot screen changes to the desktop environment's login prompt. The system seems fully ready, except sshd does not start (or bind to the interface).
Switching to a virtual terminal does not work because it switches to a virtual terminal of my host system, even if set the keyboard to be captured. I could prevent the desktop env from booting and get a terminal immediately, but I only have a short amount of time (2-3 minutes I'd say) so I would have to reboot after every few commands or know where to look in order to figure it out.
How could I debug this issue effectively? Is there a likely cause that I could check?
networking boot virtualbox openssh sshd
I use a VM with ssh and X forwarding to run certain applications. When launching the VirtualBox VM, it takes several minutes for ssh to come online, even though the machine is at the desktop environment's login prompt in no time. The machine does not use a lot of resources (CPU, network) while sshd is starting.
Other things that might need to understand the issue:
- The host is a Debian Buster (testing) system running
OpenSSH_7.9p1 Debian-1, OpenSSL 1.1.1 11 Sep 2018
- When I log in on the desktop environment, it also takes a bit, but usually not multiple minutes. It accepts my login (or tells me I typo'd) immediately and switches to a blank screen, but takes a while to show the actual desktop.
- Once the desktop is shown and I can start to debug the issue, the issue has disappeared: sshd invariably works when the desktop environment has loaded. They both seem to block on the same thing.
- While sshd is not yet up, the system responds with "connection refused", i.e. it can reach the host and port, but sshd seems not to have bound to it.
- I can also ping the host, immediately from the moment the boot screen changes to the desktop environment's login prompt. The system seems fully ready, except sshd does not start (or bind to the interface).
Switching to a virtual terminal does not work because it switches to a virtual terminal of my host system, even if set the keyboard to be captured. I could prevent the desktop env from booting and get a terminal immediately, but I only have a short amount of time (2-3 minutes I'd say) so I would have to reboot after every few commands or know where to look in order to figure it out.
How could I debug this issue effectively? Is there a likely cause that I could check?
networking boot virtualbox openssh sshd
networking boot virtualbox openssh sshd
edited Nov 24 at 18:48
Rui F Ribeiro
38.3k1475126
38.3k1475126
asked Nov 22 at 9:21
Luc
883717
883717
maybe dns resolve error.
– Ipor Sircer
Nov 22 at 9:29
@IporSircer I was thinking DNS might be it, but what could I do to fix it? Resolvconf seems to work correctly as, after booting, dns works fine.
– Luc
Nov 22 at 9:50
add a comment |
maybe dns resolve error.
– Ipor Sircer
Nov 22 at 9:29
@IporSircer I was thinking DNS might be it, but what could I do to fix it? Resolvconf seems to work correctly as, after booting, dns works fine.
– Luc
Nov 22 at 9:50
maybe dns resolve error.
– Ipor Sircer
Nov 22 at 9:29
maybe dns resolve error.
– Ipor Sircer
Nov 22 at 9:29
@IporSircer I was thinking DNS might be it, but what could I do to fix it? Resolvconf seems to work correctly as, after booting, dns works fine.
– Luc
Nov 22 at 9:50
@IporSircer I was thinking DNS might be it, but what could I do to fix it? Resolvconf seems to work correctly as, after booting, dns works fine.
– Luc
Nov 22 at 9:50
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f483392%2fhow-could-i-debug-sshd-taking-several-minutes-to-start%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
maybe dns resolve error.
– Ipor Sircer
Nov 22 at 9:29
@IporSircer I was thinking DNS might be it, but what could I do to fix it? Resolvconf seems to work correctly as, after booting, dns works fine.
– Luc
Nov 22 at 9:50