Skip to content
Advertisement

Tag: ssh

SSH Tunnel to a machine on another network [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers. This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question

bash list postgresql databases over ssh connection

I am doing some work on a remote Postgresql database. When I log into the server this command works on bash: $ psql -c “l” Remote login over ssh is possible using: But why doesn’t it work from this command? This is working, also “psql -l” but I don’t understand why I have to use backslash 3 times here? Answer

Multi Hop, Self Closing, Background SSH Tunnel

I’m trying to create a multi hop ssh tunnel, that is in the background, and self closing. What I have is… This successfully creates a multi hop ssh tunnel that closes the port on host1 after I close the tunnel. However, if I try to fork it to the background, like this… It runs in the background, but killing the

Paramiko return code127 against command that actually exist

During automating SSH routine using paramiko to linux pc, I am encountering an issue where for the existing command, I am not able to execute it successfully as “command not found” 127 response code is received on command execution. I have tried all sort of ways exec_command(), crosschecking manually (the command work fine), change directory to the path of command

No activity on server with logging every 5 seconds

Recently I have notices that log files on my server grow faster than I was expecting. After a quick look I have realized that it is wtmp what aggressively is taking my disk space. Using utmpdump command (see below) I found out that every 5 seconds new 3 or 4 logs are recorded. There is no load on the server:

How to setup a ssh connection to connect only via the localhost

We have a Linux Server with 2 users user1 and user2. We have to login from user1 to user2 via ssh such as: Both users are on the same server. However, user1 is an automated script where we cant type in manually the password and we dont want to store the password. Therefore, we want to use an ssh key

How to ssh.invoke_shell() work under Linux

The problem is that in theory the var channel_data must have and print This: Inted of that, it print this: The host “xxxx@yyyyy~$” it never appeared, so the part of the code when I asked for: It never happened. The only difference from this, to the paramiko librarie example I saw, was that the code work on Windows. So the

localhost refuses access on port during Docker tutorial

I’m currently getting started with Docker on a Linux VM provided by my university. To get started with docker I’m doing their tutorial (https://docs.docker.com/get-started/part2/#run-the-app). After creating the files the tutorial says to use the command: docker run -p 4000:80 <name of container> This should host the container on http://localhost:4000 because port 80 is mapped to 4000. But unfortunately when I

Bash poweroff script hangs system

My intention is to cycle through my list of ips and poweroff if my ping succeeds first. However the systems seems to hang. After running this script I can’t ping the systems anymore and they aren’t powered off. If I run ssh 192.168.1.ip “sudo poweroff” through terminal I dont encounter this issue. Any advice? After running a single ssh 192.168.1.40

Not able to execute a .csh script using jsch library – Exit 1

Im trying to use Jsch to execute a .csh script on a remote server. I am able to execute commands like cp, mv and ls. But when I try to execute a script that internally references some environment variables, the script is exiting with status 1. There is an INTERNAL_ENV_VARIABLE referenced inside script.sh that is not accessible when i run

Advertisement