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

Documentation Errors #233

Closed
gbica-hzo opened this issue May 16, 2024 · 3 comments
Closed

Documentation Errors #233

gbica-hzo opened this issue May 16, 2024 · 3 comments
Assignees
Labels
bug Something isn't working stale

Comments

@gbica-hzo
Copy link

MacOS Agent Uninstall

Full script
#!/bin/sh echo "This will uninstall the Lithnet Access Manager Agent, and remove all configuration for this machine" read -p "Are you sure? " -n 1 -r echo if [ $REPLY =~ ^[Yy]$ ] then /bin/launchctl unload "/Library/LaunchDaemons/io.lithnet.accessmanager.agent.plist" rm "/Library/LaunchDaemons/io.lithnet.accessmanager.agent.plist" rm -rf "/Library/Application Support/Lithnet/AccessManagerAgent" fi

The link https://docs.lithnet.io/ams/installation/installing-the-access-manager-agent/installing-the-access-manager-agent-macos describes the following steps

Uninstalling the agent
You can use the uninstallation script provided to remove the agent from the computer.

sudo /Library/Application\ Support/Lithnet/AccessManagerAgent/Core/Lithnet.AccessManager.Agent/uninstall.sh

but the uninstall.sh is not there, instead it is here
/Library/Application\ Support/Lithnet/AccessManagerAgent/Core/uninstall.sh

Further problems, when running the script
sh /Library/Application\ Support/Lithnet/AccessManagerAgent/Core/uninstall.sh

it throws an error

sh /Library/Application\ Support/Lithnet/AccessManagerAgent/Core/uninstall.sh
This will uninstall the Lithnet Access Manager Agent, and remove all configuration for this machine
Are you sure? y
/Library/Application Support/Lithnet/AccessManagerAgent/Core/uninstall.sh: line 5: [: =~: binary operator expected

If we ran the lines individually, the 1st one fails

/bin/launchctl unload "/Library/LaunchDaemons/io.lithnet.accessmanager.agent.plist"

Warning: Expecting a LaunchAgents path since the command was ran as root. Got LaunchDaemons instead.
`launchctl bootout` is a recommended alternative.
Unload failed: 5: Input/output error
Try running `launchctl bootout` as root for richer errors.
@gbica-hzo gbica-hzo added the bug Something isn't working label May 16, 2024
@jcspencer
Copy link

Hi @gbica-hzo,

Thank you for pointing this out!

I believe this may be a ZSH vs. Bash script difference, as this script was developed when macOS used bash as the default shell.

We will update the documentation accordingly.

Thanks!

@gbica-hzo
Copy link
Author

@jcspencer Note there are 2 issue here.

  • The uninstall script path is incorrect in the docs.
  • The uninstall script does not perform uninstall.

Copy link

stale bot commented Jun 1, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs.

@stale stale bot added the stale label Jun 1, 2024
@stale stale bot closed this as completed Jun 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working stale
Projects
None yet
Development

No branches or pull requests

2 participants