shirou
39f3b34192
Merge pull request #1392 from brianryner8/getfsstat-count
...
Truncate the Getfsstat result to the count of items that were returned
2022-12-18 13:19:54 +09:00
shirou
8d22915181
[disk][darwin]: add issue URL
2022-12-18 13:11:56 +09:00
Brian Ryner
c2fa2cbf8e
Update comment
2022-12-18 14:23:01 +11:00
shirou
bd21a78aa9
Merge pull request #1387 from shirou/dependabot/go_modules/golang.org/x/sys-0.3.0
...
chore(deps): bump golang.org/x/sys from 0.2.0 to 0.3.0
2022-12-10 20:19:46 +09:00
shirou
d661503ccc
Merge pull request #1393 from tklauser/byteslicetostring
...
host: use unix.ByteSliceToString
2022-12-10 10:36:24 +09:00
shirou
d2a3bd84bd
Merge pull request #1394 from tklauser/activeprocessorcount
...
cpu: use windows.GetActiveProcessorCount
2022-12-10 10:27:29 +09:00
Tobias Klauser
f2bf9a480a
cpu: use windows.GetActiveProcessorCount
...
Use GetActiveProcessorCount and the ALL_PROCESSOR_GROUPS const provided
in golang.org/x/sys/windows. The function is available on Windows 7 and
later. Go requires Windows 7, see https://go.dev/doc/go1.11#ports
2022-12-07 13:51:29 +01:00
Tobias Klauser
f9a5834e0e
host: use unix.ByteSliceToString
...
Use ByteSliceToString provided in golang.org/x/sys/unix to convert
\0-terminated byte slices to strings.
2022-12-07 13:14:45 +01:00
Brian Ryner
34da06e9b7
fix
2022-12-07 14:31:09 +11:00
Brian Ryner
c5e42b972f
Truncate the result of Getfsstat to the item count that is returned.
...
This count may be less than what was returned by the first call to Getfsstat.
2022-12-07 14:27:20 +11:00
dependabot[bot]
062ecda202
chore(deps): bump golang.org/x/sys from 0.2.0 to 0.3.0
...
Bumps [golang.org/x/sys](https://github.com/golang/sys ) from 0.2.0 to 0.3.0.
- [Release notes](https://github.com/golang/sys/releases )
- [Commits](https://github.com/golang/sys/compare/v0.2.0...v0.3.0 )
---
updated-dependencies:
- dependency-name: golang.org/x/sys
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-12-05 01:46:28 +00:00
shirou
3b918ebd29
Merge pull request #1386 from bogdandrutu/patch-1
...
Retract deleted tag v3.22.11
2022-12-02 15:32:00 +09:00
Bogdan Drutu
032376bae4
Retract deleted tag v3.22.10
2022-12-01 11:57:22 -08:00
shirou
e7a0ff26d0
Merge pull request #1384 from shirou/revert-1367-feat/implement-label-windows
...
Revert "[disk][windows] Support LabelWithContext & SerialNumberWithContext - rebased "
2022-12-01 23:06:37 +09:00
shirou
a0f8443561
Revert "[disk][windows] Support LabelWithContext & SerialNumberWithContext - rebased "
2022-12-01 08:42:17 +09:00
shirou
af44f9d16b
Merge pull request #1367 from FrankSpitulski/feat/implement-label-windows
...
[disk][windows] Support LabelWithContext & SerialNumberWithContext - rebased
2022-12-01 08:34:29 +09:00
shirou
9fc4d70059
Merge pull request #1379 from shirou/feature/revert_errors_from_internal
...
[disk][host]: move back Warnings from internal to disk and host.
2022-12-01 08:30:31 +09:00
shirou
5473fd114d
[disk][host]: change to use type alias.
2022-11-30 23:23:31 +00:00
shirou
ea7607ebd0
Merge pull request #1381 from sfzfs/solaris-disk-mem-net-feature
...
pull request on adding missing statistic under solaris/illumos
2022-12-01 08:14:54 +09:00
shirou
30aa851d39
Merge pull request #1380 from shirou/feature/readable_error_on_load_windows
...
[load][windows]: add error detail and context handling.
2022-12-01 08:09:20 +09:00
Steve Zhang
ccb11cf45e
reuse the context.Context instead of creating a new Context
2022-11-28 22:30:09 -07:00
Steve Zhang
cf62eac8f9
The current codes miss below statistic data under solaris/illumos:
...
1. the disk io statistic data as: nread, nwritten, reads, writes, rtime, wtime;
2. the free memory under global zone;
3. the net io statistic data as: rbytes64, ipackets64, idrops64, ierrors, obytes64, opackets64, odrops64, oerrors.
The new feature branch adds the above missing statistic data based on the psutil project (https://psutil.readthedocs.io/ ), it has been tested under solaris ( Oracle Solaris 11.4 X86) and illumos (OmniOS v11 r151044).
2022-11-21 21:28:36 -07:00
shirou
231d6f3d4e
[load][windows]: add error detail and context handling.
2022-11-19 12:21:45 +00:00
shirou
4ac7e99c6a
[disk][host]: move back Warnings from internal to disk and host.
...
fix #1377
2022-11-19 11:37:38 +00:00
Aman Gupta Karmani
34cc43d282
[android][host] fix Info() failure due to forbidden /proc/stat and /proc/uptime ( #1361 )
...
* [android][host] fallback to sysinfo() syscall for uptime
with Android O, /proc/{stat,uptime} both return permission denied
2022-11-19 04:17:18 +01:00
shirou
d3ea8776ff
Merge pull request #1362 from fancybits/ios-iokit
...
[ios][disk] IOKit is not available on iOS
2022-11-19 11:58:31 +09:00
shirou
672e2518f2
Merge pull request #1374 from shirou/feature/add_ubr_on_host_windows
...
feat(host, windows): add UBR (Update Build Revision) to kernel version
2022-11-10 10:22:20 +09:00
shirou
2099ec6e27
Merge pull request #1375 from shirou/dependabot/go_modules/github.com/tklauser/go-sysconf-0.3.11
...
chore(deps): bump github.com/tklauser/go-sysconf from 0.3.10 to 0.3.11
2022-11-10 10:22:05 +09:00
dependabot[bot]
2a3e4c7326
chore(deps): bump github.com/tklauser/go-sysconf from 0.3.10 to 0.3.11
...
Bumps [github.com/tklauser/go-sysconf](https://github.com/tklauser/go-sysconf ) from 0.3.10 to 0.3.11.
- [Release notes](https://github.com/tklauser/go-sysconf/releases )
- [Commits](https://github.com/tklauser/go-sysconf/compare/v0.3.10...v0.3.11 )
---
updated-dependencies:
- dependency-name: github.com/tklauser/go-sysconf
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-11-10 01:08:53 +00:00
shirou
59246d8b0f
Merge pull request #1373 from yaozbek/modelname-support-for-arm
...
feat: Setting the model name for arm based CPUs
2022-11-06 13:13:02 +09:00
Yalcin Ozbek
8bf7f37fca
the code has been moved before append
...
Signed-off-by: Yalcin Ozbek <yalcinozbekceng@gmail.com>
2022-11-05 16:40:39 +03:00
Yalcin Ozbek
4314a0567b
the code has been moved outside the loop.
...
Signed-off-by: Yalcin Ozbek <yalcinozbekceng@gmail.com>
2022-11-05 16:37:04 +03:00
Yalcin Ozbek
13f00fde46
code review fix
...
Signed-off-by: Yalcin Ozbek <yalcinozbekceng@gmail.com>
2022-11-05 15:06:30 +03:00
shirou
68452e2602
feat(host, windows): add UBR (Update Build Revision) to kernel version
2022-11-05 20:59:15 +09:00
Yalcin Ozbek
102439862e
feat: Setting the model name for arm based CPUs
...
- Added arm model and model name as map.
- The modelName is set again according to the model value when the model name is empty.
- Based on lscpu source code.. https://github.com/util-linux/util-linux/blob/master/sys-utils/lscpu-arm.c
---
Signed-off-by: Yalcin Ozbek <yalcinozbekceng@gmail.com>
2022-11-05 02:36:48 +03:00
shirou
50f22507f5
Merge pull request #1365 from ib-steffen/pass-context
...
Pass on context to ConnectionsPidWithContext
2022-10-29 13:45:28 +09:00
shirou
b34aa19712
Merge pull request #1370 from shirou/dependabot/go_modules/github.com/stretchr/testify-1.8.1
...
chore(deps): bump github.com/stretchr/testify from 1.8.0 to 1.8.1
2022-10-29 13:29:07 +09:00
shirou
20b15fb639
Merge pull request #1369 from Lomanic/issue1368
...
[process][windows] Retrieve process name as basename of executable
2022-10-29 13:28:52 +09:00
dependabot[bot]
359e8eb4b3
chore(deps): bump github.com/stretchr/testify from 1.8.0 to 1.8.1
...
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify ) from 1.8.0 to 1.8.1.
- [Release notes](https://github.com/stretchr/testify/releases )
- [Commits](https://github.com/stretchr/testify/compare/v1.8.0...v1.8.1 )
---
updated-dependencies:
- dependency-name: github.com/stretchr/testify
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-10-24 01:45:06 +00:00
Lomanic
980cc82c08
[process][windows] Retrieve process name as basename of executable
...
We align ourself with psutil
8e4099d9f0/psutil/_pswindows.py (L749-L759)
Benchmarks show vast improvements
go test -run=BenchmarkProcessName -bench=BenchmarkProcessName ./process
goos: windows
goarch: amd64
pkg: github.com/shirou/gopsutil/v3/process
cpu: Intel(R) Core(TM) i5-6300U CPU @ 2.40GHz
BenchmarkProcessName-4 180 6564033 ns/op
BenchmarkProcessNameViaExe-4 22111 51153 ns/op
PASS
ok github.com/shirou/gopsutil/v3/process 3.914s
Fixes #1368
2022-10-22 21:43:23 +02:00
Lomanic
bd4529a7cc
[process][windows] Refator a tiny bit is32BitProcess() function to be more idiomatic Go
2022-10-22 19:09:36 +02:00
Frank Spitulski
d7c791252a
rebase on master
2022-10-19 19:19:59 -07:00
Matthew Palmer
b515acb162
[disk][windows] Support LabelWithContext & SerialNumberWithContext
...
Add support for LabelWithContext & SerialNumberWithContext, additionally returning this data back for the IOCountersWithContext function.
2022-10-19 19:10:01 -07:00
Steffen Geissinger
5bbcabf17d
Pass on context to ConnectionsPidWithContext
2022-10-19 10:07:21 +02:00
Aman Karmani
0823447625
[ios][disk] IOKit is not available on iOS
2022-10-11 13:17:17 -07:00
shirou
400a453e67
Merge pull request #1360 from bduffany/darwin-memleak
...
Fix memory leaks in process_darwin_cgo
2022-10-09 12:57:36 +09:00
shirou
769daafb9e
Merge pull request #1347 from atoulme/windows_errors
...
Return all Windows partitions
2022-10-09 12:55:42 +09:00
Brandon Duffany
38064605a8
Fix memory leaks in darwin_cgo
2022-10-04 14:35:52 -04:00
Antoine Toulme
dbc0f20fe3
code review
2022-10-03 13:55:14 -07:00
shirou
16b3aac6ad
Merge pull request #1336 from johanburati/job043
...
Add hostinfo Virtualization hyperv
2022-09-30 17:33:58 +09:00