/build/static/layout/Breadcrumb_cap_w.png

Macintosh Not Checking In; Showing as Off-line, but it's not; Konea not running

I have a computer lab with 8 Macs here on campus. Last year I spent some time on this lab, and I'm confident I had them in the Quest/KACE K1000. In fact, if I remote over to one of them that I haven't touched in that past year, I see that it has both a "/Library/Application Data/Dell" directory (empty tree) and a "/Library/Application Data/Quest" directory (populated with KACE/[bin|data]/[files]).

ps ax | grep konea

returns nothing.

But they don't show up in the K1000.

So I picked one Mac out of the eight, and ran "/Library/Application Support/Quest/bin/AMPTools uninstall all-kuid".

Then I rmdir'd the entire "/Library/Application Data/Dell" and /Library/Application Data/Quest" directories.

Then I rebooted.

I then reinstalled the latest AMP agent (8.1.52), and waited 15 minutes or so for the machine to show up in the K1. It didn't.

So I opened a Terminal and ran "runkbot 2 0" and "runkbot 4 0" and "runkbot 6 0". The 2 and 4 seemed to run normally; the 6 produced some errors (available if needed). The Mac then showed up in the K1000, for a little while (hours?), but when I checked later, it showed up as offline in the K1000, even though I could remote over to it, and reboot, and runkbots some more. I left the machine alone about a day, and after 24 hours of it not checking in, I repeated the uninstall/reinstall, and waited again for it to show up; it hasn't.

I opened a Terminal window and ran

ps ax | grep konea

It returns nothing.

I could run "runkbot [6|4|2] 0", but as long as there's no konea agent running, I see no reason to chase that rabbit.

1) Am I correct in believing the konea agent needs to be running (as it is on a working Mac)? Here's what it looks like on a working Mac:

ACU14090:~ westk$ ps ax | grep konea
93 ?? Ss 1:41.53 /Library/Application Support/Quest/KACE/bin/konea

2) If konea needs to be running, why isn't it running? Hhow do I get it running / fix this issue?

Thanks!

/Kent


7 Comments   [ + ] Show comments
  • WPA-232-MAC-02:data acutech$ ls -alh /Library/LaunchDaemons/ | grep konea
    -rw-r--r-- 1 root wheel 479B May 31 08:06 konea.plist

    WPA-232-MAC-02:data acutech$ sudo launchctl bslist | grep konea
    WPA-232-MAC-02:data acutech$ - kentwest 6 years ago
    • WPA-232-MAC-02:data acutech$ sudo launchctl unload /Library/LaunchDaemons/konea.plist
      launchctl: Error unloading: konea
      WPA-232-MAC-02:data acutech$ sudo launchctl load /Library/LaunchDaemons/konea.plist
      nothing found to load
      WPA-232-MAC-02:data acutech$

      WPA-232-MAC-02:data acutech$ ls -lah /Library/Application\ Support/Quest/KACE/bin/konea
      -rwxr-xr-x 1 root admin 10M Jan 26 14:18 /Library/Application Support/Quest/KACE/bin/konea
      WPA-232-MAC-02:data acutech$

      WPA-232-MAC-02:data acutech$ cat /Library/LaunchDaemons/konea.plist
      <?xml version='1.0' encoding='UTF-8'?>
      <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN"
      "http://www.apple.com/DTDs/PropertyList-1.0.dtd" >
      <plist version='1.0'>
      <dict>
      <key>Label</key><string>konea</string>
      <key>ProgramArguments</key>
      <array>
      <string>/Library/Application Support/Quest/KACE/bin/konea</string>

      </array>



      <key>SessionCreate</key><false/>
      <key>KeepAlive</key><true/>
      <key>RunAtLoad</key><false/>
      <key>Disabled</key><false/>
      </dict>
      </plist>
      WPA-232-MAC-02:data acutech$ - kentwest 6 years ago
  • WPA-232-MAC-02:data acutech$ /Library/Application\ Support/Quest/KACE/bin/konea
    W: 08:53:32 WARNING: Could not lock PID file. Continuing. (open /Library/Application Support/Quest/KACE/data/KONEA_STARTED: permission denied)
    2018-05-31.08:53:32-0500|ERROR|konea.go:151:setupLogging | Could not open log file |{"err":"open /Library/Application Support/Quest/KACE/data/konea.log: permission denied"}
    2018-05-31.08:53:32-0500|INFO |konea.go:247:runKonea | ======== Start Konea ========|{"pid":6151}
    2018-05-31.08:53:32-0500|INFO |konea.go:273:logConfig | Version |{"version":"8.1.52"}
    2018-05-31.08:53:32-0500|INFO |konea.go:275:logConfig | Hostname |{"hostname":"WPA-232-MAC-02"}
    2018-05-31.08:53:32-0500|INFO |konea.go:280:logConfig | Configuration |{"cert":"/Library/Application Support/Quest/KACE/data/konea-k1000.acu.local.pem","config":"/Library/Application Support/Quest/KACE/data/amp.conf","datadir":"/Library/Application Support/Quest/KACE/data"}
    2018-05-31.08:53:32-0500|INFO |engine.go:24:Run | Start Engine |
    2018-05-31.08:53:32-0500|INFO |requesterlistener.go:58:Run | Start Requester Listener |{"addr":"127.0.0.1:52117"}
    2018-05-31.08:53:32-0500|DEBUG|module.go:43:func1 | Loading module |{"path":"/Library/Application Support/Quest/KACE/data/modules/clientidentifier"}
    2018-05-31.08:53:32-0500|ERROR|kuid.go:36:CreateKuid | Could not open kuid file |{"err":"open /Library/Application Support/Quest/KACE/data/kuid.txt136665216: permission denied"}
    2018-05-31.08:53:32-0500|ERROR|serverconn.go:213:func1 | Failed to connect |{"url":"https://k1000.acu.local:443"}
    2018-05-31.08:53:32-0500|INFO |serverconn.go:130:Run | Reconnecting |{"retry":"58s"}
    2018-05-31.08:53:32-0500|DEBUG|process.go:111:Load | Waiting for url |{"module":"clientidentifier"}
    2018-05-31.08:53:32-0500|WARN |process.go:47:logStderr | Module stderr |{"module":"clientidentifier","stderr":"2018-05-31.08:53:32-0500|PANIC|sdk.go:139:SetupLogging | Could not open log file |{\"err\":\"open /Library/Application Support/Quest/KACE/data/konea.log: permission denied\"}\npanic: (*logrus.Entry) (0x1346a40,0xc420080340)\n\ngoroutine 1 [running]:\ngithub.com/Sirupsen/logrus.(*Entry).log(0xc420080340, 0x0, 0xc4200983c0, 0x17)\n\t/Volumes/Build/bamboo-agent-home/xml-data/build-dir/KA-AGENT311-MAC/src/github.com/Sirupsen/logrus/entry.go:103 +0x43c\ngithub.com/Sirupsen/logrus.(*Entry).Panic(0xc42008034..."}
    2018-05-31.08:53:32-0500|ERROR|loader.go:98:load | Could not load module |{"err":"unexpected EOF","name":"clientidentifier"}
    2018-05-31.08:53:32-0500|DEBUG|loader.go:90:remove | Removing module |{"module":"clientidentifier"}
    2018-05-31.08:53:32-0500|ERROR|loader.go:54:AutoLoad | Could not autoload modules|{"err":"unexpected EOF"}

    ^CI: 08:53:53 konea is Stopping!
    2018-05-31.08:53:53-0500|INFO |konea.go:136:Stop | Service Stopping |
    2018-05-31.08:53:53-0500|ERROR|requesterlistener.go:66:Run | Stop Requester Listener |{"err":"accept tcp 127.0.0.1:52117: use of closed network connection"}
    2018-05-31.08:53:53-0500|INFO |engine.go:53:Run | Stop Engine |
    2018-05-31.08:53:53-0500|ERROR|konea.go:250:func2 | Exiting due to error |{"err":"open /Library/Application Support/Quest/KACE/data/KONEA_STARTED: permission denied"}
    2018-05-31.08:53:53-0500|INFO |konea.go:252:func2 | ======== Stop Konea ========|{"pid":6151}
    WPA-232-MAC-02:data acutech$ - kentwest 6 years ago
    • Oops; never mind on this last post; I forgot to "sudo". When I "sudo", I get no output, but I don't get returned to the prompt either. (I would delete this last post, except it might be of value to others to see what happens when you forget to do it as root/sudo.) - kentwest 6 years ago
  • WPA-232-MAC-02:data acutech$ sudo /Library/Application\ Support/Quest/KACE/bin/konea &
    [1] 6432

    WPA-232-MAC-02:data acutech$ ps ax | grep konea
    6432 s000 S 0:00.01 sudo /Library/Application Support/Quest/KACE/bin/konea

    and the Mac shows up in the K1.

    I'm going to reboot, and see what happens. - kentwest 6 years ago
  • After rebooting the Mac,

    the Mac does to offline in the K1 SMA.

    After login,

    WPA-232-MAC-02:~ acutech$ sudo launchctl list | grep konea
    WPA-232-MAC-02:~ acutech$

    So,

    WPA-232-MAC-02:~ acutech$ sudo launchctl load -w /Library/LaunchDaemons/konea.plist
    WPA-232-MAC-02:~ acutech$ sudo launchctl list | grep konea
    1214 - konea
    WPA-232-MAC-02:~ acutech$

    and a few seconds later, the Mac shows up in the SMA as online. Yea, making progress!

    Now, one more reboot test... - kentwest 6 years ago
  • As the reboot started, the Mac when offline in the SMA, as expected.

    After the reboot finished, and I got logged in:

    WPA-232-MAC-02:~ acutech$ sudo launchctl list | grep konea
    Password:
    68 - konea
    WPA-232-MAC-02:~ acutech$

    I was a bit nervous, as the Mac still showed as off-line in the SMA, but after another minute or two, it came online. I think I'm okay with that. - kentwest 6 years ago
  • So I tried it on another of the eight machines.

    I ran:

    WPA-232-MAC-05:~ acutech$ sudo launchctl load -w /Library/LaunchDaemons/konea.plist
    WPA-232-MAC-05:~ acutech$

    and then

    WPA-232-MAC-05:~ acutech$ sudo launchctl list | grep konea
    60401 - konea
    WPA-232-MAC-05:~ acutech$

    and then that Mac appeared in the SMA, as online.

    Yea!

    I then wanted to see what would happen if I reloaded the daemon on a machine that was already running the daemon:

    WPA-232-MAC-05:~ acutech$ sudo launchctl load -w /Library/LaunchDaemons/konea.plist
    konea: Already loaded
    WPA-232-MAC-05:~ acutech$

    Okay, looks like no harm done. I can push this command to all eight Macs without worrying which ones I've already fixed.

    But then after letting things sit a few minutes, I noticed that machine went offline in the SMA, and I went back to it and ran:

    WPA-232-MAC-05:~ acutech$ sudo launchctl list | grep konea
    WPA-232-MAC-05:~ acutech$

    Uh oh, apparently the agent died, and did not restart automagically. Did my second attempt to load the daemon cause it to die? Something else? Why didn't it restart?

    I waited a few minutes, with no change, then reloaded the daemon:

    WPA-232-MAC-05:~ acutech$ sudo launchctl load -w /Library/LaunchDaemons/konea.plist
    WPA-232-MAC-05:~ acutech$

    and

    WPA-232-MAC-05:~ acutech$ sudo launchctl list | grep konea
    60401 - konea

    and the machine came back online in the SMA.

    Looks good.

    But now, I need to wait a little while, without touching anything, to make sure the daemon doesn't die again.

    But at any rate, I'm real close to getting this issue solved, it seems, close enough to enter an answer and close this question. - kentwest 6 years ago
  • I sent the "launchtrl load" command to all eight Macs (via Apple Remote Desktop), and after a couple of minutes they all re-populated in the K1000 SMA.

    Yea!

    But then a couple of minutes later they started going offline again. Now, about 6 minutes later, half of them are offline in the SMA.

    I remoted over to one of them, and ran:

    WPA-232-MAC-01:~ acutech$ sudo launchctl list | grep konea
    Password:
    WPA-232-MAC-01:~ acutech$

    Ah, the agent is again not running.

    Back in the SMA, I notice that the four Macs that are offline have the 8.0.152 agent, and three of the four that are still online have the 8.1.52 agent.

    When I try to Force Inventory the remaining online older agent, it doesn't update the inventory, and after another several minutes, it goes offline.

    So I had five older agents, four of which were offline, and then the last one of those five went offline.

    Ah, another clue!

    So on that Mac only,

    WPA-232-MAC-01:~ acutech$ sudo launchctl load -w /Library/LaunchDaemons/konea.plist
    WPA-232-MAC-01:~ acutech

    It almost immediately comes back online. I run a Force Inventory on it, and it now reports the new agent (8.1.52).

    So I resend the "launchctl load" command to the four older-client offline Macs, and they immediately come back online.

    I do a Force Inventory on those four Macs, and they come back now with the 8.1.52 agent.

    I suspect they will now all stay online. - kentwest 6 years ago

Answers (1)

Answer Summary:
Posted by: kentwest 6 years ago
Second Degree Brown Belt
1

Top Answer

Turns out the konea daemon wasn't starting up on reboot for whatever reason.

Check to see if the daemon is running:

WPA-232-MAC-05:~ acutech$ sudo launchctl list | grep konea
60401 - konea
WPA-232-MAC-05:~ acutech$

means Yes, it is running.

WPA-232-MAC-05:~ acutech$ sudo launchctl list | grep konea
WPA-232-MAC-05:~ acutech$

means No, it is not running.

Make sure the konea.plist is in the right place with the right perms:

WPA-232-MAC-05:~ acutech$ ls -lah /Library/LaunchDaemons/kon*
-rw-r--r-- 1 root wheel 479B May 31 09:12 /Library/LaunchDaemons/konea.plist
WPA-232-MAC-05:~ acutech$

Then tell the system to load the daemon, and to write it to the system as a daemon to be loaded every time the machine is running:

WPA-232-MAC-05:~ acutech$ sudo launchctl load -w /Library/LaunchDaemons/konea.plist
WPA-232-MAC-05:~ acutech$ sudo launchctl list | grep konea
60401 - konea
WPA-232-MAC-05:~ acutech$

Problem (hopefully permanently) solved!

/Kent

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ