server not accessible

Latest response

Hi, since this morning I can't connect to the machine registered with the name X, as I keep losing the sftp and ssh connection, I also noticed that by accessing the machine console instead of showing me [user @ hostname] # after having logged in, it shows me -bash-4.2 # as attached and trying a simple command like cd / var / log it doesn't show me anything.

the web server on the machine is accessible from the browser but is not updated and I want to retrieve the content before formatting or deleting the machine.

Thank you


Hi Ibrahim Ali,

We recommend removing the hostname from this very public discussion area.

If you want your "shell prompt" to show the user, hostname and current working directory, see this Red Hat solution.

You will need to add the resulting line you borrow from that solution into each user's ~/.bashrc file

Let us know if we can assist further,

Kind Regards,

Ibrahim Ali,

There are a number of things that could cause losing an sftp or ssh connection. If you ssh to the system, maybe consider using "tmux" or "screen" so that if you lose the ssh session, you will be able to use "tmux attach" (if you established a tmux session).

"tmux" is a way to retain your session if your network connection gets interrupted.

However, there maybe another possibility, some systems are configured to automatically log someone out after a period of time. I'm not certain if that is what you are facing. Some configure specific directives in /etc/ssh/sshd_config to automatically disconnect someone's session after a defined period of time.

Kind Regards,