473,325 Members | 2,792 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

Plink error

My script is simple:

Expand|Select|Wrap|Line Numbers
  1.  
  2.  #!/usr/bin/perl
  3.  
  4.  `plink alcatel@50.1.1.10 -pw alcatel ls /usr`;
  5.  

The error message is:
Unable to open connection:
Name or service not known
Sep 26 '08 #1
6 3566
Icecrack
174 Expert 100+
First off please use code tags,

Second thats not related to perl, unless it works in Shell for *nix.

also why is ls should'nt you be piping /usr in there??

eg.

Expand|Select|Wrap|Line Numbers
  1.  Plinx XXXXXXXXXXX xxxxx@xxx || ls /usr
Sep 26 '08 #2
But when iexecute this command in prompt line, it works.

In perl script , if i put this command between `'s, it must execute this command.
Sep 26 '08 #3
Icecrack
174 Expert 100+
ok,


try

Expand|Select|Wrap|Line Numbers
  1. system(`plink alcatel@50.1.1.10 -pw alcatel ls /usr`);
Sep 26 '08 #4
It's OK now, but not with `'s with 's :-)

One more question,

system('mail ahmet@gmail.com -s "trial" "trial"');

when i write this the script hangs on.
Sep 26 '08 #5
Icecrack
174 Expert 100+
almost for got to get more detail, it may hang but thats because we didnt end it if it had errors.



try

Expand|Select|Wrap|Line Numbers
  1. system('mail ahmet@gmail.com -s "trial" "trial"') || die "Error: $!";


and please put all your code in code tags
Sep 26 '08 #6
sorry, ill do it nex time,

thanks for your help.
Sep 26 '08 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

13
by: deko | last post by:
I use this convention frequently: Exit_Here: Exit Sub HandleErr: Select Case Err.Number Case 3163 Resume Next Case 3376 Resume Next
7
by: p | last post by:
WE had a Crystal 8 WebApp using vs 2002 which we upgraded to VS2003. I also have Crystal 9 pro on my development machine. The web app runs fine on my dev machine but am having problems deploying....
2
by: Al | last post by:
I'm currently attempting to use PLink (the console component of PUTTY - see http://www.chiark.greenend.org.uk/~sgtatham/putty/) as a Telnet component as I may in future need to change to using SSH...
2
by: Rennie7676 | last post by:
Hi, I'm trying to write VC++ code for using Plink (command-line tool of PuTTY) interactively from within my program which is a console type windows application. The basic purpose is to run...
10
by: Justin | last post by:
We have a simple shell script called testsp.sh (located at /home/ userid) Within the shell script, the following command is called: db2 -tvf callsp.sql When the shell script is run in command...
1
by: paafio | last post by:
Hi I'm using ActivePython 2.5 on Mac OS X. I would like to know if there is a way to call PLINK--the Genome Wide Association software-- from Python
2
by: sowm18 | last post by:
Hi, Here iam developing the .exe file for the Distribution and Deployment in other windows machines where TCL and SSH client is not installed. I had written a script in TCL to automate SSH Login...
2
hyperpau
by: hyperpau | last post by:
Before anything else, I am not a very technical expert when it comes to VBA coding. I learned most of what I know by the excellent Access/VBA forum from bytes.com (formerly thescripts.com). Ergo, I...
0
hyperpau
by: hyperpau | last post by:
Before anything else, I am not a very technical expert when it comes to VBA coding. I learned most of what I know by the excellent Access/VBA forum from bytes.com (formerly thescripts.com). Ergo, I...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.