Skip to content

CI build problem on SLURM test #67

Closed

Description

@guillaumeeb

There seems to be a problem with SLURM CI test, I've seen this in several PRs : https://travis-ci.org/dask/dask-jobqueue/jobs/387815778

A job seems to be fail at submission.

============================= test session starts ==============================
platform linux -- Python 3.6.5, pytest-3.6.0, py-1.5.3, pluggy-0.6.0 -- /opt/anaconda/bin/python
cachedir: .pytest_cache
rootdir: /dask-jobqueue, inifile:
collected 11 items                                                             
dask_jobqueue/tests/test_jobqueue_core.py::test_jq_core_placeholder PASSED [  9%]
dask_jobqueue/tests/test_jobqueue_core.py::test_errors PASSED            [ 18%]
dask_jobqueue/tests/test_pbs.py::test_header PASSED                      [ 27%]
dask_jobqueue/tests/test_pbs.py::test_job_script PASSED                  [ 36%]
dask_jobqueue/tests/test_pbs.py::test_basic SKIPPED                      [ 45%]
dask_jobqueue/tests/test_pbs.py::test_adaptive SKIPPED                   [ 54%]
dask_jobqueue/tests/test_sge.py::test_basic SKIPPED                      [ 63%]
dask_jobqueue/tests/test_slurm.py::test_header PASSED                    [ 72%]
dask_jobqueue/tests/test_slurm.py::test_job_script PASSED                [ 81%]
dask_jobqueue/tests/test_slurm.py::test_basic FAILED                     [ 90%]
dask_jobqueue/tests/test_slurm.py::test_adaptive PASSED                  [100%]
=================================== FAILURES ===================================
__________________________________ test_basic __________________________________
loop = <tornado.platform.asyncio.AsyncIOLoop object at 0x7f934bd42390>
    @pytest.mark.env("slurm")  # noqa: F811
    def test_basic(loop):
        with SLURMCluster(walltime='00:02:00', threads=2, processes=1, memory='4GB',
                          job_extra=['-D /'], loop=loop) as cluster:
            with Client(cluster) as client:
                workers = cluster.start_workers(2)
                future = client.submit(lambda x: x + 1, 10)
                assert future.result(60) == 11
                assert cluster.jobs
    
                info = client.scheduler_info()
                w = list(info['workers'].values())[0]
                assert w['memory_limit'] == 4e9
                assert w['ncores'] == 2
    
                cluster.stop_workers(workers)
    
                start = time()
                while len(client.scheduler_info()['workers']) > 0:
                    sleep(0.100)
>                   assert time() < start + 10
E                   assert 1528123387.6426318 < (1528123377.581219 + 10)
E                    +  where 1528123387.6426318 = time()
dask_jobqueue/tests/test_slurm.py:104: AssertionError
------------------------------ Captured log call -------------------------------
core.py                    210 ERROR    sbatch: error: Batch job submission failed: Unable to contact slurm controller (connect failure)
core.py                    210 ERROR    scancel: error: Invalid job id
================ 1 failed, 7 passed, 3 skipped in 36.07 seconds ================

Activity

  1. lesteve commented on Jun 25, 2018

    @lesteve
    Member

    I can reproduce the error locally. No expert at all in slurm but it seems to me like ci/slurm/register_cluster.sh script is not working correctly and ci/slurm/start-slurm.sh is not stringent enough to detect that the . Why it seemed to work before and not anymore, no idea ...

    Here is the code I run:

    cd ci/slurm
    ./start-slurm.sh
    

    Here is the output I get at the end of the run (the docker part seems to be fine AFAICT):

    sacctmgr: error: slurm_persist_conn_open_without_init: failed to open persistant connection to slurmdbd:6819: Connection refused
    sacctmgr: error: slurmdbd: Sending PersistInit msg: Connection refused
    sacctmgr: error: Problem talking to the database: Connection refused
    SLURM properly configured
    

    So despite the error in register-cluster.sh start-slurm.sh still thinks slurm is properly configured.

    With my limited docker knowledge, it seems to me that the root problem is in the mysql container, if I only try to start the mysql container:

    docker-compose up mysql 
    
    Starting mysql ... done
    Attaching to mysql
    mysql        | Initializing database
    mysql        | 2018-06-25T15:29:25.103541Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
    mysql        | 2018-06-25T15:29:25.104861Z 0 [ERROR] --initialize specified but the data directory has files in it. Aborting.
    mysql        | 2018-06-25T15:29:25.104886Z 0 [ERROR] Aborting
    mysql        | 
    mysql exited with code 1
    

    Haven't had time to dig further into this ...

  2. guillaumeeb commented on Jun 25, 2018

    @guillaumeeb
    MemberAuthor

    @lesteve do you have the same error as reported above? e.g. with the

    ------------------------------ Captured log call -------------------------------
    core.py                    210 ERROR    sbatch: error: Batch job submission failed: Unable to contact slurm controller (connect failure)
    core.py                    210 ERROR    scancel: error: Invalid job id
    

    part?

    When I look at this, it seems to me that one of the two job-queue jobs that "basic" test is launching, does not fire up correctly. But it looks like the second one has worked, so the SLURM cluster seems to be up at some point.

    The output you show from start-slurm.sh doesn't look too bad to me. The register-cluster.sh is called until no more error are return in output.

  3. lesteve commented on Jun 26, 2018

    @lesteve
    Member

    FYI I added a Travis daily cron job. I feel this is a good way to run the tests daily (especially since there are not that many ongoing PRs in dask-jobqueue) and have some history when something appears to be failing out of nowhere.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions