Forum Replies Created

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • in reply to: Leopard: What happened to /etc/rc and `id`? #370638
    klktrk
    Participant

    [QUOTE][u]Quote by: khiltd[/u]

    I’ve tried (I think) every permutation of the undocumented “bootstrap” subcommand and that’s definitely not a good idea. Seems to fire everything up and leave you stuck with no login window. [/QUOTE]
    Yes, my experience exactly. I’m trying to pare down what is needed in order to be able to use some basic utilities in SUM, especially because using the bootstrap is a sure road to hanging computer hell.

    [QUOTE]For diskutil and dscl I imagine you’d want to start with /System/Library/LaunchDaemons/com.apple.diskarbitrationd.pllist and /System/Library/LaunchDaemons/com.apple.DirectoryServicesLocal.pllist and see how far you get. [/p][/QUOTE]

    Yeah, I enabled diskabritation, and that helped me get from using diskutil with a user-friendly “can’t use that, sorry” message to diskutil now sullenly just hanging. I’ll add the directory services and see how far i get.

    it’s the interdependencies that kill me.

    in reply to: Leopard: What happened to /etc/rc and `id`? #370628
    klktrk
    Participant

    [QUOTE][u]Quote by: khiltd[/u][p]It’s not much documentation, but it’s documentation nonetheless:

    [code]Prior to Mac OS X 10.5, the rc script was used to bootstrap the OS. As of Leop-
    ard, the system is self-bootstrapped via launchd(8) which uses the launchctl(1)
    bootstrap subcommand to read in launchd jobs from the standard locations. For
    compatibility reasons, the rc.local script still continues to work.[/code]

    Inspection of the launchctl sources confirms that it’s calling most of the shots these days. [/p][/QUOTE]

    Yes, it does appear that launchctl is doing 90% of the work now, which is great. What is harder to determine is what daemons need to be launched in order to get diskutil or dscl working,without loading the whole kit and kaboodle.

    I think I’m left to a trial and error on that one.

    in reply to: Leopard: What happened to /etc/rc and `id`? #370574
    klktrk
    Participant

    In the meantime, I’ve learned the following:

    The location of the vm (swap directory) can be read here:
    (array) = defaults read /Syste/Library/LaunchDaemons/com.apple.dynamic_pager ProgramArguments

    The id utility fails with a “bus error” when run with no parameters. However, if you run it with id -n or id -un, it works. Odd. Gotta love it.

    So some of the basic re-jiggering has been solved, but I’ve got a long way to go.

    I wish I wish I wish Apple would document their changes, but judging from the last decade or two, that’s never going to happen.

    in reply to: mdls and md server in single user mode won’t work #363988
    klktrk
    Participant

    I got some helpful hints from a user on Mac Ars, and thought I’d share them. He recommended using the file utility, and looking into the file’s resource fork.

    Basically, an alias has two defining characteristics that can be tested in bash:
    1) It has a zero file size (all info is stored in the resource fork).
    2) using the file util agains the rsrc fork of the file will yield the response: ms-windows icon resource (weird).

    So, the code I cobbled together with his help:

    testfile=somefile
    # first, test for 0 file size
    if [ ! -s $testfile ]; then
    r=`file $testfile/rsrc | awk ‘/ms-windows icon resource/ { print $2 “.” $3 “.” $4 }’`;
    if [ “$r” = “ms-windows.icon.resource” ];then
    echo “it’s an alias”;
    fi
    fi

    This seems to be working.

    in reply to: Repair permissions from single user mode? #362179
    klktrk
    Participant

    [QUOTE BY= macshome] I wrote an article on this for the site a while back. Click here for all the details.

    Josh[/QUOTE]

    Seems like there’s some weird behavior with this in PowerBooks under 10.4.x. after typing in /usr/libexec/register_mach_bootstrap_servers /etc/mach_init.d all hell breaks lose for some users–many reporting that they get an infinite loop of the3se errors printed to the screen:
    limiting closed port RST response from 251 to 250 packets per second.

    These are repeated every second or so. There is no way to regain control of the machine except with CTRL-C.

    I’m thinking there’s something buggy going on with launchd and one of the services configured inside the /etc/mach_init.d directory but I can’t for the life of me pin it down.

    These messages, by the way, appear whether the machine is on a network or not, and also regardless of whether the firewall is on or not. It might be related to external USB devices?

    In any case, there are serious problems with this stuff in Tiger.

Viewing 5 posts - 1 through 5 (of 5 total)