Fedora Linux Support Community & Resources Center
  #1  
Old 14th April 2012, 02:32 AM
maxleifermann Offline
Registered User
 
Join Date: Apr 2012
Location: Mountain View, CA, USA
Posts: 3
linuxfirefox
trouble with "at" utility

Hi,

I am having some trouble with the "at" utility. I am using Fedora 12 running in VMWare Player.

I created a file at /home/bagside/Downloads/espeak-alarm.sh containing this:

#!/bin/bash
espeak "hello"
echo "hello"

I changed the permissions to read, write, execute:

chmod 777 espeak-alarm.sh

then I tried to use the "at" command:

at -f /home/bagside/Downloads/espeak-alarm.sh 18:27 today

the time was 18:26:38: when I entered the at command:
date
Fri Apr 13 18:26:38 PDT 2012

but nothing happened at 18:27, neither a sound or the echoed "hello".

the script espeak-alarm works when executed from the shell and the word "hello" is spoken.

I have tried many permutations of the at command, using different time formats, also I have read the man pages and searched on Google for an answer, but to no avail! Please help if you can see what I am doing wrong, thank you in advance!

-- Max
Reply With Quote
  #2  
Old 14th April 2012, 03:12 AM
bob Offline
Administrator (yeah, back again)
 
Join Date: Jul 2004
Location: Colton, NY; Junction of Heaven & Earth (also Routes 56 & 68).
Age: 68
Posts: 22,082
linuxfirefox
Re: trouble with "at" utility

Moved to EOL
__________________
Linux & Beer - That TOTALLY Computes!
Registered Linux User #362651


Don't use any of my solutions on working computers or near small children.
Reply With Quote
  #3  
Old 14th April 2012, 03:23 AM
jpollard Online
Registered User
 
Join Date: Aug 2009
Location: Waldorf, Maryland
Posts: 6,772
linuxfirefox
Re: trouble with "at" utility

The environment of the commands executing in the "at" job is not the same as the environment of a user login at the console. The espeak should have generated an error message as it does not have access to the audio.

It should also happen if you opened a ssh session to your system and tried to run it from a remote host.
Reply With Quote
  #4  
Old 14th April 2012, 03:36 AM
maxleifermann Offline
Registered User
 
Join Date: Apr 2012
Location: Mountain View, CA, USA
Posts: 3
linuxfirefox
Re: trouble with "at" utility

Thank you for your reply, but I don't understand why the "echo 'hello'" part of the espeak-alarm.sh script did not execute?
Reply With Quote
  #5  
Old 14th April 2012, 03:38 AM
marko Offline
Registered User
 
Join Date: Jun 2004
Location: Laurel, MD USA
Posts: 5,997
linuxfirefox
Re: trouble with "at" utility

You can check the environment of the 'at' job by doing your 'at' command
Quote:
at -f /home/bagside/Downloads/espeak-alarm.sh 22:40 today
then do this to get the listing of queued at jobs:

1) get the job number via "at -l", it's the integer at the far left
Quote:
at -l
5 Fri Apr 13 22:40:00 2012 a bagside
2) use that job number you got from step 1 to see the at job itself with the -c flag:
Quote:
at -c 5
This should show the entire at job, look at the PATH and other details of the job to make sure they look correct
Reply With Quote
  #6  
Old 14th April 2012, 05:37 AM
maxleifermann Offline
Registered User
 
Join Date: Apr 2012
Location: Mountain View, CA, USA
Posts: 3
linuxfirefox
Re: trouble with "at" utility

Thanks Marco! I did as you suggested and looked at the PATH variable, it said USERNAME was "bagside" not root (which I was logged in as). So I changed user in my shell to "bagside" and ran the "at" command with the "espeak-alarm.sh" as the command to execute again-- and it worked! Thank you for your help!

--Max
Reply With Quote
Reply

Tags
trouble, utility

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
unpredictable "delete" "move to trash" or "cut" file menu option dorianrenato Using Fedora 1 21st November 2011 03:09 AM
Problem running "crash" command/utility AlFrugal Using Fedora 1 12th October 2008 12:17 PM
about the"Vanity webcam utility" error message roskoo Hardware & Laptops 2 16th December 2005 03:16 PM
Please explain a little about "up2date" utility in FC3 A6quattro EOL (End Of Life) Versions 4 21st July 2005 03:47 AM
Error:visibility arg must be one of "default", "hidden", "protected" or "internal" wangfeng Using Fedora 0 23rd May 2005 04:59 AM


Current GMT-time: 10:39 (Thursday, 24-07-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat