Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

osTicket v1.10 (stable) and Maintenance Release v1.9.15 are now available! Go get it now

osticket does not fetch eMails

Hello,
i checked the settings from the other posting "Can't get POP3 fetch to work".
I checked everything, but i can not receive an eMails in the Ticket Area of the Staff Panel.???
Account datas are also correct, but it seems, that osticket will not fetch them from the server. When i try to manual make /api/cron.php via browser, i get that i have not enough rights to see the page. CHMOD is 777.
Has anybody an idea?

Do i need to make an cronjob on my server or is it not required when i use pop3 fetch in osticket? It is not very clear written in the installation instructions.???

Also, i can put all datas, also incorrect ones in the pop3 Account Details Form, they will be saved, no check with pop3 Account if the datas are correct???

Regards
Dirk

Comments

  • You culd enable cron to only run on staff aktivity, but i would regard to setup
    a cronjob using crontab ...
    how else could that work ?
    PHP can't just call scripts cause it should ;)

    */2 * * * * root php5-cgi /home/www/web1/html/ticketsupport/api/cron.php

    works fine with me ;)
  • können wir deutsch reden? (ISABERLIN)???
    I can not open cron.php in my browser. Not enough rights, so i think, Cronjob will also not work???
    I create cronjob with plesk and the command gives me failure:
    /bin/sh: php5-cgi: command not found

    And what does the API and Pass Phrase mean? Do i have to put something in here?

    When i browse manual the cron.php with a firefox browser, i get a white page with "77" on it ???

    Dirk
  • image
    [Same as above]

    image
    du kannst die optiion aktivieren, dass cron läuft wennjemand vom "Staff" eine aktion macht (refresh, pagewechsel etc).
    Aber am sinnvollsten ist es einen Cronjob in !crontab! einzurichten
    (also direkt im Server indem du "crontab -e" als befehl in SSH verwendest.)
    PHP kann ja net einfach ne Datei aufrufen regelmäßig nur weil es sinn ergibt.
    PHP kann viel, aber net denken ;)

    Wenn du es manuell im browser öffnest kommt ein fehler, da der apache server kein zugriff auf das emailprogramm hat !
    */2 * * * * root php5-cgi /home/www/web1/html/ticketsupport/api/cron.php

    damit läuft es bei mir super. nur den Pfad musst du natürlich anpassen (sowohl für deine PHP version als auch deine cron.php location)
  • Danke Schön!
    Now i get this message:
    Could not open input file: /srv/www/vhosts/xxx/subdomains/support/httpdocs/api/cron.php

    Naturally "xxx" replaced the domain name.
    ???
    So i can deactivate all fetch functions and pop3 User Datas in the admin Panel and use only the cronjob, when it work?

    Dirk
  • image
    [not given]

    image
    Nein.
    Im user CP muss alles drin stehen denn das ist ja blos der an aus schalter
    der funktionen die von cron.php aufgerufen werden.
    was im ACP nicht aktiviert ist wird von cron auch nicht gemacht !

    Und bei der fehlermeldung ist der pfad einfach falsch ;)
  • was meinst Du mit der Pfad ist falsch?
    Ich habe Suse 10.1-64bit drauf. Der Pfad kann ich genauso mit WinSCP verfolgen. Wie soll der Pfad denn lauten? Oder hab ich jetzt nen Knoten drin?

    Danke Dirk
  • Dirk, do you have IMAP require encrypted passwords/authentication? This was my problem!
  • i can not find that in Plesk. There is only "SMTP Authorization required" active.
    Dirk
  • Hmm, it would depend on your hosting provider then. You may need to ask them if they require encryption on their IMAP server.
  • but why IMAP? i think it is POP3? Or do i have to create an IMAP eMail Adress?
  • it uses IMAP to connect, not pop3.
  • It is a root Server, so i have full access.
    Where can i find this to check if it is activated or not?

    Thank you and Regards
    Dirk
  • /etc/c-client.cf

    I accept the risk
    set disable-plaintext nil
    You need "I accept the risk" on the first line.
  • I put the 2 lines on the top of the file.
    Still does not work! Do i have to put something in the API Section of the Admin Panel?
  • try calling the file from commandline now?

    php cron.php
  • when i do: /opt/php52/bin/php5 /srv/www/vhosts/xxx/subdomains/support/httpdocs/api/cron.php
    in shell, there is no error, but also no emails in ticket system...

    when i make: php5 /srv/www/vhosts/xxx/subdomains/support/httpdocs/api/cron.php
    i get:
    PHP Warning: Cannot load module 'SQLite' because required module 'pdo' is not loaded in Unknown on line 0

    It is crazy...

    I have no idea what the problem is:-(
    Dirk
  • and when i try to use pipe with .qmail i get failure notice email back with:
    /bin/sh: true
    : command not found
  • ISABerlin: Ich glaub mit dem Cronjob in Plesk anlegen funktioniert deshalb nicht, weil nicht die ausreichenden Rechte vorhanden sind. root kann den Cronjob nicht anlegen. Kannst DU mir sagen wie ich den Cronjob über die Shell anlegen kann?
    Danke Dirk
  • image
    [not given]

    image
    Darum sagte ich ja schon die ganze zeit :
    anlegen über den befehl "crontab -e"
    dann öffnet sich ein editor in dem du die zeile einträgst.
    dann den cronjob speichern und fertig.
  • und mit welcher Taste speicher ich?
    Wenn ich crontab -e eingebe kann ich noch nichts eingeben...
    Sorry, bin da nicht so fit.
    Danke Vielmals
    Dirk
  • Hi,

    wenn ich mal meinen Senf dazu geben darf. Speichern mit Taste ESC drücken, dann :w! oder ZZ (zweimal in Großbuchstaben). Denke es ist dann der VI Editor auf dem Server. Wäre jetzt meine Idee.

    Cu
    Jörg Peter
  • Cron-job

    Hello all,

    My "cron-hell" is this...

    /home/xx/public_html/api/cron.php: line 1: ?php: No such file or directory
    /home/xx/public_html/api/cron.php: line 2: /_rvdynamicaddon: Permission denied
    /home/xx/public_html/api/cron.php: line 3: cron.php: command not found
    /home/xx/public_html/api/cron.php: line 5: syntax error near unexpected token `('
    /home/xx/public_html/api/cron.php: line 5: ` File to handle cron job calls (local and remote).'

    I have no own webserver so I have a rented one where I can run my own cron-jobs.

    As I see it my cron-jobs can only run .cgi scripts. .php is just not workin...

    any suggestions?


    regards
    Ed
  • Here's how to get out of cron job hell

    Ed,

    As you've speculated, looks like your cron is not reading php. My guess is that you need to enter the appropriate php shell path. You may want to post your cronjob entry so we can see what you have.

    Below is one way I can get an error like yours on my server:
    */5 * * * * /pathtoinstallation/support/api/cron.php


    When I use this entry I get the same error as you've posted above. The cron.php file is not being parsed as php but just as a text file. So your cron is just reading each line looking for an appropriate command.

    Below if I give the cron.php the appropriate directive, it will execute as expected:

    */5 * * * * [COLOR=\"Green\"]/usr/local/bin/php[/COLOR] /pathtoinstallation/support/api/cron.php


    In the example above, I've included the absolute path to php (highlighted in green). There are a few other ways to do this but this is pretty easy and you don't have to modify any osticket files.

    Now it's important to note that your server may have a different path for php. In that case, you can contact your host administrator for additional details.

    I hope that helps.

    Best Regards,
    sg
  • Auto cron in RC2

    For users having trouble with cron setup via api, I would recommend upgrading to RC2. Auto cron is now fixed. When enabled cron is called once every 3 minutes for each staff session. i.e staff activity spawns osTicket cron call.
Sign In or Register to comment.