Ticket #1277 (closed Feature Requests: fixed)

Opened 4 years ago

Last modified 6 months ago

Ability to remove old files

Reported by: kerryg Assigned to: gregmac
Priority: minor Milestone: 2.7
Component: Installation Version: SVN-HEAD
Keywords: Cc:
Confirmation: Unreviewed SVN Revision (if applicable):
Backend Engine: All Backend Engine Version:

Description (Last modified by diego_iastrubni)

<b>Warning</b>:  readlink(): Invalid argument in <b>/usr/src/freepbx/amp_conf/bin/retrieve_conf</b> on line <b>397</b><br />
[DEBUG-retrieve-conf] (error) /var/lib/asterisk/bin/retrieve_backup_cron_from_mysql.pl already exists, and is linked to something else!
[DEBUG-retrieve-conf] (devel-debug) /var/lib/asterisk/bin/dumpastdb.php already points to /var/www/html/admin/modules/backup/bin/dumpastdb.php - OK
<br />
<b>Warning</b>:  readlink(): Invalid argument in <b>/usr/src/freepbx/amp_conf/bin/retrieve_conf</b> on line <b>397</b><br />
[DEBUG-retrieve-conf] (error) /var/lib/asterisk/bin/ampbackup.pl already exists, and is linked to something else!

Change History

11/04/06 07:56:10 changed by ariel_

I got the same thing. So I uninstalled the backup module then did the update again it worked fine. I then via the Gui installed the backup module and it installed correctly and it's working fine.

11/04/06 08:58:20 changed by webrainstorm

In my case it hangs because it's recursively copying stuff in backup module

Here is a sample debug message I get if I ./install_amp --debug:

[DEBUG-preDB] copy amp_conf/htdocs/admin/modules/backup/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/bin/ampbackup.pl 
->
 /var/www/localhost/htdocs/admin/modules/backup/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/var/lib/asterisk/bin/ampbackup.pl

11/04/06 09:08:32 changed by webrainstorm

Ok, I had to unlink backup module dir and checkout again, now it's working goon. No more ./install_amp problems

11/04/06 12:56:51 changed by gregmac

  • owner set to gregmac.
  • priority changed from 5 to 1.
  • type changed from Bugs to Feature Requests.
  • summary changed from Error on install_amp to Ability to remove old files.

Removed the PHP errors in r2992

However, I think this is still an issue.. since this was previously included in core, we need a way to remove it.

Suggested removal technique:

I suggest we have a list of files to be removed (eg, upgrades/2.2.0/remove_files.list). Using the same technique as copy_recursive() (in install_amp), if the existing file's md5sum doesn't match the md5sum of the previous release, then it should prompt ("This file should be deleted, however there are modifications..."). This is a pretty critical change, so need some feedback on it before implementation.

11/04/06 16:46:01 changed by RobThomas

  • status changed from new to closed.
  • resolution set to invalid.

See source:/freepbx/trunk/upgrades/2.2.0beta1/ampbackup.php -- I guess people got out of the habit of doing a --force-version=a.previous.version when they're doing ./install_amp

I didn't, however, check the MD5. Do you think it's needed?

--Rob

11/04/06 23:12:59 changed by gregmac

  • priority changed from 1 to 5.
  • status changed from closed to reopened.
  • resolution deleted.
  • milestone changed from 2.2 to 2.3.

Yes, it would probably be a good thing to check md5. Perhaps not important for these files, but in general it would be good to have support for deleting files.

11/13/06 10:34:23 changed by p_lindheimer

  • version changed from 2.2 branch to SVN-HEAD.

moving this to svn head since the milestone has been changed to 2.3 branch.

01/08/07 11:46:49 changed by

  • milestone deleted.

Milestone 2.3 deleted

01/08/07 12:12:14 changed by vgster

  • milestone set to 2.3.

04/16/07 20:39:39 changed by diego_iastrubni

  • description changed.
  • svn_rev changed.
  • engine_version changed.

(changed formatting of the original post, easier to read)

02/27/10 15:14:53 changed by p_lindheimer

  • status changed from reopened to closed.
  • confirmation set to Unreviewed.
  • resolution set to fixed.
  • milestone changed from 2.8 to 2.7.

I'm pretty sure we've modified retrieve_conf and Module Admin to remove links and files that no longer exist. I'm closing this as fixed. If there are cases where this has not been done, please open a new ticket with explicit information.