Results 1 to 5 of 5

Thread: Silent Upgrade: ERROR: directory not writable

  1. #1
    eggsurplus's Avatar
    eggsurplus is offline Sugar Community Member
    Join Date
    Dec 2005
    Location
    Minnesota
    Posts
    2,343

    Default Silent Upgrade: ERROR: directory not writable

    I've tried to find a solution for the past few days and I know it's an environment issue but I'm not finding a solution. Hopefully someone else has either had the same issue or knows of a possible solution.

    Running:
    Windows 2000
    Apache 2.2 as part of the XAMPP stack
    Sugar 4.5.1e

    If upgrading using the Upgrade Wizard I get the following error:
    Error: PCLZIP_ERR_MISSING_FILE (-4) : Missing archive file ''

    If upgrading using the silent installer (using DOS as an admin user of the box):
    *** ERROR: directory not writable: c:/xampp/xampp/htdocs/sugar_upgrade/cache/upload/upgrades/patch/SugarCE-Upgrade-4.5.1-to-5.0.0b-restore

    If I run the installer the system check returns:
    Writable Cache Sub-Directories OK

    Apache is ran as the SYSTEM user which is set to Full Control. Disk is NTFS.

    The Sugar instance is a zipped copy from a live production which was moved to this test server and unzipped. This may have something to do with it. Maybe not. I did run "attrib -R -A /S /D" against the sugar instance to unset any read only or archive flags.

    Anything that I could have overlooked?

    Thanks

  2. #2
    eggsurplus's Avatar
    eggsurplus is offline Sugar Community Member
    Join Date
    Dec 2005
    Location
    Minnesota
    Posts
    2,343

    Default Re: Silent Upgrade: ERROR: directory not writable

    Disparate.

    I'm going to try changing the upgrade code to assign itself rights to write as it runs. Hopefully that'll do it.

  3. #3
    eggsurplus's Avatar
    eggsurplus is offline Sugar Community Member
    Join Date
    Dec 2005
    Location
    Minnesota
    Posts
    2,343

    Default Re: Silent Upgrade: ERROR: directory not writable

    I couldn't get it to work on the test server so tried moving it to my laptop and using the silent upgrader it finishes but never touches the database and misses a bunch of files. Here is what I get at the login screen now:

    Warning: include(themes/Sugar/footer.php) [function.include]: failed to open stream: No such file or directory in C:\xampp\htdocs\sugar_upgrade\index.php on line 809

    Warning: include() [function.include]: Failed opening 'themes/Sugar/footer.php' for inclusion (include_path='.;C:\xampp\php\pear\') in C:\xampp\htdocs\sugar_upgrade\index.php on line 809

    The updater log just says:
    Wed, 23 Apr 2008 10:31:34 -0500 [UpgradeWizard] - *** SILENT UPGRADE INITIATED.
    Wed, 23 Apr 2008 10:31:34 -0500 [UpgradeWizard] - *** UpgradeWizard Upgraded

  4. #4
    eggsurplus's Avatar
    eggsurplus is offline Sugar Community Member
    Join Date
    Dec 2005
    Location
    Minnesota
    Posts
    2,343

    Default Re: Silent Upgrade: ERROR: directory not writable

    Getting closer...

    Now using Upgrade Wizard by uploading file...then going to Admin->Upgrade Wizard again. This part works. When it tries to run the update script though it is failing with this error:
    SQL Error : Conversion failed when converting the varchar value 'off' to data type bit.: -- project task UPDATE [project_task] set [milestone_flag]='0' where [milestone_flag] in ('',null,'off');

    OK, it's still a varchar in the database and there are no rows in that table...ideas?

    P.S. The 451_to_500_mssql.sql script mostly works in Studio Manager. I needed to alter a few statements since some columns don't exist and some statements needed to be forced to execute by adding a GO statement after it before trying to set the value. It just doesn't work when Sugar tries to run it.

  5. #5
    eggsurplus's Avatar
    eggsurplus is offline Sugar Community Member
    Join Date
    Dec 2005
    Location
    Minnesota
    Posts
    2,343

    Default Re: Silent Upgrade: ERROR: directory not writable

    Got it to fully work!

    I had to open the upgrade patch and change upgrade_utils.php to not stop after a failed query by changing true to false:
    PHP Code:
    $query_result $db->query($query.';'false"An error has occured while performing db query.  See log file for details. query: $query<br>"); 
    I also had to change the 451_to_500_mssql.sql script by remove all comments and blank lines and adding this if exists clause before any drop column to make sure that the column exists before dropping it:

    if exists ( select * from INFORMATION_SCHEMA.COLUMNS where TABLE_NAME='[documents]' and COLUMN_NAME='[mail_merge_document]' )
    ALTER TABLE [documents] DROP COLUMN [mail_merge_document];

    After I run the upgrade I just check the logs to see what queries failed and deal with it at that time. Now it upgrades and we can move on.
    Last edited by eggsurplus; 2008-04-24 at 04:18 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Command-line upgrade for large systems
    By clint in forum Installation and Upgrade Help
    Replies: 66
    Last Post: 2011-07-28, 03:04 PM
  2. Upgrade from 3.0.1 to 4.5.1b
    By bkunyiha in forum Installation and Upgrade Help
    Replies: 1
    Last Post: 2007-06-21, 11:40 PM
  3. Upgrade process review - 2.0 to 4.0
    By kimvette in forum General Discussion
    Replies: 2
    Last Post: 2007-05-22, 06:18 PM
  4. Replies: 3
    Last Post: 2005-11-23, 12:34 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •