LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 03-18-2010, 01:48 PM   #1
Mr187
LQ Newbie
 
Registered: Mar 2010
Posts: 2

Rep: Reputation: 0
corntab / file running SSH help


Well, It seems to be the file i am trying to add to the corntab works fine, I mean like if i go on SSH and do for an example
Quote:
cd /opt/server/
Now i am at the folder of my "server".
If i type in SSH
Quote:
sh /opt/server/checkonline.sh
it works, and checks if its online or not.

now if i just open ssh fresh and try to do
Quote:
sh /opt/server/checkonline.sh
it just won't reply anything, which other way it does.

and when ever i try to add it to the corntab like such
Quote:
1 * * * * /opt/server/checkonline.sh >/dev/null 2>&1
It doesn't work, comes up wit error "E486: Pattern not found" etc, Can somebody please help and sorry for the "newbie" question..

Last edited by Mr187; 03-18-2010 at 01:49 PM.
 
Old 03-18-2010, 03:20 PM   #2
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,824

Rep: Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615
Post the contents of checkonline.sh. Use [code] tags.
 
Old 03-18-2010, 04:23 PM   #3
Bratmon
Member
 
Registered: Jul 2009
Location: 75.126.162.205:80
Distribution: Arch / Mint 17
Posts: 297
Blog Entries: 3

Rep: Reputation: 50
Corntab? Best misspelling ever.
 
Old 03-18-2010, 04:51 PM   #4
Mr187
LQ Newbie
 
Registered: Mar 2010
Posts: 2

Original Poster
Rep: Reputation: 0
Sorry mean Cron Job, Not really knowing what they mean or understand just got into linux yesterday.

And checkonline.sh is working fine, its just the fact that it won't add to cron job, and if i try to link to it at normal SSH right away at cd ~ it just doesn't say anything but if i do go to the folder its in, it works and textes me back "Server is Working" etc.
 
Old 03-18-2010, 06:10 PM   #5
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,824

Rep: Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615
Post the contents of checkonline.sh. Use [code] tags.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
running file from root and running file from user kedar Linux - Newbie 2 09-16-2008 01:59 AM
file time stamp is wrong with ssh file transfer cy163 Linux - Newbie 8 05-18-2008 01:40 AM
Do I need ssh running? reesee Linux - Security 7 01-02-2006 10:01 PM
running ssh connection into batch file jdonaldogg General 1 12-17-2005 10:25 PM
Running X through SSH cdakin Linux - Newbie 0 04-23-2002 08:40 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:13 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration