08-02-2014
Try reducing the sleep periods to 1 sec, and add a sleep after the exit command.
This User Gave Thanks to RudiC For This Post:
10 More Discussions You Might Find Interesting
1. IP Networking
Hi,
I am having a problem with our AIX 4.3.3 Server accessing FTP. The error is " Connection Closed By Remote Host".
Scenario:
Since i put a default gateway on the server FTP connection is having a problem but when i remove the default gateway it will works fine..
Is there any way not... (1 Reply)
Discussion started by: mouglybean
1 Replies
2. Shell Programming and Scripting
hi
i am trying to connect the frontend server using ssh
i got the following error
ssh_exchange_identification: Connection closed by remote host
can anyone help please (1 Reply)
Discussion started by: Satyak
1 Replies
3. Linux
Dear All,
Recently our server has been giving the error:
"ssh_ exchange-identification: Connection closed by remote host"
The error causes the server to become in accessible via ssh and the services are stopped/hung. The server has to be restarted to make it working normal again.
The... (3 Replies)
Discussion started by: vguleria
3 Replies
4. UNIX for Dummies Questions & Answers
Hi Everyone,
Good day.
Scenario:
2 unix servers -- A (SunOS) and B (AIX)
I have an ftp script to sftp 30 files from A to B which happen almost instantaneously i.e 30 sftp's happen at the same time.
Some of these sftp's fail with the following error:
ssh_exchange_identification: Connection... (1 Reply)
Discussion started by: jeevan_fimare
1 Replies
5. Shell Programming and Scripting
How do I gain control of the "Connection closed by foreign host" message telnet yields when you connect to it in a shell script? I'm using the output:
#!/usr/local/bin/bash
count=$(ping -c 1 $1 | grep 'received' | awk -F',' '{ print $2 }' | awk '{ print $1 }')
if ; then
echo "$1 PING "... (2 Replies)
Discussion started by: phpfreak
2 Replies
6. HP-UX
I am trying to connect to my HP server from remote machine.
It gets connected but once credential are provided the connection is closed.
adroit:/home/seo/hitendra 32 ] telnet myserv1
Trying...
Connected to myserv1.
Escape character is '^]'.
Local flow control on
Telnet TERMINAL-SPEED... (4 Replies)
Discussion started by: hiten.r.chauhan
4 Replies
7. Solaris
Version Details
Solaris version : Oracle Solaris 10 8/11 s10x_u10wos_17b X86
$ uname -a
SunOS tippy178 5.10 Generic_147441-01 i86pc i386 i86pcThe Issue
+++++++++
I have two solaris 10 Virtual Machines created using Virtual Box. One of my applications running on Source was trying to connect... (9 Replies)
Discussion started by: kraljic
9 Replies
8. Red Hat
Hi All,
I am new to Redhat Enterprise Linux 6 version. I am facing an issue with my lab server which is having RHEL6
lab1:root> uname -a
Linux lab1 2.6.32-358.18.1.el6.x86_64 #1 SMP Fri Aug 2 17:04:38 EDT 2013 x86_64 x86_64 x86_64 GNU/Linux
I am getting this error for every 18 minutes 30... (0 Replies)
Discussion started by: go2suresh1979
0 Replies
9. Shell Programming and Scripting
In program, I want to telnet the ports present in telnet.txt file and capture screenshot of open port which is opened on new terminal.
Problems:
Escape character is '^]' and Connection closed by foreign host.
Loop is not working properly. It only take one ports and closed the connection.
... (9 Replies)
Discussion started by: sk151993
9 Replies
10. UNIX for Beginners Questions & Answers
Hello,
I'm trying to learn and automate some tasks via a script, but my first ever script failed with "connection closed by foreign host" error. I checked the other discussions but it didn't help. Could you please help?
#!/bin/bash
( sleep 2
echo open x.x.x.x 23
sleep 2
echo user
sleep 2... (1 Reply)
Discussion started by: Myrtle
1 Replies
LEARN ABOUT CENTOS
systemd-suspend.service
SYSTEMD-SUSPEND.SERVICE(8) systemd-suspend.service SYSTEMD-SUSPEND.SERVICE(8)
NAME
systemd-suspend.service, systemd-hibernate.service, systemd-hybrid-sleep.service, systemd-sleep - System sleep state logic
SYNOPSIS
systemd-suspend.service
systemd-hibernate.service
systemd-hybrid-sleep.service
/usr/lib/systemd/systemd-sleep
DESCRIPTION
systemd-suspend.service is a system service that is pulled in by suspend.target and is responsible for the actual system suspend.
Similarly, systemd-hibernate.service is pulled in by hibernate.target to execute the actual hibernation. Finally,
systemd-hybrid-sleep.service is pulled in by hybrid-sleep.target to execute hybrid hibernation with system suspend.
Immediately before entering system suspend and/or hibernation systemd-suspend.service (and the other mentioned units, respectively) will
run all executables in /usr/lib/systemd/system-sleep/ and pass two arguments to them. The first argument will be "pre", the second either
"suspend", "hibernate", or "hybrid-sleep" depending on the chosen action. Immediately after leaving system suspend and/or hibernation the
same executables are run, but the first argument is now "post". All executables in this directory are executed in parallel, and execution
of the action is not continued until all executables have finished.
Note that scripts or binaries dropped in /usr/lib/systemd/system-sleep/ are intended for local use only and should be considered hacks. If
applications want to be notified of system suspend/hibernation and resume, there are much nicer interfaces available.
Note that systemd-suspend.service, systemd-hibernate.service, and systemd-hybrid-sleep.service should never be executed directly. Instead,
trigger system sleep states with a command such as "systemctl suspend" or similar.
Internally, this service will echo a string like "mem" into /sys/power/state, to trigger the actual system suspend. What exactly is written
where can be configured in the "[Sleep]" section of /etc/systemd/sleep.conf. See systemd-sleep.conf(5).
OPTIONS
systemd-sleep understands the following commands:
-h, --help
Print a short help text and exit.
--version
Print the systemd version identifier and exit.
suspend, hibernate, hybrid-sleep
Suspend, hibernate, or put the system to hybrid sleep.
SEE ALSO
systemd-sleep.conf(5), systemd(1), systemctl(1), systemd.special(7), systemd-halt.service(8)
systemd 208 SYSTEMD-SUSPEND.SERVICE(8)