Running shell scripts on a remote server | Unix Linux Forums | UNIX for Dummies Questions & Answers

  Go Back    


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

Running shell scripts on a remote server

UNIX for Dummies Questions & Answers


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 07-22-2003
pepintheshort pepintheshort is offline
Registered User
 
Join Date: Jul 2003
Last Activity: 12 April 2004, 9:09 AM EDT
Location: Seattle
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Running shell scripts on a remote server

Hi -
I am running Mac OS X (Terminal) at my current workstation, and I would like to telnet to my local server to run a shell script. The local server is a Solaris machine (don't know the version or the type of Unix being run on it, sorry.)

The problem I have is that when I create a #!/bin/sh line, the local server doesn't recognize it . I run less on the .sh script file, so that I can see its contents and I only see the last three lines of the script.

Any suggestions for what I might be doing wrong? By the way, if it helps, the shell script file I created was made on the Mac, using BBEdit, but was saved as a Unix specific, Unix line breaks file. So, I should not be getting any "^M" character set issues with carriage returns.

Thanks for any suggestions you may have!
Sponsored Links
    #2  
Old 07-22-2003
jagannatha jagannatha is offline
Registered User
 
Join Date: Oct 2002
Last Activity: 27 July 2005, 3:35 PM EDT
Location: Auckland, NZ
Posts: 49
Thanks: 0
Thanked 0 Times in 0 Posts
A possible solution is to Telnet to the server where you wish to create the script, and use VI to create it on the server it's self.
Sponsored Links
    #3  
Old 07-22-2003
pepintheshort pepintheshort is offline
Registered User
 
Join Date: Jul 2003
Last Activity: 12 April 2004, 9:09 AM EDT
Location: Seattle
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Certainly that's a possibility. However, my script is designed to go to that server and retrieve a bunch of files. Each time I run the script, I would be retrieving different files. Its easier to somehow batch these retrievals rather than have to edit the script in VI each time I want to run it. I would like to use Perl, ideally, but I just don't understand it well enough.
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Running for loop on remote server sexyTrojan Shell Programming and Scripting 6 03-14-2010 03:13 AM
Execute scripts on remote server m_kapur83 Shell Programming and Scripting 1 01-26-2010 06:00 AM
Script to connect to a remote server and execute scripts sgbhat Shell Programming and Scripting 5 09-02-2009 05:53 AM
Running command on Remote server sanjay1979 Solaris 1 06-07-2008 04:59 PM
Running a Script in a Remote server ZeroGPX Shell Programming and Scripting 2 03-07-2008 07:07 PM



All times are GMT -4. The time now is 04:01 AM.