Hello,

Yes, this is sometimes problematic. You may have seen this, but a discussion about this same topic took place on the galaxy-dev@bx.psu.edu mailing list earlier. It has more details about why this can occur. Also, please try the work-around Jeremy suggests and see if that helps.
http://lists.bx.psu.edu/pipermail/galaxy-dev/2013-December/017773.html

Take care,

Jen
Galaxy team

On 12/18/13 4:48 AM, Alessandro Ogier wrote:
Dear galaxy users,

    here at European Institute of Oncology we're deploying a brand new galaxy install, but facing problems with history (re)importing.

We have configured a galaxy running on one node where users took a "sneek peek" on features while developing a real deployment on nfs and cluster integration. Now I have to migrate histories to new galaxy install, I'm doing that on behalf my users because we choose to integrate with an apache proxy that does reverse proxying and ldap authentication.

Yesterday I produced four tar.gz for a user, placed on a temporary webserver and then proceeded with reimport on new instance: two where reimported, two not.

All those files are relatively small (from 1MB to 13MB), and no clues from galaxy debug log:

SUCCESSFUL ONE:

galaxy.jobs DEBUG 2013-12-18 13:29:32,718 (354) Working directory for job is: /srv/galaxy/galaxy-dist/database/job_working_directory/000/354
galaxy.jobs.handler DEBUG 2013-12-18 13:29:32,738 (354) Dispatching to local runner
galaxy.jobs DEBUG 2013-12-18 13:29:32,826 (354) Persisting job destination (destination id: local)
galaxy.jobs.handler INFO 2013-12-18 13:29:32,864 (354) Job dispatched
galaxy.jobs.runners.local DEBUG 2013-12-18 13:29:33,151 (354) executing: export GALAXY_SLOTS="1"; python /srv/galaxy/galaxy-dist/lib/galaxy/tools/imp_exp/unpack_tar_gz_archive.py http://debian.ieo.eu/drosano/dalia-37.tar.gz /srv/galaxy/galaxy-dist/database/tmp/tmpLAAF5z --url
galaxy.jobs DEBUG 2013-12-18 13:29:33,326 (354) Persisting job destination (destination id: local)
galaxy.jobs.runners.local DEBUG 2013-12-18 13:29:34,451 execution finished: export GALAXY_SLOTS="1"; python /srv/galaxy/galaxy-dist/lib/galaxy/tools/imp_exp/unpack_tar_gz_archive.py http://debian.ieo.eu/drosano/dalia-37.tar.gz /srv/galaxy/galaxy-dist/database/tmp/tmpLAAF5z --url
galaxy.jobs DEBUG 2013-12-18 13:29:34,644 job 354 ended
galaxy.datatypes.metadata DEBUG 2013-12-18 13:29:34,644 Cleaning up external metadata files

UNSUCCESSFUL ONE:

galaxy.jobs DEBUG 2013-12-18 13:30:42,824 (392) Working directory for job is: /srv/galaxy/galaxy-dist/database/job_working_directory/000/392
galaxy.jobs.handler DEBUG 2013-12-18 13:30:42,844 (392) Dispatching to local runner
galaxy.jobs DEBUG 2013-12-18 13:30:42,934 (392) Persisting job destination (destination id: local)
galaxy.jobs.handler INFO 2013-12-18 13:30:42,963 (392) Job dispatched
galaxy.jobs.runners.local DEBUG 2013-12-18 13:30:43,236 (392) executing: export GALAXY_SLOTS="1"; python /srv/galaxy/galaxy-dist/lib/galaxy/tools/imp_exp/unpack_tar_gz_archive.py http://debian.ieo.eu/drosano/dalia-138.tar.gz /srv/galaxy/galaxy-dist/database/tmp/tmpH8buNE --url
galaxy.jobs DEBUG 2013-12-18 13:30:43,400 (392) Persisting job destination (destination id: local)
galaxy.jobs.runners.local DEBUG 2013-12-18 13:30:47,524 execution finished: export GALAXY_SLOTS="1"; python /srv/galaxy/galaxy-dist/lib/galaxy/tools/imp_exp/unpack_tar_gz_archive.py http://debian.ieo.eu/drosano/dalia-138.tar.gz /srv/galaxy/galaxy-dist/database/tmp/tmpH8buNE --url
galaxy.jobs DEBUG 2013-12-18 13:30:47,711 job 392 ended
galaxy.datatypes.metadata DEBUG 2013-12-18 13:30:47,712 Cleaning up external metadata files


sorry for line wraps, I also attached logs.

I cloned your repository on my development machine to try to recreate/debug this issue but unfortunately this time I'm unable to import successfully any history (plain galaxy instance, sqlite, no ext user, no job_conf, either default and stable branches).

I'm attaching the new galaxy instance universe_wsgi.ini and job_conf.xml, as you can see they are pretty straight-forward.


What I'm asking to you : which is the correct way for debugging this sort of things ? No luck putting some debugging code in

  * lib/galaxy/tools/actions/history_imp_exp.py
  * lib/galaxy/tools/imp_exp/unpack_tar_gz_archive.py


maybe I'm missing something ...

also, I'd like to contribute some patch on a couple of minor glitches I found, but I'll write to -dev list for that


Thank you, and thanks for this great tool :) ciao


___________________________________________________________
The Galaxy User list should be used for the discussion of
Galaxy analysis and other features on the public server
at usegalaxy.org.  Please keep all replies on the list by
using "reply all" in your mail client.  For discussion of
local Galaxy instances and the Galaxy source code, please
use the Galaxy Development list:

  http://lists.bx.psu.edu/listinfo/galaxy-dev

To manage your subscriptions to this and other Galaxy lists,
please use the interface at:

  http://lists.bx.psu.edu/

To search Galaxy mailing lists use the unified search at:

  http://galaxyproject.org/search/mailinglists/

-- 
Jennifer Hillman-Jackson
http://galaxyproject.org