News for hackers. Stuff that matters.
Re:Has modern Linux lost its way? Some thoughts on Jessie by zdw on Tuesday February 10, 2015 @02:04AM (#9025774)
> When was the last time you read a manpage about launchd or one of its helpers?

Every time I had to write a lauchdaemon to implement the equivalent of what would be done in cron or inetd.

But I do a lot of Mac sysadmin work.

Re:Has modern Linux lost its way? Some thoughts on Jessie by deong on Tuesday February 10, 2015 @08:34AM (#9026961)
My iMac's automated backup has been broken since Yosemite because Apple removed the ability to set environment variables that all processes started from launchd could use.

It appears that "run a python program as root on a schedule regardless of if anyone is logged in" is no longer possible on a Mac. Or rather, me and my CS PhD aren't capable of figuring out how to do it. I just keep a terminal window open at all times as a reminder to occasionally manually run the script.

Re:Has modern Linux lost its way? Some thoughts on Jessie by fit2rule on Tuesday February 10, 2015 @03:38AM (#9025986)
As a homebrew user I absolutely abhor having to keep around a list of instructions that I've only barely just caught during an install .. things like:

    launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.rethinkdb.plist
    launchctl load ~/Library/LaunchAgents/homebrew.mxcl.rethinkdb.plist

    cassandra

    To have launchd start cassandra at login:
    ln -sfv /usr/local/opt/cassandra/*.plist ~/Library/LaunchAgents
    Then to load cassandra now:
    launchctl load ~/Library/LaunchAgents/homebrew.mxcl.cassandra.plist


    To have launchd start redis at login:
    ln -sfv /usr/local/opt/redis/*.plist ~/Library/LaunchAgents
    Then to load redis now:
    launchctl load ~/Library/LaunchAgents/homebrew.mxcl.redis.plist
    Or, if you don't want/need launchctl, you can just run:
    redis-server /usr/local/etc/redis.conf

.. and so on and on it goes .. seems like the more things 'improve', the more they stay the same.
Re:Has modern Linux lost its way? Some thoughts on Jessie by oesmith on Tuesday February 10, 2015 @11:25AM (#9028116)
Pro-tip: you can use "brew info [package-name]" to lookup the post-install info that flashes up after a homebrew install.

    $ brew info cassandra

    cassandra: stable 2.1.2
    http://cassandra.apache.org
    Not installed
    From: https://github.com/Homebrew/homebrew/blob/master/Library/Formula/cassandra.rb
    ==> Caveats
    If you plan to use the CQL shell (cqlsh), you will need the Python CQL library
    installed. Since Homebrew prefers using pip for Python packages, you can
    install that using:

      pip install cql

    To have launchd start cassandra at login:
        ln -sfv /usr/local/opt/cassandra/*.plist ~/Library/LaunchAgents
    Then to load cassandra now:
        launchctl load ~/Library/LaunchAgents/homebrew.mxcl.cassandra.plist
Re:Has modern Linux lost its way? Some thoughts on Jessie by bazzargh on Tuesday February 10, 2015 @07:04AM (#9026639)
I prefer to use lunchy to do the launchctl stuff: https://github.com/eddiezane/lunchy

'gem install lunchy' to install it. Your commands would have been eg 'lunchy stop rethinkdb', 'lunchy start rethinkdb' - it matches on substrings. The ln step is handled slightly differently - it doesn't work with lists of files, and installs to two different places, but this is roughly equivalent:

    for f in /usr/local/opt/cassandra/*.plist; do lunchy install -s $f; done
(here the -s flag is symlink rather than copy)
Re:Has modern Linux lost its way? Some thoughts on Jessie by fit2rule on Tuesday February 10, 2015 @07:57AM (#9026810)
I have much disdain for this solution - even though it is a solution - because its a non-builtin tool and has dependencies outside the OSX sphere in order to run.

I wish there were some sort of Guild of OS Developers that could be relied on to enforce the inclusion of standardized tools in all OS's released by its members. It seems that a lack of an organizing body to enforce these standards - or in Apples' case, any way for the public to influence the standards they dictate - is a real problem with OS development today.

Nevertheless, good to know about lunchy. I will try to remember to check it out some time.

Re:Has modern Linux lost its way? Some thoughts on Jessie by protomyth on Tuesday February 10, 2015 @10:14AM (#9027555)
If I am having a problem with OpenBSD, I read the man pages. If I am having a problem with OS X, I search the web for a result. I just don't quite trust the OS X man pages anymore.