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

FreeBSD Support #126

Open
wants to merge 68 commits into
base: main
Choose a base branch
from
Open

FreeBSD Support #126

wants to merge 68 commits into from

Commits on Feb 5, 2019

  1. Add HostInfo support for FreeBSD

    Initial implementation of HostInfo for FreeBSD platforms.
    dbolcsfoldi committed Feb 5, 2019
    Configuration menu
    Copy the full SHA
    2db0640 View commit details
    Browse the repository at this point in the history

Commits on Feb 10, 2019

  1. Use os.SameFile to compare cwds

    On some platforms (e.g. FreeBSD) user home directories are symlinks
    and os.Getcwd will return the symlink path.
    
    On FreeBSD CWD for processes that's not the running process will not
    give the symlink but the resolved path causing the test to fail at this
    point.
    
    Fix is to use the os.SameFile call to resolve both Os.Getcwd and CWD.
    dbolcsfoldi committed Feb 10, 2019
    Configuration menu
    Copy the full SHA
    d6b209f View commit details
    Browse the repository at this point in the history
  2. Add basic support for ProcessInfo on FreeBSD.

    Implement Process(), Self() and Processes() to the bare minimum.
    That is passing all basic tests.
    dbolcsfoldi committed Feb 10, 2019
    Configuration menu
    Copy the full SHA
    08f7b57 View commit details
    Browse the repository at this point in the history

Commits on Feb 11, 2019

  1. Configuration menu
    Copy the full SHA
    f8ea094 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7d8b0f6 View commit details
    Browse the repository at this point in the history

Commits on Feb 12, 2019

  1. Review fixes.

    - Fix issue on FreeBSD 12.
    - Minor cosmetic issues.
    dbolcsfoldi committed Feb 12, 2019
    Configuration menu
    Copy the full SHA
    4388e47 View commit details
    Browse the repository at this point in the history
  2. Clean up build process.

    - Remove cgo build directives from things not needing it.
    - Add linker flags into .go files.
    dbolcsfoldi committed Feb 12, 2019
    Configuration menu
    Copy the full SHA
    926d715 View commit details
    Browse the repository at this point in the history

Commits on Aug 5, 2022

  1. Configuration menu
    Copy the full SHA
    37cd519 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    042a304 View commit details
    Browse the repository at this point in the history

Commits on Aug 16, 2022

  1. Configuration menu
    Copy the full SHA
    e0d9718 View commit details
    Browse the repository at this point in the history

Commits on Mar 14, 2024

  1. Configuration menu
    Copy the full SHA
    32a9266 View commit details
    Browse the repository at this point in the history
  2. gofumpt the code

    [git-generate]
    
    gofumpt -w --extra $(find . -name '*.go')
    andrewkroh committed Mar 14, 2024
    Configuration menu
    Copy the full SHA
    cf4130f View commit details
    Browse the repository at this point in the history
  3. Add changelog file

    andrewkroh committed Mar 14, 2024
    Configuration menu
    Copy the full SHA
    68c3cbe View commit details
    Browse the repository at this point in the history
  4. go.mod - tidy up

    andrewkroh committed Mar 14, 2024
    Configuration menu
    Copy the full SHA
    3cba121 View commit details
    Browse the repository at this point in the history
  5. implement type.Host by adding FQDN() and FQDNWithContext()

    providers/freebsd/host_freebsd.go:56:9: cannot use newHost() (value of type *host) as types.Host value in return statement: *host does not implement types.Host (missing method FQDN)
    andrewkroh committed Mar 14, 2024
    Configuration menu
    Copy the full SHA
    47ee9c3 View commit details
    Browse the repository at this point in the history
  6. Fix changelog PR number

    andrewkroh committed Mar 14, 2024
    Configuration menu
    Copy the full SHA
    1b786ed View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    984d22f View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    98a3c4f View commit details
    Browse the repository at this point in the history

Commits on Apr 9, 2024

  1. Configuration menu
    Copy the full SHA
    26ffe87 View commit details
    Browse the repository at this point in the history
  2. moved files

    redanthrax committed Apr 9, 2024
    Configuration menu
    Copy the full SHA
    608fba5 View commit details
    Browse the repository at this point in the history

Commits on Apr 10, 2024

  1. Use stdlib errors

    Replace usages of github.com/pkg/errors and github.com/joeshaw/multierror.
    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    056b9f1 View commit details
    Browse the repository at this point in the history
  2. align go:build tags

    Make sure that all code depending on cgo is tagged appropriately.
    
    Replace "syscall" with golang.org/x/sys/unix as per the recommendation of
    the stdlib syscall package for new code.
    
    Add a cross-compile sanity check for freebsd/amd64.
    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    e7fcbe6 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1ba0ba6 View commit details
    Browse the repository at this point in the history
  4. go mod tidy

    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    6870e0a View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    00cb2d3 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    174d0bb View commit details
    Browse the repository at this point in the history
  7. update README with freebsd

    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    2002a73 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    a15881d View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    bfbc2e6 View commit details
    Browse the repository at this point in the history
  10. remove getOSInfo(baseDir)

    The baseDir was never used so implement this directly within OperativingSystem().
    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    ff57aec View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    496d742 View commit details
    Browse the repository at this point in the history
  12. use unix.SysctlUint{32,64}

    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    8f57214 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    9753408 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    ff2ef7b View commit details
    Browse the repository at this point in the history
  15. remove dead code

    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    26dfaba View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    3952336 View commit details
    Browse the repository at this point in the history
  17. hw.physmem is a uint64

    andrewkroh committed Apr 10, 2024
    Configuration menu
    Copy the full SHA
    21e4945 View commit details
    Browse the repository at this point in the history

Commits on Apr 11, 2024

  1. Configuration menu
    Copy the full SHA
    56e911a View commit details
    Browse the repository at this point in the history
  2. change memory data sources

    Prior to this change the used memory value looked incorrect:
    
    {
      "host.memory": {
        "total_bytes": 6402035712,
        "used_bytes": 6402035712,
        "available_bytes": 162770944,
        "free_bytes": 0,
        "virtual_total_bytes": 1073610752,
        "virtual_used_bytes": 0,
        "virtual_free_bytes": 1073610752
      }
    }
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    772144c View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    ceb2852 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    c4a0b0d View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    eedf803 View commit details
    Browse the repository at this point in the history
  6. improve code locality - combine sysctl sources

    Combine all non-cgo sysctl based data sources into one file
    to improve the code locality.
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    0398d56 View commit details
    Browse the repository at this point in the history
  7. dead code - remove vmstat.go + related

    Remove vmstat.go and vmstat_test.go for now because these were unused.
    They can be added back later in a separate PR.
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    5b21c93 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    5da5e60 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    1eac8f6 View commit details
    Browse the repository at this point in the history
  10. replace ioutil.ReadFile with os.ReadFile

    ioutil is deprecated.
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    46fd95b View commit details
    Browse the repository at this point in the history
  11. fix handling of kern.cp_time

      === RUN   TestHost
          system_test.go:309: error parsing kern.cp_time: strconv.ParseUint: parsing "\xd8\x0f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00Q\x05\x00\x00\x00\x00\x00\x00\xce\x01\x00\x00\x00\x00\x00\x00k": invalid syntax
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    69bf19c View commit details
    Browse the repository at this point in the history
  12. initialize process.fs to fix NetworkCounters

           system_test.go:265:
              	Error Trace:	system_test.go:265
              	Error:      	Received unexpected error:
              	            	open 1620/net/snmp: no such file or directory
              	Test:       	TestSelf
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    8f0f7aa View commit details
    Browse the repository at this point in the history
  13. remove NetworkCounters implementation

    The implementation was not tested and did not work.
    
    I don't think FreeBSD has /proc/<pid>/net/{snmp,netstat} paths.
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    0f176f3 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    0701447 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    6f81957 View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    60b935f View commit details
    Browse the repository at this point in the history
  17. timevalToDuration - use time constants

    Based on the timeval definition, I think the conversion to time.Duration was incorrect.
    
    https://elixir.bootlin.com/freebsd/v14.0/source/sys/sys/_timeval.h#L47
    andrewkroh committed Apr 11, 2024
    Configuration menu
    Copy the full SHA
    9ffae07 View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    d3ab680 View commit details
    Browse the repository at this point in the history

Commits on May 16, 2024

  1. Configuration menu
    Copy the full SHA
    96ff4d1 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    799d779 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    5c5317e View commit details
    Browse the repository at this point in the history

Commits on Jun 19, 2024

  1. Configuration menu
    Copy the full SHA
    534a478 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f9fda75 View commit details
    Browse the repository at this point in the history
  3. Use mib const in sysctlRaw()

    sarog committed Jun 19, 2024
    Configuration menu
    Copy the full SHA
    d3d45df View commit details
    Browse the repository at this point in the history
  4. memInfo(): be less optimistic

    sarog committed Jun 19, 2024
    Configuration menu
    Copy the full SHA
    bbb75c4 View commit details
    Browse the repository at this point in the history

Commits on Jun 20, 2024

  1. Simplified reader.Err()

    sarog committed Jun 20, 2024
    Configuration menu
    Copy the full SHA
    be7058a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    1e82bbf View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    b119ea8 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    1449217 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    1106c15 View commit details
    Browse the repository at this point in the history
  6. Merge pull request #1 from sarog/FreeBSD

    Requested upstream changes
    redanthrax authored Jun 20, 2024
    Configuration menu
    Copy the full SHA
    57174b1 View commit details
    Browse the repository at this point in the history