Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Permission problem causes the message of "Another instance of BOINC is running" #2264

Closed
photonxp opened this issue Nov 29, 2017 · 1 comment

Comments

@photonxp
Copy link

photonxp commented Nov 29, 2017

OS: ubuntu
boinc version: 7.6.31+dfsg-6ubuntu1

Problem reduplication:

When user [otheruser] uses the working directory [boinctest] of the user [boinc], boinc program showes "Another instance of BOINC is running":

otheruser@linux $ sudo chown boinc:boinc -R /home/otheruser/boinctest
otheruser@linux $ /usr/bin/boinc --dir /home/otheruser/boinctest

28-Nov-2017 22:21:07 Another instance of BOINC is running.

With enough permission, no message of "Another instance of BOINC is running":

otheruser@linux $ sudo chown boinc:boinc -R /home/otheruser/boinctest
otheruser@linux $ sudo -u boinc /usr/bin/boinc --dir /home/otheruser/boinctest
)) Some files under [boinctest] may need root permission, so the commands here are just for test.

28-Nov-2017 22:53:04 [---] Starting BOINC client version 7.6.31 for x86_64-pc-linux-gnu
28-Nov-2017 22:53:04 [---] log flags: file_xfer, sched_ops, task
28-Nov-2017 22:53:04 [---] Libraries: libcurl/7.47.0 OpenSSL/1.0.2g zlib/1.2.8 libidn/1.32 librtmp/2.3
28-Nov-2017 22:53:04 [---] Data directory: /home/otheruser/boinctest
28-Nov-2017 22:53:04 [---] No usable GPUs found
28-Nov-2017 22:53:04 [---] Host name: linux
... ...
28-Nov-2017 22:53:04 [---] This computer is not attached to any projects
28-Nov-2017 22:53:04 [---] Visit http://boinc.berkeley.edu for instructions
28-Nov-2017 22:53:04 Initialization completed

More info:

I think the problem may lie somewhere around the functions of [wait_client_mutex] and [get_client_mutex] in the lib/util.cpp.

//Codes around here below look suspicious. Perhaps we need to check "retval" for more types of error messages or error handlers. Even better if the file path is attached in the error messages.

    int retval = file_lock.lock(path);
    if (retval == ERR_FCNTL) {
        return ERR_ALREADY_RUNNING;
    } else if (retval) {
        return retval;
@photonxp photonxp changed the title Boinc shows "Another instance of BOINC is running", but actually it's a permission problem Permission problem causes the message of "Another instance of BOINC is running" Nov 29, 2017
@AenBleidd
Copy link
Member

Closed as a duplicate of #2156

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

No branches or pull requests

3 participants