osquery ਨੂੰ ਬਿਨਾਂ ਕਿਸੇ ਸਵਾਲ ਦੇ ਇੰਸਟਾਲ ਕਰਨ, ਦੁਬਾਰਾ ਹਟਾਉਣ ਅਤੇ ਡਿਪਲੌਇਮੈਂਟ ਟੂਲਾਂ ਨਾਲ ਪਛਾਣਨ ਦੀਆਂ ਕਮਾਂਡਾਂ। ਕੋਈ ਕਮਾਂਡ ਤਾਂ ਹੀ ਦਿਖਾਈ ਜਾਂਦੀ ਹੈ ਜੇ ਉਹ ਪੱਕੀ ਹੋਵੇ: ਮੈਨੀਫ਼ੈਸਟ ਤੋਂ, ਜਾਂ ਇੰਸਟਾਲਰ ਤਕਨੀਕ ਦੇ ਦਰਜ ਡਿਫ਼ੌਲਟ ਤੋਂ।
ਸੰਬੰਧਿਤ ਗਾਈਡ: ਸਾਈਲੈਂਟ ਇੰਸਟਾਲ ਸਵਿੱਚ: MSI, NSIS, Inno Setup · ਰਜਿਸਟਰੀ ਜਾਂ PowerShell ਨਾਲ ਪ੍ਰੋਗਰਾਮ ਅਣਇੰਸਟਾਲ ਕਰੋ
winget ਨਾਲ
PowerShell
winget install --id osquery.osquery -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id osquery.osquery -e --silentwinget uninstall --id osquery.osquery -e --silentਹਰ ਇੰਸਟਾਲਰ ਮੁਤਾਬਕ
64-ਬਿੱਟ · MSI · ਸਾਰੇ ਯੂਜ਼ਰ · en-US
ਸਾਈਲੈਂਟ ਇੰਸਟਾਲ
msiexec /i osquery-5.24.0.msi /qn /norestartਲੌਗ ਫ਼ਾਈਲ ਲਿਖੋ
msiexec /i osquery-5.24.0.msi /qn /norestart /l*v "%TEMP%\osquery-install.log"ਅਣਇੰਸਟਾਲ
msiexec /x {C31D86CB-6E56-4661-A798-3DCC57A6EEC7} /qn /norestart- MSI ਪ੍ਰੋਡਕਟ ਕੋਡ
- {C31D86CB-6E56-4661-A798-3DCC57A6EEC7}
- ਅਣਇੰਸਟਾਲ ਰਜਿਸਟਰੀ ਕੀ
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{C31D86CB-6E56-4661-A798-3DCC57A6EEC7}
- UpgradeCode
- {EA6C7327-461E-4033-847C-ACDF2B85DEDE}
- ਇੰਸਟਾਲ ਫ਼ੋਲਡਰ
- %ProgramFiles%/osquery
- DisplayVersion
- 5.24.0
PowerShell: ਡਾਊਨਲੋਡ, ਜਾਂਚ, ਇੰਸਟਾਲ
ਅਧਿਕਾਰਤ ਫ਼ਾਈਲ ਡਾਊਨਲੋਡ ਕਰਦੀ ਹੈ, ਉਸ ਦਾ SHA256 ਜਾਂਚਦੀ ਹੈ ਅਤੇ ਉਸ ਨੂੰ ਸਾਈਲੈਂਟ ਮੋਡ ਵਿੱਚ ਇੰਸਟਾਲ ਕਰਦੀ ਹੈ।
install-osquery.ps1
$url = 'https://github.com/osquery/osquery/releases/download/5.24.0/osquery-5.24.0.msi'
$sha256 = '5F123C07936EE927D7B44CCDAF5D01C4B9BAB2956328A4D8C7ADC3395812A659'
$file = Join-Path $env:TEMP 'osquery-5.24.0.msi'
Invoke-WebRequest -Uri $url -OutFile $file -UseBasicParsing
if ((Get-FileHash $file -Algorithm SHA256).Hash -ne $sha256) { throw 'SHA256 mismatch' }
Start-Process msiexec.exe -ArgumentList '/i', ('"{0}"' -f $file), '/qn', '/norestart' -Wait