[Solved] Have Cron Job Open Terminal Window

I want to run a ping script every morning to check the liveliness and latency of specific servers. The script itself works fine but I can't figure out how to have cron open up a terminal window so I can see the script running.
This is what I have so far:
#runs /home/bran/pingservers.sh everyday at 8:30 am
10 10 * * * env DISPLAY=:0 konsole -e ~/pingservers.sh
But it doesn't open anything I don't even know if the job is even executing.
Last edited by brando56894 (2013-05-20 14:25:42)

I am unsure how to get the script to open a terminal, but the journal should have some information on whether the script is running or not and if there are any errors.
brando56894 wrote:
I don't even think cron jobs are running at all. I changed my job to
1 * * * * /bin/echo hello world
and it hasn't done anything...
As far as the job above, I just wanted to note that you have it set to run on the first minute of every hour. If you were looking for every second minute, you would want the following:
*/1 * * * * /foo/bar
Last edited by BluMongoose (2013-05-14 22:01:48)

Similar Messages

  • Unable to Open Terminal Window

    Hello,
    I am trying to do research on how to fix my current problem of not being able to open my terminal window.  When attempting to do so I get the following error message:
    You are unauthorized to run this application.
    The administrator has set your shell to an illegal value.
    I looked at some previous posts and some people said download iterm2 and put the following command: sudo chsh -s /bin/bash my_username.  After this enter password and it should be fixed.  However when doing that I get the following response: SC is not in the sudoers file.  This incident will be reported.
    Couple of things, firstly SC (which is me) is the administrator to this computer (this is my computer and there are no other users on it). 
    Either way can anyone give some suggestions on how to solve this problem so that I am able to open the terminal window.
    Much thanks in advance for anyones assistance.
    Sami

    Create a new administrator account in which to change your shell and also fix the sudoers file, which is apparently corrupt. It should have the following content:
    # sudoers file.
    # This file MUST be edited with the 'visudo' command as root.
    # Failure to use 'visudo' may result in syntax or file permission errors
    # that prevent sudo from running.
    # See the sudoers man page for the details on how to write a sudoers file.
    # Host alias specification
    # User alias specification
    # Cmnd alias specification
    # Defaults specification
    Defaults          env_reset
    Defaults          env_keep += "BLOCKSIZE"
    Defaults          env_keep += "COLORFGBG COLORTERM"
    Defaults          env_keep += "__CF_USER_TEXT_ENCODING"
    Defaults          env_keep += "CHARSET LANG LANGUAGE LC_ALL LC_COLLATE LC_CTYPE"
    Defaults          env_keep += "LC_MESSAGES LC_MONETARY LC_NUMERIC LC_TIME"
    Defaults          env_keep += "LINES COLUMNS"
    Defaults          env_keep += "LSCOLORS"
    Defaults          env_keep += "SSH_AUTH_SOCK"
    Defaults          env_keep += "TZ"
    Defaults          env_keep += "DISPLAY XAUTHORIZATION XAUTHORITY"
    Defaults          env_keep += "EDITOR VISUAL"
    Defaults          env_keep += "HOME MAIL"
    # Runas alias specification
    # User privilege specification
    root          ALL=(ALL) ALL
    %admin          ALL=(ALL) ALL
    # Uncomment to allow people in group wheel to run all commands
    # %wheel          ALL=(ALL) ALL
    # Same thing without a password
    # %wheel          ALL=(ALL) NOPASSWD: ALL
    # Samples
    # %users  ALL=/sbin/mount /cdrom,/sbin/umount /cdrom
    # %users  localhost=/sbin/shutdown -h now

  • I can't open a silverlight dmg file-it always opens Terminal window

    Hi,  I can't open a silverlight dmg file to watch netflix.  I am running Lion on my 2.66ghz iMac i5 with 10.7.3. I can download and install silverlight but when I try to open the file, it always opens the Terminal window.  Please Help.

    It sounds like all your launch services file associations have somehow been corrupted.  I suggest your reset the launch services bake to their initial default settings.
    The easiest way for you to do this is probably to get a maintenence utility like OnyX (download the Lion version for your case).  It has, among many other things, a way to rebuild the launch services.  Launch OnyX.  It will ask for your admin password and a window like below will be dispallyed.
    As you can see from the above picture in OnyX you select Maintenance, Rebuild tab, check the LaunchServices checkbox, and click the Execute button (not shown here but it's at the bottom of the window).
    Note, the above shows the window for the Snow Leopard version of OnyX.  I don't know if the Lion version is different since I don't use Lion.

  • Sample C++ code to open terminal window ?

    Friends:
    I'm using the Command Line Utility XCode C++ tool:
    Does anyone have sample C++ code which opens the terminal window to show the products of the run? I want to include this code at the beginning of my C++ code so that the window opens automatically during the run.
    If I can set the terminal window properties that would also be appreciated, though not necessary.
    Thanks amigos,
    Migs

    Hi Migs,
    Just to perhaps explain why folks were confused by your question and maybe also clarify the answers that you've already been given...
    While you're *in the process of writing* a command-line tool within Xcode it's usually easiest to just "Build & Run" your tool totally within Xcode's environment. That's why Xcode provides it's own integrated "Console" window - so you can view the results of your tool's execution without having to leave the Xcode environment. This saves you the trouble of having to switch back and forth between Xcode and Terminal during the development process.
    However, typically, a command-line tool is ultimately intended to be run from the Unix command-line (ie Terminal.app). So *once you're finished writing and debugging your tool* you will then generally want to run your tool from Terminal (and not have to launch Xcode). You can find the final executable in the "build" folder of your Xcode project. And at this point you would typically launch Terminal and execute your tool from Terminal's command prompt. Once your tool is finished there's no need to launch Xcode every time you want to run it.
    In Terminal you would just type:
    /path/to/your/tool
    You might even want to move the final executable to a directory that's in the Terminal's $PATH so the shell could find it using only it's name without requiring the path.
    Steve

  • Problems : Starting up with CDE and Opening terminal window in JDS

    Hi
    I installed Solaris 10 GA on the system having 2.8 GHz Dual Xeon processor with EM64T.
    Installation process was fine and completed. But, I have two problems with CDE and JDS.
    Firstly, in JDS, the graphical login comes up, works fine. After I login (as root or anyone), sometimes terminal window does not start up correctly. The windows for terminal apprear, but there is no display. Thus, I cannot use the terminal in JDS, while the other menus on launch panel (e.g. StarOffice) seem to work properly.
    Secondly, in CDE, I can login, the hourglass pointer appears and changes to arrow pointer. But then, there are no items except only the pointer and wallpaper.
    Both problems do not happen at every login time. when the problems happen, I have to reboot (in CDE/JDS) or re-login (in JDS). After some rebooting or re-login, things work fine again.
    Can everybody help me?
    Thanks

    I am not Adobe staff, but I have never heard of an "online upgrade". When I purchased my CS6 upgrade  from Adobe, they sent me an email with the serial.
    Who did you go through to get this upgrade?

  • I have not checked "Open new windows in a new tab instead" but Firefox 5 keeps opening new windows in a new tab. How do I stop this?

    I do not want to use the tab feature.
    I have an iMac OS 10.6.8

    (''Note: cross posted from [https://support.mozilla.com/nl/questions/801471 here].'')
    I had the same problem, but was able to fix it somewhat.
    # Open the about:config page.
    # Set the ''browser.link.open_newwindow.restriction'' setting to 0 (= zero).
    On my machine this will open new windows in a new tab. However, it switches to the new tab regardless of the setting ''"When I open a link in new tab, switch to it immediatly"''.

  • How to have cron jobs email to an exchange server

    How do you setup a cron job so that i can send its results to an email server such as exchange?
    I want to dump the results of a cronjob and then email this results to an account on a exchange server
    please help?

    to redirect the mail message to a non priveleged account create a[b] .forward file in the / directory with a single line entry containing the user to receive the forwarded mail.
    In outlook create a new mail account using POP3.
    The mail server should be your UNIX server, might have to use the IP address rather than the host name.
    The login details should be your UNIX account and password. Dont believe the email address is important as you are only downloading mail from the server.
    This is basically the same as you do from home when dialling into your ISP and dowloading mail.
    Not sure if this is a solution as it doesnt use an exchange server but it does get your mail.
    Your mail program should be able to handle receiving emails from multiple sources ie your exchange server and a pop3 account

  • [solved]sonata won't open (terminal output inside)

    I am new to Arch, after using Ubuntu for a few months.. this is the first problem that i have run into that i can't' figure out how to fix.
    I am trying to use the mpd client "Sonata"  but it doesn't open for me.  When i do it in the terminal, i get this output:
    (sonata:16223): Gtk-WARNING **: Locale not supported by C library.
    Using the fallback 'C' locale.
    No protocol specified
    /usr/lib/python2.5/site-packages/gtk-2.0/gtk/__init__.py:72: GtkWarning: could not open display
    warnings.warn(str(e), _gtk.Warning)
    /usr/lib/python2.5/site-packages/sonata.py:7532: Warning: invalid (NULL) pointer instance
    gtk.Window.__init__(self, gtk.WINDOW_POPUP)
    /usr/lib/python2.5/site-packages/sonata.py:7532: Warning: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed
    gtk.Window.__init__(self, gtk.WINDOW_POPUP)
    Taglib and/or tagpy not found, tag editing support disabled.
    ZSI not found, fetching lyrics support disabled.
    Python 2.5 or python-elementtree not found, audioscrobbler support disabled.
    Sonata failed to connect to the D-BUS session bus: Unable to determine the address of the message bus (try 'man dbus-launch' and 'man dbus-daemon' for help)
    Traceback (most recent call last):
    File "/usr/bin/sonata", line 47, in <module>
    app = sonata.Base()
    File "/usr/lib/python2.5/site-packages/sonata.py", line 331, in __init__
    self.enc = locale.getpreferredencoding()
    File "/usr/lib/python2.5/locale.py", line 512, in getpreferredencoding
    setlocale(LC_CTYPE, "")
    File "/usr/lib/python2.5/locale.py", line 476, in setlocale
    return _setlocale(category, locale)
    locale.Error: unsupported locale setting
    i tried to search for the answer, but honestly, i don't even know what to search for in this case.  I am using KDEmod as DE and can give any other information about my system if needed. 
    can someone please try to help me out with this?
    mrcold
    Last edited by mrcold (2008-01-24 18:51:30)

    Roberth wrote:
    snozle wrote:I am having the same issue but fixing my locale doesn't seem to work (I also have dbus in my daemons in /etc/rc.conf)
    Did you start dbus? adding it to the daemons field in rc.conf only make it start up at boot.
    I've since restarted.
    [EDIT FIXED] I changed my ~/.config/openbox/autostart.sh to exclude foreign language support
    Last edited by snozle (2008-02-07 08:14:41)

  • [solved]DWM rules for opening terminal based apps

    These are the rules that I have in my dwm config.h
    The ncurses apps that open in the terminal do not follow the rules. How can accomplish this?
    static const Rule rules[] = {
    /* class instance title tags mask isfloating monitor */
    { "Gimp", NULL, NULL, 0, True, -1 },
    { "Firefox", NULL, NULL, 1 << 3, False, -1 },
    { "Pcmanfm", NULL, NULL, 1 << 1, False, -1 },
    { "ranger", NULL, NULL, 1 << 6, False, -1 },
    { "mutt", NULL, NULL, 1 << 7, False, -1 },
    { "ncmpc", NULL, NULL, 1 << 8, False, -1 },
    Last edited by derrickcope (2015-05-02 05:26:14)

    thanks for the suggestion. xprop just sees them as "terminator". When I start them with -T "title" then xprop sees them with "title".
    When I used the -T switch in .xinitrc and then changed my rules to
    static const Rule rules[] = {
    /* class instance title tags mask isfloating monitor */
    { "Gimp", NULL, NULL, 0, True, -1 },
    { "Firefox", NULL, NULL, 1 << 3, False, -1 },
    { "Pcmanfm", NULL, NULL, 1 << 1, False, -1 },
    { "ranger", NULL, "ranger", 1 << 6, False, -1 },
    { "mutt", NULL, "mutt", 1 << 7, False, 2 },
    { "ncmpc", NULL, "ncmpc", 1 << 8, False, 2 },
    They are still opening on the first monitor and not on the tag I set. I am not sure I am doing it correctly. Should I write terminator as the class?

  • I would like to open links in a new window but cannot find where to put the setting. Have unchecked the "Open new windows in new tab instead" box in the Options dialog box.

    When I click a link on a webpage or other software, I would like for it to open in a completely new window.

    You can hold the Shift key and click the left mouse button a link to open that link in a new window.
    The setting in Tools > Options > Tabs is only for links that specify a target window and you can divert such a link to a new tab instead.

  • How to have the OS open every window every time in List View?

    I tend to work in List View all the time with my windows. However when I do, for example, a search it opens in what ever View but not List View. If I than close that window, without putting it on List View, the next one opens in the same setting as the one I closed (annoying to me to say the least).
    Is it possible to set things up so it always and for ever opens in List View?
    Ta.

    Malcolm Rayfield wrote:
    Select a window, set it to List view then select "Show View Options" in Finder's "View" menu. Enable "Always open in list view" then click the "Use as Defaults" button.
    I had been trying that. First apologies, I made a mistake upstairs in the title I meant *"Column View"* sorry, grovel, grovel.
    However in list view I cannot click "Use as Defaults" as it is grayed out and in "Column View" it does not even show up.

  • How to open a terminal window in a path currently visible in the Finder?

    I often need to open a terminal window with the current visible folder (a long, deep path) as the working directory.
    In Windows I used to have the little "Open command window here..." hack available in the context menu in Explorer.
    How can I achieve the same on OS X to avoid tediously typing the path?

    open a finder window and navigate to one-level above
    this visible folder.
    open a terminal window.
    drag the folder of interest from the finder window
    into the terminal window. now you see the whole path
    to that folder has been typed out for you....
    so, if you wanted to 'cd' into that folder in
    terminal, you'd type cd, then a space, into the
    terminal window, then drag that folder in there from
    the finder, then hit return.... viola!
    If the folder you want is already open, you can drag the icon at the top of the Finder window. You don't have to go one level up.

  • Command-tab between Terminal windows

    Hi, when I have multiple Terminal windows, I want to Command tab between these windows (like I can in Windows XP). However. the MacOS is treating the Terminal windows as one application. Anyone know how I can change this behaviour?
      Windows XP Pro  

    In Mac OS X, Command-Tab cycles only through applications. If you want to cycle through the open windows of a particular application, use the keystroke Command-`. This works for all applications that use multiple windows.
    For clarity, the (`) key is just above the Tab key, i.e. the one where tilde (~) is the uppercase character. Just hold down the Command key and hit ` to cycle through open Terminal windows.

  • Some programs open new window instead of new tab in open window

    Firefox 17.0.1. I have the option "Open new windows in a new tab instead" set, I use the Tree Style Tab 0.14.2012111201 addon (and others unrelated to tabs or windows), and I have multiple profiles. It seems that since I started using multiple profiles some programs (MediaMonkey's help, for example) insist on opening a new Firefox window. If I select any of the one or more currently open profiles it says "Profile in use". Some programs that want to open an internet site to show their help files do open a tab in the current browser window, as expected and desired. But more programs cause the Choose a profile box to display.

    Make sure that you do not start Firefox with the -no-remote switch or have set the environment variable MOZ_NO_REMOTE=1 (Control Panel > System > Advanced > Environment variables).
    If you need to have more than one profile open at the same time then start subsequent instances with the -no-remote command line switch.<br />
    You can not send links from other programs to a Firefox instance that is started with the -no-remote switch.
    In such a case you need to drag links in a Firefox window or paste the link in the location bar.
    *http://kb.mozillazine.org/Opening_a_new_instance_of_Firefox_with_another_profile

  • New window will not open even when "open new window in tab" is checked

    I cannot open a new window even when i have the option "Open new window in tab" checked.
    Firefox will NOT open a new window under any circumstances.
    Also, when I quit Firefox, the system thinks that multiple instances of FF is running but they are invisible to me.

    Start Firefox in [[Safe Mode]] to check if one of the add-ons is causing the problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    * Don't make any changes on the Safe mode start window.
    See:
    * [[Troubleshooting extensions and themes]]

Maybe you are looking for

  • Notes v 10.6.2 - opens but no content, wont close

    10.6.2 on MBP syncing to iPhone regularily suddenly, Notes via Mail app open but no content in them, wont close no content means none in Preview Pane and none via 2x clicking (dialogue in Prev Pane says "Loading..." but nothing ever does ALL Notes be

  • Playlist's not in the correct order

    I've always had a last played list of all the songs I've listened to recently. Ever since the new itunes update when I update my iPods (shuffle, nano and iphone 4S) they are in alphabetical order but in the smart playlist on my computer they are in t

  • [svn] 4078: Add support for dataTips to Slider

    Revision: 4078 Author: [email protected] Date: 2008-11-11 17:41:52 -0800 (Tue, 11 Nov 2008) Log Message: Add support for dataTips to Slider SDK-16291 Implement data tip for slider - Added new dynamic, optional skin part called "dataTip". - Added data

  • Pacman signature error

    Hello, I was installing XFCE4, but my laptop died while pacman was downloading and installing the packages. Now, if I try to download any package that contains ant packages or dependencies from XFCE I get error: signature from <whoever> is invalid. I

  • Unable To Make Connection With FreeTalk Website

    I have tried to reactivate my Freetalk unit (wall plugin). There used to be an area on the freetalk site that would reset the device and always worked when I had a problem. Now I don't see that option. I've tried doing a reset on the unit and all I'm