Splunk Dev

Deployment Server access via Winscp

daisy
Explorer

hi all, I would like to access DS via Winscp so I can look at and donwload some apps. The problem is that Splunk is installed as and owned by splunk user. When I use Putty, I use "sudo su - splunk" and am able to make changes to any directories under /opt/splunk. Can someone give me a hint what I need to change for Winscp to be able to use it and access the directories as I am currently getting "permission denied" messages. 

Thanks!

Labels (1)
0 Karma

isoutamo
SplunkTrust
SplunkTrust

Hi

I don't know is there an any easy way to do it or not. If I recall right there could be some way to configure sftp server on node to accept this? Probably this is not the best way in security point of view? But I suppose that still it's much better to copy those apps to your own user on DS and then use "sudo cp ...." to get those to correct places. Also remember to do "sudo chown ..." for copied files.

Even better way to deploy and keep track of those is use e.g. git to store those configurations and then deploy those from it.

r. Ismo

daisy
Explorer

Thanks, this is a good workaround. I will give it a try. 

0 Karma

Stefanie
Builder

Are you able to login to WinSCP using a non-splunk account and then tell WinSCP to use sudo on login? 

https://winscp.net/eng/docs/faq_su#use_sudo_on_login

(Example) In the WinSCP login options window:

Click Advanced options
Go to Environment --> SCP/Shell (on left)
Select Shell: "sudo su - splunk"

daisy
Explorer

I was looking for this option (as I read online about it) but couldn't find it so it might be disabled. Is it possible taht it is disabled or should I look further for it?

0 Karma

Stefanie
Builder

I'm not familiar with using winscp all that much. I typically use putty and pscp.

If it's a software installed by your IT department then it's possible they have some features disabled.

I use pscp to transfer files to my server as my user account and then "sudo chown" the files to the splunk user, the same process that isoutamo mentioned.

 

 

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Build the Future of Agentic AI: Join the Splunk Agentic Ops Hackathon

AI is changing how teams investigate incidents, detect threats, automate workflows, and build intelligent ...

[Puzzles] Solve, Learn, Repeat: Character substitutions with Regular Expressions

This challenge was first posted on Slack #puzzles channelFor BORE at .conf23, we had a puzzle question which ...

Splunk Community Badges!

  Hey everyone! Ready to earn some serious bragging rights in the community? Along with our existing badges ...