1. Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

BOINC Config Utility

Discussion in 'World Community Grid (WCG)' started by FordGT90Concept, Aug 7, 2013.

  1. FordGT90Concept

    FordGT90Concept "I go fast!1!11!1!"

    Joined:
    Oct 13, 2008
    Messages:
    12,985 (6.44/day)
    Thanks Received:
    3,092
    Location:
    IA, USA
    Both. If you do anything with exclusive apps in BOINC client, it should write all the default values to the cc_config.xml.


    I would have to move cc_config.xml out of /etc first. Where could my program read/write without problems?
    Crunching for Team TPU
  2. ThE_MaD_ShOt

    ThE_MaD_ShOt

    Joined:
    Nov 29, 2011
    Messages:
    4,610 (5.28/day)
    Thanks Received:
    3,066
    Location:
    Hi! I'm from the Internet
    Theres a download folder. I will try moving it and see how it works. But will probably need permission for that also.
    Crunching for Team TPU
  3. FordGT90Concept

    FordGT90Concept "I go fast!1!11!1!"

    Joined:
    Oct 13, 2008
    Messages:
    12,985 (6.44/day)
    Thanks Received:
    3,092
    Location:
    IA, USA
    Probably. It seems like a dead end to me. A good guide is probably the best we can do.
    Crunching for Team TPU
  4. ThE_MaD_ShOt

    ThE_MaD_ShOt

    Joined:
    Nov 29, 2011
    Messages:
    4,610 (5.28/day)
    Thanks Received:
    3,066
    Location:
    Hi! I'm from the Internet
    Cool thanks for trying man, I really do appreciate it. :toast:

    I will get to work on a guide.
    Arjai says thanks.
    Crunching for Team TPU
  5. Mindweaver

    Mindweaver Moderato®™ Staff Member

    Joined:
    Apr 16, 2009
    Messages:
    5,055 (2.76/day)
    Thanks Received:
    2,606
    Location:
    Statesville, NC
    Yea, I agree with the guide, because even if it's wrote outside of the /etc directory it still needs sudo to modify anything going into the /etc directory. :toast: I think it would be much simplier to use a script using "sed" to do a find and replace. But I think most Linux users would just use the terminal to pass sudo to gedit and modify that file. example:
    Code:
    sudo gedit
    or edit the file outside of /etc like the "Documents" folder and then copy it to /etc/boinc-client.
    Code:
    cd /home/user/Documents
    then once in the Documents folder
    Code:
    sudo cp cc_config.xml /etc/boinc-client
    :toast:
    Crunching for Team TPU
  6. FordGT90Concept

    FordGT90Concept "I go fast!1!11!1!"

    Joined:
    Oct 13, 2008
    Messages:
    12,985 (6.44/day)
    Thanks Received:
    3,092
    Location:
    IA, USA
    That's the advantage of using that program though: it processes the XML file as an XML file. It literally reads the whole file, makes the changes, and writes it back. I don't know if *nix has an XML parser for Bash Shell script but if it does, that would probably be the best way to go.

    Apparently it is possible, but not easy because there is no native support:
    http://stackoverflow.com/questions/893585/how-to-parse-xml-in-bash/2608159#2608159
    Crunching for Team TPU
  7. Mindweaver

    Mindweaver Moderato®™ Staff Member

    Joined:
    Apr 16, 2009
    Messages:
    5,055 (2.76/day)
    Thanks Received:
    2,606
    Location:
    Statesville, NC
    Yea, even if you're able too, the biggest obstacle is still getting a Linux user to except they need a program to do something as simple as editing a text file. and don't take that as me taking a cheap shot at the program or your ability buddy, because that's far from what I'm trying to do. :toast: It's just the mind set of 95% of Linux users. :toast: It's getting a lot better with more users using Ubuntu and Android, but we still have a ways to go. :toast:
    Crunching for Team TPU
  8. FordGT90Concept

    FordGT90Concept "I go fast!1!11!1!"

    Joined:
    Oct 13, 2008
    Messages:
    12,985 (6.44/day)
    Thanks Received:
    3,092
    Location:
    IA, USA
    No one "needs a program" to do what these do. Like most programs, their intent is to take a 10 step process and simplify it to one or two. Linux is engineered, it seems, to prevent that so, naturally, people that don't like wasting time doing frivolous tasks are going to stay away from Linux.

    The problem isn't me, it isn't you, it isn't BOINC, it is Linux. None of us are going to fix Linux (it's a systemic problem, not a distro problem) so a thorough guide is the best we can do. I don't have Linux on any of my computers so I can't write that guide but I hope someone else will. I recommend using spoiler tags and images for whoever does it though.

    I'm not intending to remove the Linux code by the way so if someone finds a way to make it work on Linux, let me know and I'll keep trying. Until then, it's really only useful on Windows.
    Crunching for Team TPU
  9. Arjai

    Arjai

    Joined:
    Apr 3, 2012
    Messages:
    1,451 (1.94/day)
    Thanks Received:
    1,707
    Location:
    St. Paul, MN
    Fine work guys. Really. This noob absorbs this stuff. I think I could edit my config in *nix with just reading these posts! Of course, both my *nix-er's are sitting in storage, at the moment but, good info for future use.

    BTW, MAD, anytime spent writing a Guide will be essential to getting people to switch up their Crunchers to *nix. Effectively improving the PPD and eventually propping TPU on the top of the WCG list!!:rolleyes:

    :D
    Crunching for Team TPU
  10. laptop-hpc

    laptop-hpc

    Joined:
    Apr 7, 2013
    Messages:
    26 (0.07/day)
    Thanks Received:
    30
    Location:
    Central USA
    Well, I've been looking at writing something using GTK+, but that turned into a pain pretty fast, so a command line program seemed simpler to start, and the attached program is what I threw together last night.

    It's a horrible hack that asks whether to report tasks immediately and whether to use GPUs, and then writes strings to the XML file with the options in place. It doesn't parse any XML, so it will OVERWRITE the config file, which is only useful if you don't care about any other options.

    Edit Sep 15: Version 0.01 had a bug where cc_config.xml was written as root, and boinc can't write to it until it's manually removed. :eek: V0.02 fixes that.

    Usage:
    To run it, open a terminal in the directory with the program, and type
    Code:
    sudo ./boinc-config
    to use the default path "/etc/boinc-client/cc_config.xml" or
    Code:
    sudo ./boinc-config 'path-to-cc_config.xml'
    for a custom path (on my system it's /var/lib/boinc/cc_config.xml).
    I'll keep messing with some kind of GUI, but it might take me weeks to get that working. :eek: :laugh:
    The zip file has the compiled program, plus source code if anyone wants it. :)
    Edit: I realize this is hardly easier than just editing the config file with a text editor, but at least you don't have to write the XML every time.

    Attached Files:

    Last edited: Sep 15, 2013
    Crunching for Team TPU
  11. FordGT90Concept

    FordGT90Concept "I go fast!1!11!1!"

    Joined:
    Oct 13, 2008
    Messages:
    12,985 (6.44/day)
    Thanks Received:
    3,092
    Location:
    IA, USA
    Updated BOINC Config Utility to 1.0.1 including changes:
    -Changed "Program..." to "Running..." to avoid confusion.
    -Redid the "Running..." dialog so now it shows process ID, process name, and CPU usage. This is sortable via clicking on the column header to make it much quicker to find the application you are looking for.
    -Made the Exclusive Application list view sortable as well via clicking on the column header. Related: added "Value" to the header because the sorter needs it (silly sorter).
    -Made it save exclusive GPU apps even if no GPUs is set to true. I'll let BOINC sort that one out. Because the application saves and loads directly to/from cc_config.xml, I didn't want to lose exclusive GPU app settings just because no GPUs was true.

    Note: the program will freeze for a few seconds when opening the "Running..." dialog. This inadvertently happens because it is loading information about the running processes. I figure it isn't slow enough that it requires a "loading" dialog.

    Note: It doesn't save the sorted order in the Exclusive Applications list view because, frankly, there's no reason to. Performance is better by not sorting the underlying collection, only sorting the user interface.
    Crunching for Team TPU
  12. FordGT90Concept

    FordGT90Concept "I go fast!1!11!1!"

    Joined:
    Oct 13, 2008
    Messages:
    12,985 (6.44/day)
    Thanks Received:
    3,092
    Location:
    IA, USA
    Updated BOINC Config Utility to 1.0.2 including changes:
    -Revamped code for reading registry so it will properly fall through the options should they fail (e.g. check 64-bit registry, then 32-bit registry, then ask user).
    -Changed windows icons from icons to portable network graphics. Don't ask why but if this isn't done, it will crash on start in Server 2003 and potentially other, older operating systems (read: XP).
    -It now supports 5.10 which is still in service on Windows Server domain controllers.
    Arjai says thanks.
    Crunching for Team TPU
  13. FordGT90Concept

    FordGT90Concept "I go fast!1!11!1!"

    Joined:
    Oct 13, 2008
    Messages:
    12,985 (6.44/day)
    Thanks Received:
    3,092
    Location:
    IA, USA
    Just updated BOINC Config Utility to 1.0.3. The changes I can remember...
    -Exclusive Apps list now defaults to sorting alphabetically.
    -Add running program list now defaults to sorting highest CPU load.
    -Double click to add a program from the running program list is now supported again.
    -When a program is added to the exclusive apps list, it automatically scrolls to it and selects it.
    -When a program is added to the exclusive apps list, the default is to select "All" instead of "Default."
    -Add running program and add program name dialogs no longer show up in the taskbar.

    These changes should make it much faster to find, add, and apply rules so you can get back to what you were doing as quickly as possible.
    t_ski, Arjai and Norton say thanks.
    Crunching for Team TPU

Currently Active Users Viewing This Thread: 1 (0 members and 1 guest)

Share This Page