I am using Vertica backup script /opt/vertica/bin/vbr.py.
Unfortunately it fails when it tries to connect to the host via ssh on default 22 port.
The problem is that we use on our server 222 port. I have changed that in the backup .ini file by adding following setting:
[Transmission]
encrypt= False
port_ssh_backup = 222
Unfortunately script still uses port 22:
preparing on host 127.0.0.1...
ssh: connect to host 127.0.0.1 port 22: Connection refused
Unable to ssh to host: 127.0.0.1
backup failed!
How to overwrite default port? I use 7.1.1 Vertica version
Unfortunately that option doesn't work with 7.1.1. I had to define that port in Python backup script: /opt/vertica/bin/vbr.py
Related
I have connected to the server and I am root user,but my command failed
scp -p 10010 ~/Desktop/usb.sh root#localhost:/
Error:
ssh: connect to host localhost port 22: Connection refused
You'll need a capital P (-P) to specify a port, from the man page:
scp (1):
-P port
Specifies the port to connect to on the remote host. Note that this option is written with a capital 'P', because -p is already reserved for preserving the times and modes of the file in rcp(1).
Also, ensure you user can write to the document root (/), you can always write to your home folder: (root#localhost:/root/)
Fixed command:
scp -P 10010 ~/Desktop/usb.sh root#localhost:/
I'm trying to establish a remote port forwarding to my Mac (target 4004) via a bastion host and Server-A to a Port (1555) on Server B.
So the whole connection is:
Mac:4004 => Bastion:22 => A:22 => B:1555
And the target is my Mac should have a Port 4004 forwarded from B:1555.
What is working so far?
I can connect to Server A with the command ssh user-bastion#user-A#server-A#server-bastion
On Server A I can establish a connection e.g. telnet to B:1555
On my windows client I can remote forward the port B:1555 to my local machine via Putty.
I'm now looking for the ssh command to establish this connection on my Mac.
Commands I tried:
Of course I have already searched for it and I've already tried different versions.
e.g.
ssh -fNT -R 1555:localhost:4004 -J user-bastion#user-A#server-A#server-bastion server-B
ssh -N user-bastion#user-A#server-A#server-bastion -R server-B:1555:localhost:4004
I always receive message like "Warning: remote port forwarding failed for listen port 1555"
VSCode Version: 1.40.0
Local OS Version: Windows 10
Remote OS Version: CentOS 7
Remote Extension/Connection Type: SSH
Steps to Reproduce:
Use SSH to connect host with non-22 port and declare it in ssh_config, then start connecting
Host refused with error message being "ssh connect ot host XXX.XXX.XX.XX port 22: Connection refused"
I think this message indicates that ssh use port 22 to connect host. But, I have changed it in configure file.
I'm setting up to run some parallel jobs using MPICH 3.2 and I tried to test the configuration (3 Nodes, named Ruby, Sapphire and Onyx (Master)) using the example program cpi provided with the installation. When I tried to run the job I the following error:
ssh: connect to host Ruby_Slave port 22: No route to host
Host key verification failed.
Ruby is running ssh on a non-standard ssh port, which I think might be the problem. Is there any way to specify the port used for ssh in MPI?
Edit1:
Host Sapphire
HostName 10.42.43.11
Port 22
PasswordAuthentication no
EnableSSHKeysign yes
RSAAuthentication yes
PubkeyAuthentication yes
To my knowledge, you can't specify the port used for SSH in MPI.
You can however tell SSH which port to use, on a machine by machine basis, in .ssh/config. The user configuration file is (usually) located in ~/.ssh/config and the system-wide configuration file is located in /etc/ssh/ssh_config.
Here's an example configuration:
Host 192.168.0.101
Port 5101
Host 192.168.0.102
Port 5102
Also take a look at man ssh_config.
I set up SSH on my Ubuntu server (running XMonad) and generated a key for my laptop that I used to connect to my home server with. I also went on my wireless router and forward port 22 for SSH use. I can SSH fine when I'm at home using the standard:
ssh user#ipaddress
However when I'm outside of my local network I get this error:
ssh: connect to host xxx.xx.xx.xxx port 22: Connection refused
Everything I read says I need to either a) check that my port 22 is forward (which it is) or b) check that sshd is actually running on my Ubuntu server (which it is).
Any ideas what is preventing my SSH from working when I'm remote?
Add the following line your ssh user config file if it doesn't exits You can create the config file as shown below.
vi ~/.ssh/config
Host *
ServerAliveInterval 300
Change the permission as below:
chmod 600 ~/.ssh/config
Restart the daemon. Hope this helps.
https://serverfault.com/a/371563/617303
For me this was the cause.
In your /etc/ssh/sshd_config or /etc/ssh_ssh_config check to make sure GSSAPI Auth is disabled (set to no).
GSSAPIAuthentication no
Then restart the service or machine.