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

add support for OpenBSD arm64 #1052

Merged
merged 1 commit into from Apr 19, 2021
Merged

Conversation

gballet
Copy link
Contributor

@gballet gballet commented Mar 23, 2021

No description provided.

@Lomanic
Copy link
Collaborator

Lomanic commented Apr 13, 2021

I finally ordered a Raspberry Pi 4 to be able to test gopsutil on arm64 on various OSes, I received it last week but I failed to install openbsd 6.8 on it last weekend (it is not as simple as running dd over an sd card and booting it). I will follow up on this not before the next weekend. Previous work was started in #993 but hit some roadblocks as I was only able to test things without hardware with @vext01 helpful assistance.

Can any of @vext01 or @tobias-hildebrandt run tests on this PR on your hardware (go test github.com/shirou/gopsutil/... or go test ./...)?

@shirou
Copy link
Owner

shirou commented Apr 14, 2021

(sorry to off-topic)

How about to start a GitHub sponsor, @Lomanic ? I want to pay your Raspberry Pi!

@tobias-hildebrandt
Copy link

Hello, I've run the tests on my Raspberry Pi 4:
gopsutil-log.txt

@gballet
Copy link
Contributor Author

gballet commented Apr 15, 2021

@tobias-hildebrandt are you running OpenBSD on bare metal or in a VM? error operation not supported comes from a sysctl that checks for CPU frequencies.

@tobias-hildebrandt
Copy link

I'm running OpenBSD on bare metal.

Your diagnosis seems correct, it looks like I'm unable to check the CPU frequency via sysctl hw.cpuspeed, the output is sysctl: hw.cpuspeed: value is not available

I noticed said command when looking at the man pages for cpu(4), though it seems that the man page doesn't exist for arm64, only amd64, hppa, and i386. In my brief search online, I wasn't able to find another way to check the processor frequency.

Perhaps the output of my sysctl hw could help? sysctl_hw.txt (I've redacted some information that might be sensitive)

Let me know if there is any other information I can provide that would be of help.

@gballet
Copy link
Contributor Author

gballet commented Apr 16, 2021

I see, the problem isn't the VM part, the sysctl isn't implemented on arm64 at all 😠 Ok, I'll work around it, thank you.

@Lomanic
Copy link
Collaborator

Lomanic commented Apr 19, 2021

As-is it's OK to merge, thanks a lot @gballet.

About the missing sysctl hw.cpuspeed, it can be fixed afterwards.

@shirou you can setup GitHub sponsors if you want, but I didn't mind buying that Pi, I could also find it some use outside of gopsutil.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants