APS Installer not installing packages - no error message

Discussion in 'ISPConfig 3 Priority Support' started by arraken, Mar 10, 2014.

  1. arraken

    arraken Member

    Hi!

    I just reinstalled my ispconfig master server (switched from apache to nginx). After reconnecting the slave servers, the main functions seem to work, however the APS installer does not.

    When I try to install a package, Ispconfig just instantly returns to the "installed packages" site, but doesn't actually do anything. No error message, and also no error logs (at least none that I found).

    I am suspecting a problem with the db-server (slave server). I tried manually creating a db, and it works as expected, but maybe there is some configuration that has to be updated regarding APS?

    This guy seems to have a similar problem: http://www.howtoforge.com/forums/showthread.php?t=64691&highlight=aps+installer
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Is the aps package that you want to install listed in the installed packages list after you clicked on install?
     
  3. arraken

    arraken Member

    no, there are no installed packages listed
     
  4. arraken

    arraken Member

    there is also no database created, and no files are added to the webfolder.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    If there is no package listed, then there is no install job, so nothing will get ctreated.

    I guess the problem is that your ispconfig database and the folders with the aps packages are not in sync due to your reinstall, as the aps package system relies on data in the database and data in the filesystem that it has downloaded. if one of these 2 parts is missing or not compatible with the other data, then the installer might fail.

    Have you tried to update the packagelist so that it downloads the packages again?
     
  6. arraken

    arraken Member

    I think I found the problem, and you are right - the filesystem and db are out of sync: the "/usr/local/ispconfig/server/aps_packages" folder is empty, but the table "aps_packages" has 158 entries. I manually cleared both the table and the folder, because I thought this might fix my APS-Problem.

    But apparently now, everytime I update the package list, only the table gets repopulated, and the folder stays empty.
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    The folder /usr/local/ispconfig/server/aps_packages is owend by user and group ispconfig? the ispconfig php is running as user ispconfig? The php curl module is installed?
     
  8. arraken

    arraken Member

    1. Yes, folder rights are correct
    2. How can i check if ispconfig php is running as user ispconfig?
    3. Curl php module is installed. Can I test if it is working somehow?
     
  9. arraken

    arraken Member

    Hi!

    I still can't install packages with APS installer - on none of my nginx ispconfig servers. When i set the ispconfig log level to debug, I only get the following output when I try to do an installation:

    Code:
    26.03.2014-14:01 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    26.03.2014-14:01 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    
    On my apache servers aps installer works like a charm.. Any more ideas what could be the problem?
     
  10. till

    till Super Moderator Staff Member ISPConfig Developer

    maybe the aps plugin is not enabled. Please post the output of:

    ls /usr/local/ispconfig/server/plugins-enabled/
     
  11. arraken

    arraken Member

    Hi!

    the aps plugin seems to be installed: here's the output of ls /usr/local/ispconfig/server/plugins-enabled/

    Code:
    apps_vhost_plugin.inc.php  cron_jailkit_plugin.inc.php  mysql_clientdb_plugin.inc.php    shelluser_base_plugin.inc.php
    aps_plugin.inc.php         cron_plugin.inc.php          network_settings_plugin.inc.php  shelluser_jailkit_plugin.inc.php
    backup_plugin.inc.php      ftpuser_base_plugin.inc.php  nginx_plugin.inc.php             software_update_plugin.inc.php


    But now something different happened: I added a new domain, and tried the aps-installer again. Suddenly it worked (still not working in the old domain though), but it hangs in the "installation_task" phase. Here's my ispconfig log:

    Code:
    26.03.2014-20:13 - DEBUG - Remove Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    26.03.2014-20:14 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    26.03.2014-20:14 - DEBUG - installer function entered
    26.03.2014-20:14 - DEBUG - Found 14 changes, starting update process.
    26.03.2014-20:14 - DEBUG - Calling function 'db_user_insert' from plugin 'mysql_clientdb_plugin' raised by event 'database_user_insert'.
    26.03.2014-20:14 - DEBUG - Processed datalog_id 961
    26.03.2014-20:14 - DEBUG - Calling function 'install' from plugin 'aps_plugin' raised by event 'aps_instance_insert'.
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:16 - DEBUG - There is already an instance of server.php running. Exiting.
    26.03.2014-20:16 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:16 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:16 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:16 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:16 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:16 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:17 - DEBUG - There is already an instance of server.php running. Exiting.
    26.03.2014-20:17 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:17 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    
    This goes on for around 10 minutes now. Every 10 seconds i get the message that the lockfile is already set. How can I stop it?

    EDIT: I tried to delete the lock with "rm /usr/local/ispconfig/server/temp/.ispconfig_lock", but the installer instantly started again:

    Code:
    26.03.2014-20:24 - DEBUG - Set Lock: /usr/local/ispconfig/server/temp/.ispconfig_lock
    26.03.2014-20:24 - DEBUG - installer function entered
    26.03.2014-20:24 - DEBUG - Found 13 changes, starting update process.
    26.03.2014-20:24 - DEBUG - Calling function 'install' from plugin 'aps_plugin' raised by event 'aps_instance_insert'.
    26.03.2014-20:25 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:25 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:25 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    Because of the lockfile, the /usr/local/ispconfig/server/server.sh also isn't running, which is a big problem..
     
    Last edited: Mar 26, 2014
  12. arraken

    arraken Member

    Ok, one day later, i still get the same errors in my log every 10 seconds:

    Code:
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:15 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    26.03.2014-20:16 - DEBUG - There is already an instance of server.php running. Exiting.
    26.03.2014-20:16 - DEBUG - There is already a lockfile set. Waiting another 10 seconds...
    How can I delete the stuck APS job?
     
  13. till

    till Super Moderator Staff Member ISPConfig Developer

    run:

    rm -f /usr/local/ispconfig/server/temp/.ispconfig_lock

    to remove the lockfile and then run:

    /usr/local/ispconfig/server/server.sh

    to get the debug output to see why the cronjob hang.
     
  14. arraken

    arraken Member

    Hi till,

    I already tried to delete the .ispconfig_lock. The problem is, that afterwards, the aps install function gets started again, and the problem repeats. So the problem seems to be that the aps-install job is somewhere in the queue, and never gets removed, because it never finishes.

    However, I apparently just solved the problem by removing the enty in the aps_instaces table of the ispconfig db, then deleting the .ispconfig_lock file and then runnint server.sh.

    Now I can install in all new domains without a problem! Even an old error that I got an "installation_failure" even though the installation was correct now went away. I don't really understand what happened, but oh well.. :)

    As always: thanks for the help till!
     
  15. till

    till Super Moderator Staff Member ISPConfig Developer

    In case that you get an issue again where you want to skip a transaction, then open the dbispconfig database on the master, go to the server table, select the server were you want to skip the transaction and increment the value in the "updated" column by one (or set it to the ID that you want to process from sys_datalog table).
     

Share This Page