Installation

Can I download splunkforwarder by using curl ?

okug
New Member

Can I download splunkforwarder by using curl instead of wget?

Thanks,
-- Hiroshi

Tags (1)
0 Karma
1 Solution

ohoppe
Path Finder

Hi Hiroshi,

of course you can.

Assuming you want to download splunkforwarder-6.3.3-f44afce176d0-linux-2.6-amd64.deb - you can simply copy paste the wget link that is shown on the download page.

The wget looks like: wget -O splunkforwarder-6.3.3-f44afce176d0-linux-2.6-amd64.deb 'http://www.splunk.com/bin/splunk/DownloadActivityServlet?architecture=x86_64&platform=linux&version=...'

Just change the wget -O to curl -L -o
The final command should look like
curl -L -o splunkforwarder-6.3.3-f44afce176d0-linux-2.6-amd64.deb 'http://www.splunk.com/bin/splunk/DownloadActivityServlet?architecture=x86_64&platform=linux&version=...'

That's all.

BR
Oliver

View solution in original post

bishopolis
Path Finder

wget https://download.splunk.com/products/splunk/releases/6.6.3/linux/splunkforwarder-6.6.3-e21ee54bc796-...
--2017-10-24 16:44:47-- https://download.splunk.com/products/splunk/releases/6.6.3/linux/splunkforwarder-6.6.3-e21ee54bc796-...
Resolving download.splunk.com (download.splunk.com)... 13.33.151.73, 13.33.151.8, 13.33.151.155, ...
Connecting to download.splunk.com (download.splunk.com)|13.33.151.73|:443... connected.
HTTP request sent, awaiting response... 404 Not Found
2017-10-24 16:44:47 ERROR 404: Not Found.

0 Karma

koshyk
Super Champion

Just updated or copy-paste purposes

product="splunk"       # values can be : splunk , universalforwarder
version="6.6.3"        # Splunk product Version
hash="e21ee54bc796"    # specific per Version
arch="amd64"           # values can be : x86_64 (redhat, tgz), amd64 (ubuntu), x64 (Windows)
os="linux"             # values can be : linux, windows
pkg="deb"              # Values can be : tgz, rpm, deb, msi

if [ $pkg = "tgz" ]; then
   filename="${product}-${version}-${hash}-Linux-${arch}.${pkg}"
elif [ $os = "windows" ]; then
   filename="${product}-${version}-${hash}-${arch}-release.${pkg}"
else 
   filename="${product}-${version}-${hash}-${os}-2.6-${arch}.${pkg}"
fi

md5File="${filename}.md5"
echo $filename         # Verify this is correct

wget "https://download.splunk.com/products/splunk/releases/${version}/${os}/${md5File}"
wget "https://download.splunk.com/products/splunk/releases/${version}/${os}/${filename}"


# OR
curl -o "$md5File" "https://download.splunk.com/products/splunk/releases/${version}/${os}/${md5File}"
curl -o "$md5File" "https://download.splunk.com/products/splunk/releases/${version}/${os}/${filename}"
0 Karma

ohoppe
Path Finder

Hi Hiroshi,

of course you can.

Assuming you want to download splunkforwarder-6.3.3-f44afce176d0-linux-2.6-amd64.deb - you can simply copy paste the wget link that is shown on the download page.

The wget looks like: wget -O splunkforwarder-6.3.3-f44afce176d0-linux-2.6-amd64.deb 'http://www.splunk.com/bin/splunk/DownloadActivityServlet?architecture=x86_64&platform=linux&version=...'

Just change the wget -O to curl -L -o
The final command should look like
curl -L -o splunkforwarder-6.3.3-f44afce176d0-linux-2.6-amd64.deb 'http://www.splunk.com/bin/splunk/DownloadActivityServlet?architecture=x86_64&platform=linux&version=...'

That's all.

BR
Oliver

okug
New Member

Great! I tried without -L option.
Thanks Oliver!

-- Hiroshi

0 Karma

ohoppe
Path Finder

Please accept my answer.

0 Karma
Get Updates on the Splunk Community!

Building Reliable Asset and Identity Frameworks in Splunk ES

 Accurate asset and identity resolution is the backbone of security operations. Without it, alerts are ...

Cloud Monitoring Console - Unlocking Greater Visibility in SVC Usage Reporting

For Splunk Cloud customers, understanding and optimizing Splunk Virtual Compute (SVC) usage and resource ...

Automatic Discovery Part 3: Practical Use Cases

If you’ve enabled Automatic Discovery in your install of the Splunk Distribution of the OpenTelemetry ...